fix container name not set

This commit is contained in:
JOLIMAITRE Matthieu 2024-02-03 23:39:18 +01:00
parent 4acf870e7b
commit 752efeece8

View file

@ -87,8 +87,8 @@ export class Runner {
} }
private start_process() { private start_process() {
const paths = container_paths(name); const paths = container_paths(this.name);
const command = container_command(name, paths.root, { const command = container_command(this.name, paths.root, {
boot: true, boot: true,
veth: true, veth: true,
redirections: this.config.redirections, redirections: this.config.redirections,
@ -99,8 +99,8 @@ export class Runner {
syscall_filter: ["add_key", "keyctl", "bpf"], syscall_filter: ["add_key", "keyctl", "bpf"],
}); });
this.loop = loop_process(command, { this.loop = loop_process(command, {
on_start: () => log("container", name, "started"), on_start: () => log("container", this.name, "started"),
on_stop: () => log("container", name, "stopped"), on_stop: () => log("container", this.name, "stopped"),
}); });
} }
@ -109,7 +109,7 @@ export class Runner {
} }
async update_proxies() { async update_proxies() {
const paths = container_paths(name); const paths = container_paths(this.name);
await Deno.mkdir(paths.sites, { recursive: true }); await Deno.mkdir(paths.sites, { recursive: true });
const sites = new Set<string>(); const sites = new Set<string>();
for (const redir of this.config.redirections) { for (const redir of this.config.redirections) {