/lupus-localdev

Additions for making local development with docker-compose nicer.

Primary LanguageShell

Lupus localdev Setup

Provides a central docker-compose configuration for making local development with docker-compose based projects nicer. The setup plays nice together with projects using drunomics/devsetup-docker.

Features

Installation

git clone git@github.com:drunomics/lupus-localdev.git --branch=2.x ~/.lupus-localdev
echo "# Add lupus-localdev setup and aliases." >> ~/.bashrc
echo 'source ~/.lupus-localdev/bashrc' >> ~/.bashrc
bash
# Register and launch docker containers.
localdev-dcp up -d

Usage

By default, traefik is started on boot automatically. So it's automatically avaiable all the time. However one can manually restart / stop / start it with the provided localdev-dcp command:

# Stop
localdev-dcp stop
# Start
localdev-dcp start
# Restart
localdev-dcp restart

Per-project setup changes

Using this centralized traefik network means it is an external network in respect to projects' own ecosystem and it should be declared as such:

networks:
  traefik:
    name: traefik
    external: true

Uninstall

localdev-dcp down -v
sed -i '/lupus-localdev/d' ~/.bashrc
rm -rf ~/.lupus-localdev

Provided commands

  • dcp
    A simple short-hand for docker-compose.

  • localdev-dcp
    Runs docker-compose for the lupus-localdev services, like traefik.

  • localdev-update Updates the localdev setup with latest upstream changes. Updates just pull in changes in the current branch, what will never including breaking changes.