Page MenuHomePhorge

Create a docker development environment
Open, Needs TriagePublic

Description

In the current state, it is not easy to start developing quickly, you need to make a complete setup, and it may be a hassle if you are working on different projects, or even working on the installation procedure, as reproducibility become increasingly complicated when you already did change to the system,

This task aims at providing a diff with a development environment. At the end of this task, the only command that should need to be run to start a working copy of phorge should be:

docker-compose up

Event Timeline

G renamed this task from Create a docker dvelopment environment to Create a docker development environment .Nov 6 2021, 21:31
G claimed this task.
G changed the visibility from "Public (No Login Required)" to "All Users".
G updated the task description. (Show Details)

We've developed this internally at Twitter. I'm sure some of the tribal knowledge would be useful externally. We dump about 600 lines of PHP into a PhabricatorAuthManagementDockerInstallWorkflow and then execute it with /phabricator/bin/auth docker-install once the containers are running.

This class runs through the following:

  • Creates an admin user with a default password based on an environment variable
  • Auto-enables the username/password auth provider.
  • Creates almanac devices/interfaces/networks/services for a minimal cluster setup (Daemons, php-fpm, drydock, keywarden)
  • Generates a shared SSH key for cluster security, automatically installing them and trusting them. This is distributed using shared docker volumes between the services.
  • Mirrors a git repo on our internal SCM.

We don't have Drydock working yet, but this enables us to get most of our development done relatively painlessly.

Cigaryno changed the visibility from "All Users" to "Public (No Login Required)".Sat, Dec 28, 08:33