Tag Archives: Docker

AWS: security – Instance Metadata Service v1 vs IMDS v2, Kubernetes Pod and Docker containers

24 April 2023
 

  Instance metadata (IMDS – Instance Metadata Service) – data about an EC2 instance, such as information about AMI, IP, hostname, etc. You can also add User Data to Instance Metadata to store some parameters, which can then be retrieved inside the instance. See Instance metadata and user data and Instance metadata categories. From the beginning of the… Read More »

Jenkins: running workers in Kubernetes and Docker images build

27 February 2021
 

 We have a Jenkins instance that is running jobs in Docker containers on its host. Eventually, we’ve faced with an issue when the current AWS Ec2 instance t2.2xlarge (8 CPU, 32 RAM) during peak workload periods was too overloaded – not enough CPU time, not enough memory. So, the first solution could be to proceed… Read More »

Kubernetes: NGINX/PHP-FPM graceful shutdown and 502 errors

25 February 2021
 

 We have a PHP application running with Kubernetes in pods with two dedicated containers – NGINX и PHP-FPM. The problem is that during downscaling clients get 502 errors. E.g. when a pod is stopping, its containers can not correctly close existing connections. So, in this post, we will take a closer look at the pods’… Read More »

Docker: configure tzdata and timezone during build

17 May 2020
 

 During a Docker image build – it stops asking to configure the tzdata. Dockerfile at this moment is the next: FROM ubuntu:18.04 RUN apt update && apt install -y python-pip python-dev ssh python-boto3 RUN pip install ansible==2.4.3.0 Let’s reproduce – run the build: [simterm] admin@jenkins-production:~$ docker build -t proj/proj-ansible:1.1 . Sending build context to Docker… Read More »

Helm: helm-secrets – sensitive data encryption with AWS KMS and use it with Jenkins

16 May 2020
 

 So, as a follow-up to the Helm: Kubernetes package manager – an overview, getting started post – let’s discuss about sensitive data in our Helm charts. What I want is to store a chart files in a repository, but even if such a repo will be a private Github repo – I still don’t want… Read More »

Kubernetes: monitoring with Prometheus – exporters, a Service Discovery, and its roles

26 April 2020
 

 The next task with our Kubernetes cluster is to set up its monitoring with Prometheus. This task is complicated by the fact, that there is the whole bunch of resources needs to be monitored: from the infrastructure side – ЕС2 WokerNodes instances, their CPU, memory, network, disks, etc key services of Kubernetes itself – its… Read More »

AWS: eksctl – “Put http://169.254.169.254/latest/api/token: net/http: request canceled”

26 April 2020
 

 We have a Docker image with the eksctl tool included. We also have an ЕС2 with Linux with the eksctl. There is an AWS IAM Instance Profile attached to this EC2 with the AdminAccess policy assigned. On this ЕС2 we have Jenkins running in a Docker container, and it spawns its jobs inside in additional… Read More »

Linux: PHP-FPM, Docker, STDOUT and STDERR – no an application’s error logs

24 February 2020
 

 We have a Docker image with NGINX, PHP-FPM, and Supervisor. In the same image, we have our PHP application included, which outputs its errors to the /dev/stderr as per its php.ini file: … [global] error_log=/dev/stderr … The problem is, that if run kubectl logs –  there will be no error output from the application. So,… Read More »

Calibre Web: home in-browser online-library with Nextcloud storage and Moon+ Reader on Android

7 January 2020
 

 I’m using Calibre for my e-books library management for many years, but until today always used its desktop version. A couple of days ago I found the Calibre Web project – the same library, working with the same database, but accessible via a browser. The idea is to move away from storing books in Google… Read More »