Кэш-монтирование или Cache mount в Docker. Использование кэш-монтирования в GitLab CI/CD

Кэш-монтирование в Docker — это мощный инструмент, который может значительно ускорить процесс сборки образов в CI/CD. Но его правильная настройка в GitLab требует понимания не только работы BuildKit, но и особенностей взаимодействия с различными конфигурациями GitLab Runner — DinD и DooD. В этой статье я расскажу об устройстве кэш-монтирования в Docker и как его использовать в GitLab CI/CD. На примере простой сборки Python-проекта покажу готовые решения для кэширования зависимостей, чтобы оптимизировать сборку Docker-образов.

https://habr.com/ru/articles/995528/

#docker #deploy #gitlab #python #cache #dockerfile #cicd #dind #buildkit #git

Кэш-монтирование или Cache mount в Docker. Использование кэш-монтирования в GitLab CI/CD

Я Backend разработчик на Python, и в одном из проектов мне понадобилось настроить сборку Docker-образа в GitLab CI/CD. Базовую настройку я сделал без проблем, но я хотел ускорить сборку  по...

Хабр

Anyone using cross-rs inside Docker, or in a CI which uses containers? #dind

I'm trying cross-rs to simplify cross platform CI builds and it's one extra issue after another! Might have to do it all with manual targets in Cargo.toml, yuk.

#RuslLang #CI #DevOps #WoodpeckerCI #Codeberg

This is so damn cool. Relatively secure docker in docker with very an isolated docker daemon context and low overhead. A great alternative to MicroVM's like #Firecracker.

https://www.docker.com/resources/docker-in-docker-containerized-ci-workflows-dockercon-2023/

I love the presentation style too. I followed along in my terminal and everything worked. So much more helpful for me than "go to this website to learn more".

#dind #microvm

Docker-in-Docker: Containerized CI Workflows | Docker

Docker-in-Docker (DinD) is a technique to run Docker containers inside another Docker container. DinD makes it easy to create an isolated environment for each application or service under test in a CI platform. Learn the basics of DinD, its benefits, and use cases in this presentation.

Docker

@deliverance If #Kaniko is not your speed, You can still do better than #DinD by using #PinD or even #PinP

How to use Podman inside of a container
https://www.redhat.com/sysadmin/podman-inside-container

This way you don't need a daemon, and you can run rootless.

How to use Podman inside of a container

Have you ever wondered about running Podman in a container: Podman in Podman, Podman in Docker, or even Podman in Kubernetes?

Enable Sysadmin

@fyw321 @geerlingguy My 8 node cluster costs around 55W via POE. It is 3 pi4 8G control+worker nodes, and 5 pi4 4G worker-only nodes (1 is actually 8G.)

Storage is #iscsi on spinning rust on #TrueNAS, but you can do all this on local disks.

It handles a LOT:
- #Promstack, #FluxCD, #Calico, various scrapers
- #Adguard
- #Blocky (another adblocking #dns)
- #Jellyfin
- #Ombi, Prowlarr, *arr, Deluge
- Home automation helpers (#ser2sock instances, #zigbee/#zwave 2mqtt, but not HA itself)
- #Argo for builds (deprecated in favor of the x64 cloud lab. Building x64 docker containers on arm is BAD)
- Democratic CSI for iscsi/nfs
- #GoHarbor container registry & #dockerhub cache
- #Mealie recipe manager
- #Monica contact manager
- #SMTP relay to gmail
- #Ubiquiti console (bootstrapping becomes a chicken and egg problem though, if it goes down wrong)
- #Wireguard #VPN server
- #Whoogle
- #VisualStudioCode and a #dind sidecar
- SSL termination for most of the rest of the network

It's just that the test setup is cursed:

The tests run on #GitLab runners using the #Docker executor in privileged mode. This enables us to start a #KVM based #AVD for Android tests and to deploy all individual homeserver implementations using #DinD.

In order to get better debugging information, the headless virtual screen is recorded via #VNC in order to record all ongoing tests for later use.

Some people told us they don't like our tests.

Letzte Aktion in Arbeitszeit: Skript aktualisieren fürs registrieren von #Gitlab-Runner für Projekte. 🕵️‍♀️

Funktioniert jetzt auch wieder mit #DinD 😎