-
Notifications
You must be signed in to change notification settings - Fork 58
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] Cannot build Privado Docker images #281
Comments
Hi @cattius Currently, we merge the artifacts generated from both of these images into a final image which is then consumed by Privado CLI. Here is the Dockerfile:
Here Further, we have been planning to move the missing configurations and revisit the bundling process. I've created a separate ticket to track those here #288. Hope this helps! |
Thank you! That additional Dockerfile solves the mystery for me - I'll give it a try building a custom image with that. If the work will be tracked in #288, I think we can close this issue as a duplicate, but in the interim until #288 can be worked on, it would be really helpful to add this to the documentation. |
@ojaswa1942 Hi, a heads up this is still an issue when installing the CLI as per repo instructions
|
Describe the bug
There is no Dockerfile provided that enables custom application images to be built and launched from privado-cli. Please add a complete Dockerfile and instructions to the repo.
I've tried building both the Dockerfile in this repo (see details below) and the Dockerfile in privado-core. Both fail to launch with the same error because
/app/code
and many other file paths that privado-cli expects to find don't exist in the container (I can only find/home/privado-core-build
in the image produced by the privado-core Dockerfile).I hope I'm not missing something obvious here 😅 Opening this issue as a last resort after a lot of failed attempts.
To Reproduce
docker build -t privadolocal:latest .
app_config.go
) to the local image name and comment out theif dockerAccessKey, err := docker.GetPrivadoDockerAccessKey ...
if/else block inscan.go
so that it does not try to pull the image.go build
,go run main.go scan .
)Similarly, to reproduce with privado-core build an image with
docker build -t privadocorelocal:latest --build-arg JAR_VERSION="dev-SNAPSHOT" --build-arg VERSION=1 .
Expected behavior
It is possible to launch a scan from privado-cli using the locally-built image. The image should be the same size and have the same image history as the latest Privado image from AWS ECR (see below for details).
Desktop:
Additional context
In contrast, the latest Privado image from AWS ECR is 2.14GB and has clearly been created with a different Dockerfile, as the image history is very different:
The text was updated successfully, but these errors were encountered: