Hard, Β onΒ  Containers Submissions: 15/40

Much like in the When a FROM scratch Image Is Not Good Enough challenge, you'll need to troubleshoot a misbehaving container. However, this time, the application refuses to even start. Your goal is to find the cause of the problem and fix it, potentially by rebuilding the application image.

The application is a simple web server that, upon receiving a request, calls the GitHub status API and proxies the response back to the client.

The following conditions should be met for the solution to be accepted:

  • The application container should be named status-checker.
  • The application container should be listening on port 8080.
  • The unmodified server binary from the original image must be used.

Additionally, you'll need to make sure that the container still adheres to DevOps best practices:

  • The container image size should be less than 50MB.
  • There should be no shell in the container.

You can start, stop, and remove the container as many times as you want, using its original image or replacing it with your own.

Good luck!

Hint 1 πŸ’‘

Looking at the container's logs is a good starting point.

Hint 2 πŸ’‘

Try inspecting the content of the image. How many files are there? Can you copy out the application to the host and run it?

Hint 3 πŸ’‘

Try inspecting the application binary. What can you learn about it using file and ldd?

Hint 4 πŸ’‘

If you managed to start the container, but the solution is still not accepted, try sending an HTTP request to the container. The response may contain a clue.

Hint 5 πŸ’‘

Have you read this blog post? It might help.

Different types of distroless container images.
Hint 6 πŸ’‘

Follow the dynamic hints of the solution checker.

Level up your server-side game β€” Join 6,500 engineers who receive insightful learning materials straight to their inbox