33 lines
859 B
TypeScript
33 lines
859 B
TypeScript
|
import * as plugins from '../cloudly.plugins.js';
|
||
|
|
||
|
/*
|
||
|
A container version is managed by the versionmanager
|
||
|
*/
|
||
|
@plugins.smartdata.Manager()
|
||
|
export class ContainerVersion
|
||
|
extends plugins.smartdata.SmartDataDbDoc<ContainerVersion, unknown>
|
||
|
implements plugins.servezoneInterfaces.data.IContainerVersionData
|
||
|
{
|
||
|
public static async fromIVersionData(
|
||
|
dataArg: plugins.servezoneInterfaces.data.IContainerVersionData
|
||
|
) {
|
||
|
const containerVersionInstance = new ContainerVersion();
|
||
|
containerVersionInstance.id = plugins.smartunique.shortId();
|
||
|
Object.assign(containerVersionInstance, dataArg);
|
||
|
return containerVersionInstance;
|
||
|
}
|
||
|
|
||
|
@plugins.smartdata.unI()
|
||
|
public id: string;
|
||
|
|
||
|
@plugins.smartdata.svDb()
|
||
|
public dockerImageUrl: string;
|
||
|
|
||
|
@plugins.smartdata.svDb()
|
||
|
public dockerImageVersion: string;
|
||
|
|
||
|
constructor() {
|
||
|
super();
|
||
|
}
|
||
|
}
|