cli default parameter
parent
9536ea889a
commit
89a6004493
|
|
@ -3150,9 +3150,9 @@ class Docker {
|
|||
const { path, dockerfile, baseImage } = buildParameters;
|
||||
const { version, platform } = baseImage;
|
||||
const tag = new image_tag_1.default({ repository: '', name: 'unity-builder', version, platform });
|
||||
const command = `docker build ${path} \
|
||||
--file ${dockerfile} \
|
||||
--build-arg IMAGE=${baseImage} \
|
||||
const command = `docker build ${path} \
|
||||
--file ${dockerfile} \
|
||||
--build-arg IMAGE=${baseImage} \
|
||||
--tag ${tag}`;
|
||||
yield exec_1.exec(command, undefined, { silent });
|
||||
return tag;
|
||||
|
|
@ -3161,16 +3161,16 @@ class Docker {
|
|||
static run(image, parameters, silent = false) {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
const { workspace, runnerTempPath, sshAgent } = parameters;
|
||||
const command = `docker run \
|
||||
--workdir /github/workspace \
|
||||
--rm \
|
||||
${image_environment_factory_1.default.getEnvVarString(parameters)}
|
||||
--volume "/var/run/docker.sock":"/var/run/docker.sock" \
|
||||
--volume "${runnerTempPath}/_github_home":"/root" \
|
||||
--volume "${runnerTempPath}/_github_workflow":"/github/workflow" \
|
||||
--volume "${workspace}":"/github/workspace" \
|
||||
${sshAgent ? `--volume ${sshAgent}:/ssh-agent` : ''} \
|
||||
${sshAgent ? '--volume /home/runner/.ssh/known_hosts:/root/.ssh/known_hosts:ro' : ''} \
|
||||
const command = `docker run \
|
||||
--workdir /github/workspace \
|
||||
--rm \
|
||||
${image_environment_factory_1.default.getEnvVarString(parameters)} \
|
||||
--volume "/var/run/docker.sock":"/var/run/docker.sock" \
|
||||
--volume "${runnerTempPath}/_github_home":"/root" \
|
||||
--volume "${runnerTempPath}/_github_workflow":"/github/workflow" \
|
||||
--volume "${workspace}":"/github/workspace" \
|
||||
${sshAgent ? `--volume ${sshAgent}:/ssh-agent` : ''} \
|
||||
${sshAgent ? '--volume /home/runner/.ssh/known_hosts:/root/.ssh/known_hosts:ro' : ''} \
|
||||
${image}`;
|
||||
yield exec_1.exec(command, undefined, { silent });
|
||||
});
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
|
|
@ -24,7 +24,7 @@ class Docker {
|
|||
const command = `docker run \
|
||||
--workdir /github/workspace \
|
||||
--rm \
|
||||
${ImageEnvironmentFactory.getEnvVarString(parameters)}
|
||||
${ImageEnvironmentFactory.getEnvVarString(parameters)} \
|
||||
--volume "/var/run/docker.sock":"/var/run/docker.sock" \
|
||||
--volume "${runnerTempPath}/_github_home":"/root" \
|
||||
--volume "${runnerTempPath}/_github_workflow":"/github/workflow" \
|
||||
|
|
|
|||
Loading…
Reference in New Issue