mirror of https://github.com/portainer/portainer
fix(templates): add host file entry [EE-6461] (#10839)
parent
d2ccb10972
commit
2b73116284
|
@ -134,6 +134,8 @@ export interface AppTemplate {
|
||||||
*/
|
*/
|
||||||
labels?: Pair[];
|
labels?: Pair[];
|
||||||
|
|
||||||
|
hosts?: string[];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Whether the container should be started in privileged mode.
|
* Whether the container should be started in privileged mode.
|
||||||
* @example true
|
* @example true
|
||||||
|
|
|
@ -48,6 +48,8 @@ export class TemplateViewModel {
|
||||||
|
|
||||||
RestartPolicy!: string;
|
RestartPolicy!: string;
|
||||||
|
|
||||||
|
Hosts!: string[];
|
||||||
|
|
||||||
Labels!: Pair[];
|
Labels!: Pair[];
|
||||||
|
|
||||||
Env!: Array<TemplateEnv & { type: EnvVarType; value: string }>;
|
Env!: Array<TemplateEnv & { type: EnvVarType; value: string }>;
|
||||||
|
@ -112,6 +114,7 @@ function setTemplatesV2(this: TemplateViewModel, template: AppTemplate) {
|
||||||
? template.restart_policy
|
? template.restart_policy
|
||||||
: 'always';
|
: 'always';
|
||||||
this.Labels = template.labels ? template.labels : [];
|
this.Labels = template.labels ? template.labels : [];
|
||||||
|
this.Hosts = template.hosts ? template.hosts : [];
|
||||||
this.Env = templateEnv(template);
|
this.Env = templateEnv(template);
|
||||||
this.Volumes = templateVolumes(template);
|
this.Volumes = templateVolumes(template);
|
||||||
this.Ports = templatePorts(template);
|
this.Ports = templatePorts(template);
|
||||||
|
|
Loading…
Reference in New Issue