Skip to content
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

[Jib CLI] critical error message erased if rich console #3148

Closed
chanseokoh opened this issue Mar 18, 2021 · 0 comments · Fixed by #3162
Closed

[Jib CLI] critical error message erased if rich console #3148

chanseokoh opened this issue Mar 18, 2021 · 0 comments · Fixed by #3162

Comments

@chanseokoh
Copy link
Member

A lot of people will hit registry auth issues. When passing --console=plain, we can see the error and know what went wrong.

$ jib jar --target=openjdk --console=plain ~/tmp/embedded_jetty_hello_world.jar
...
Container entrypoint set to [java, -cp, /app/explodedJar:/app/dependencies/*, org.eclipse.jdt.internal.jarinjarloader.JarRsrcLoader]
Container program arguments set to []
[ERROR] I/O error for image [registry-1.docker.io/library/openjdk]:
[ERROR]     java.net.SocketException
[ERROR]     Socket closed
com.google.cloud.tools.jib.api.RegistryUnauthorizedException: Unauthorized for registry-1.docker.io/library/openjdk

However, by default, it's getting erased by the dynamic progress update. Also the output becomes messy.

$ jib jar --target=openjdk ~/tmp/embedded_jetty_hello_world.jar
...
Container entrypoint set to [java, -cp, /app/explodedJar:/app/dependencies/*, org.eclipse.jdt.internal.jarinjarloader.JarRsrcLoader]
Container program arguments set to []
        I/O error for image [registry-1.docker.io/library/openjdk]:
            java.net.SocketException
            Socket closed
        I/O error for image [registry-1.docker.io/library/openjdk]:
            java.net.SocketException                                                                                                                                                                                          Socket closed
        I/O error for image [registry-1.docker.io/library/openjdk]:
            java.net.SocketException
            Socket closed
        I/O error for image [registry-1.docker.io/library/openjdk]:
            java.net.SocketException
            Socket closed
        I/O error for image [registry-1.docker.io/library/openjdk]:
Executing tasks:                                                                                                                                                                                                              java.net.SocketException
            Socket closed
        I/O error for image [registry-1.docker.io/library/openjdk]:
            java.net.SocketException
            Socket closed
Executing tasks:
[==========================    ] 87.2% complete
> pushing blob sha256:421a4fefea8af2cd5590e9952...
> pushing blob sha256:5d3b2c2d21bba59850dac063b...

$

This is a critical issue, as it hides the essential information.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant