Using build containers across all build steps is a very common task. They isolate the build steps and can be created for a very specific task. Most CI/CD pipelines today support them and most teams have moved away from heavy VM. Because the individual container is created every time from a immutable image, there are limited capabilities to keep state. It has to be done explicitly and is like in GitLab provided by the system as a orchestrator and coordinator.
Lately Docker introduces a rate limit for the pulls from the public repository. If you hit them, you will have to wait for 6h until you can fetch an image again.
The rate limits of 100 container image requests per six hours for anonymous usage, and 200 container image requests per six hours for free Docker accounts are now in effect. Image requests exceeding these limits will be denied until the six hour window elapses.
Null Pointer Exceptions are the most often the thing OOP developer will see while their app sinks. They don’t get much help, all they tell you is that something is not there. Where you might ask and all you get is a line. In this line there are several possibilities to be null. So no real help here. Some people came up with the idea to have less information on a single line, so that the NPE can easier be identified.
Sometime it is good to read the latest messages from a kafka topic. The standard flag provides you with the from-beginning behavior. This can be problematic, because when the topic already has a huge number of messages received. So if you want only to create a consumer, which reads the last 10 messages or so, you need to tell the consumer from which offset the receiving should start.
Photo by Denys Nevozhai on Unsplash
Photo by Nicolas Thomas on Unsplash
I you feel sometimes frustrated by writing bash script files, which do not work as expected, you will love the Shellchecker.
I came across a twitter post of Nick Janetakis about the tool ShellChecker. With this little tool you can lint your bash script right from the bash. The checker will identify many problems with your script and provide hints on why it is a problem and how to fix it.
Simple Dockerfile Here is a simple dockerfile which will run an application inside the container. The problem here is, that the command is issued as root.
1 2 3 4 5 6 7 8 9 FROMdebian:stretch-20200422-slimWORKDIR/app/COPY application /app/EXPOSE8080CMD [ "/app/application"] 1 2 3 HOST>dockerbuild−tmy−application:1.0.0.HOST> docker run -it -p 8080 my-application:1.0.0 $CONT> ps -u Dockerfile with User You’ll see that your program is running for user root.