@travetto/pack 3.4.0 → 3.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@travetto/pack",
3
- "version": "3.4.0",
3
+ "version": "3.4.2",
4
4
  "description": "Code packing utilities",
5
5
  "keywords": [
6
6
  "travetto",
@@ -55,7 +55,7 @@ export class DockerPackOperation {
55
55
  * Building Docker Container
56
56
  */
57
57
  static async* buildDockerContainer(cfg: DockerPackConfig): AsyncIterable<string[]> {
58
- const cmd = ['docker', 'build', ...DockerPackOperation.getDockerTags(cfg).flatMap(x => ['-t', x]), '.'];
58
+ const cmd = ['docker', 'build', ...cfg.dockerBuildFlags?.split(' ') ?? [], ...DockerPackOperation.getDockerTags(cfg).flatMap(x => ['-t', x]), '.'];
59
59
 
60
60
  yield* PackOperation.title(cfg, cliTpl`${{ title: 'Building Docker Container' }} ${{ param: cfg.dockerTag?.join(',') }}`);
61
61
 
@@ -19,6 +19,7 @@ export type CommonPackConfig = {
19
19
 
20
20
  export type DockerPackConfig = {
21
21
  dockerFactory: string;
22
+ dockerBuildFlags?: string;
22
23
  dockerImage: string;
23
24
  dockerName: string;
24
25
  dockerTag?: string[];
@@ -27,6 +27,8 @@ export class PackDockerCommand extends BasePackCommand {
27
27
  dockerPort: number[] = [];
28
28
  @CliFlag({ desc: 'Docker Push Tags ', short: 'dx', envVars: ['PACK_DOCKER_PUSH'] })
29
29
  dockerPush = false;
30
+ @CliFlag({ desc: 'Docker Build Flags ', short: 'dr', envVars: ['PACK_DOCKER_BUILD_FLAGS'] })
31
+ dockerBuildFlags?: string;
30
32
  @CliFlag({ desc: 'Docker Registry ', short: 'dr', envVars: ['PACK_DOCKER_REGISTRY'] })
31
33
  dockerRegistry?: string;
32
34
  @CliFlag({ desc: 'Docker Runtime user ', short: 'du', name: 'docker-runtime-user', envVars: ['PACK_DOCKER_RUNTIME_USER'] })