diff options
Diffstat (limited to 'packages/containers/script')
| -rw-r--r-- | packages/containers/script/build.ts | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/packages/containers/script/build.ts b/packages/containers/script/build.ts index 18ae328e1..8fd6a7d4d 100644 --- a/packages/containers/script/build.ts +++ b/packages/containers/script/build.ts @@ -15,9 +15,12 @@ for (const name of images) { const image = `${reg}/build/${name}:${tag}` const file = `packages/containers/${name}/Dockerfile` const arg = name === "base" ? "" : `--build-arg REGISTRY=${reg}` - const cmd = `docker build -f ${file} -t ${image} ${arg} .` - console.log(cmd) - await $`${cmd}` + console.log(`docker build -f ${file} -t ${image} ${arg} .`) + if (arg) { + await $`docker build -f ${file} -t ${image} --build-arg REGISTRY=${reg} .` + } else { + await $`docker build -f ${file} -t ${image} .` + } if (push) { await $`docker push ${image}` |
