You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using envbuilder_cached_image with a cache repo requiring authentication and passing ENVBUILDER_DOCKER_CONFIG_BASE64 into the provider:
Failed to find cached image in repository "docker.local". It will be rebuilt in the next apply. Error: failed to fetch the envbuilder binary from the builder image: check remote image: check remote image: GET http://docker.local/v2/envbuilder/manifests/latest: UNAUTHORIZED: authentication required; [map[Action:pull Class: Name:envbuilder Type:repository]]
This is assuming that the underlying Coder / Coder Provisioner deployment does not have the same image pull secret mounted and does not have DOCKER_CONFIG=path/to/config.json set in its env.
Workaround
Mount the same registry credential on the Coder deployment and set DOCKER_CONFIG=path/to/config.json
Proposed Solution
The Terraform provider should also take the base64-encoded docker config JSON into account when attempting to fetch the Envbuilder binary from the source image.