I’m trying to use `DOCKER_BUILDKIT=1` via the `env...
# general
m
I’m trying to use
DOCKER_BUILDKIT=1
via the
env
property on a
DockerBuild
using
awsx.ecs.Image.fromDockerBuild
. My
env
is the same as the test example ( https://github.com/pulumi/pulumi-docker/pull/95/files#diff-737a6e76d84c40fbbd438671aaf1a8c3R43 ), but I receive an error, and I don’t see the env options in there (not sure if I would though);
Copy code
error: Error: ' docker build --ssh default ./app -t d2314cb1-container' failed with exit code 1
Any tips for using Docker buildkit to install private packages in a docker build? https://docs.docker.com/develop/develop-images/build_enhancements/#using-ssh-to-access-private-data-in-builds
I believe my issue is related to MacOS and the SSH_AUTH_SOCK. The workaround would maybe be to have a key without a passphrase that I pass with the
--ssh
flag
Wrong all around. Using a Personal Access Token in combination with a custom
~/.npmrc
I was able to resolve:
Copy code
always-auth=true
registry=<https://registry.npmjs.org/>
@my-org:registry=<https://npm.pkg.github.com>
//npm.pkg.github.com/:_authToken=${NODE_AUTH_TOKEN}
Copy code
args: { NODE_AUTH_TOKEN: config.getSecret("nodeAuthToken");
Here’s the satanic line that is supposed to keep CD working:
Copy code
const nodeAuthToken: pulumi.Output<string> = process.env.NODE_AUTH_TOKEN || pulumi.output(config.getSecret("nodeAuthToken")!.apply(v => v));