Fix issue of workDir not being used in the code

Signed-off-by: divyansh42 <diagrawa@redhat.com>
This commit is contained in:
divyansh42 2021-04-02 00:30:39 +05:30
parent 8fe53efc79
commit 4378cb839e
5 changed files with 7 additions and 3 deletions

View file

@ -91,6 +91,7 @@ jobs:
spring-petclinic-*.jar spring-petclinic-*.jar
port: 8080 port: 8080
archs: amd64,arm64 archs: amd64,arm64
workdir: "."
- name: Echo Outputs - name: Echo Outputs
run: | run: |

View file

@ -43,7 +43,6 @@ After building your image, use [push-to-registry](https://github.com/redhat-acti
| archs | Architecture(s) to build the image(s) for. For multiple architectures, separate by a comma. Refer to [Multi arch builds](#multi-arch-builds) to setup the `qemu-user-static` dependency. | `amd64` | archs | Architecture(s) to build the image(s) for. For multiple architectures, separate by a comma. Refer to [Multi arch builds](#multi-arch-builds) to setup the `qemu-user-static` dependency. | `amd64`
| base-image | The base image to use for the container. | **Must be provided** | base-image | The base image to use for the container. | **Must be provided**
| content | Paths to files or directories to copy inside the container to create the file image. This is a multiline input to allow you to copy multiple files/directories.| None | content | Paths to files or directories to copy inside the container to create the file image. This is a multiline input to allow you to copy multiple files/directories.| None
| context | Path to directory to use as the build context. | `.`
| entrypoint | The entry point to set for the container. This is a multiline input; split arguments across lines. | None | entrypoint | The entry point to set for the container. This is a multiline input; split arguments across lines. | None
| envs | The environment variables to be set when running the container. This is a multiline input to add multiple environment variables. | None | envs | The environment variables to be set when running the container. This is a multiline input to add multiple environment variables. | None
| image | Name to give to the output image. | **Must be provided** | image | Name to give to the output image. | **Must be provided**

2
dist/index.js vendored

File diff suppressed because one or more lines are too long

2
dist/index.js.map vendored

File diff suppressed because one or more lines are too long

View file

@ -104,6 +104,10 @@ export class BuildahCli implements Buildah {
args.push("--arch"); args.push("--arch");
args.push(settings.archs); args.push(settings.archs);
} }
if (settings.workingdir) {
args.push("--workingdir");
args.push(settings.workingdir);
}
args.push(container); args.push(container);
return this.execute(args); return this.execute(args);
} }