forked from engineering/cloudservices
add tier model
parent
8df5589242
commit
688e243839
|
@ -0,0 +1,21 @@
|
||||||
|
import { Document, Schema, model } from 'mongoose';
|
||||||
|
|
||||||
|
export interface TierInterface extends Document {
|
||||||
|
id: number,
|
||||||
|
resourceLimits: {
|
||||||
|
// in MB
|
||||||
|
ram: number,
|
||||||
|
// in MB
|
||||||
|
storage: number,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
const Tier: Schema = new Schema({
|
||||||
|
id: Number,
|
||||||
|
resourceLimits: {
|
||||||
|
ram: Number,
|
||||||
|
storage: Number,
|
||||||
|
},
|
||||||
|
}, { id: false });
|
||||||
|
|
||||||
|
export default model<TierInterface>('Tier', Tier);
|
|
@ -1,3 +1,4 @@
|
||||||
export { default as Account, AccountInterface } from './Account';
|
export { default as Account, AccountInterface } from './Account';
|
||||||
export { default as Moderation, ModerationInterface } from './Moderation';
|
export { default as Moderation, ModerationInterface } from './Moderation';
|
||||||
export { default as Domain, DomainInterface } from './Domain';
|
export { default as Domain, DomainInterface } from './Domain';
|
||||||
|
export { default as Tier, TierInterface } from './Tier';
|
||||||
|
|
Loading…
Reference in New Issue