dash/contrib/containers
Kittywhiskers Van Gogh 6699b0228f
docker: fix gitian support, optimize container layer count and improve script consistency (#4983)
* contrib: set the working directory to /src/dash to allow for cloning gitian dependencies

* contrib: place the home directory inside /home instead of root

* contrib: add notes about sharing ccache across the network

* contrib: chown based on the (u/g)id env vars instead of the associated username

* contrib: reduce layer count by reducing run invocations

* contrib: develop container cleanup and maintenance

- add apt-cacher-ng, gpg, lsb-release, screen as a package dependencies
- reorder packages in alphabetical order
- correct documentation
- create and add user to the docker group to satisfy Gitian's needs
- reduce the number of RUN calls to reduce layer count
2022-08-22 22:42:36 +03:00
..
ci docker: fix gitian support, optimize container layer count and improve script consistency (#4983) 2022-08-22 22:42:36 +03:00
deploy docker: fix gitian support, optimize container layer count and improve script consistency (#4983) 2022-08-22 22:42:36 +03:00
develop docker: fix gitian support, optimize container layer count and improve script consistency (#4983) 2022-08-22 22:42:36 +03:00
README.md docs: introduce documentation and usage for containers 2021-12-21 12:43:48 +05:30

Containers

This directory contains configuration files for containerization utilities.

Currently two Docker containers exist, ci defines how Dash's GitLab CI container is built and the dev builds on top of the ci to provide a containerized development environment that is as close as possible to CI for contributors!

Usage Guide

We utilise edrevo's dockerfile-plus, a syntax extension that leverages Docker BuildKit to reduce the amount of repetitive code.

As BuildKit is opt-in within many currently supported versions of Docker (as of this writing), you need to set the following environment variables before continuing. While not needed after the initial docker-compose build (barring updates to the Dockerfile), we recommend placing this in your ~/.bash_profile/~/.zshrc or equivalent

export DOCKER_BUILDKIT=1
export COMPOSE_DOCKER_CLI_BUILD=1

After that, it's simply a matter of building and running your own development container. You can use extensions for your IDE like Visual Studio Code's Remote Containers to run terminal commands from inside the terminal and build Dash Core.

cd contrib/containers/develop
docker-compose build
docker-compose run container