Skip to content

Instantly share code, notes, and snippets.

@sbalnojan
Created August 28, 2019 19:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sbalnojan/0b4a8b38505850f49e384c765cb5a825 to your computer and use it in GitHub Desktop.
Save sbalnojan/0b4a8b38505850f49e384c765cb5a825 to your computer and use it in GitHub Desktop.
containers:
build-env:
image: python:3.7
volumes:
- local: .
container: /src
options: cached
- local: .pip-cache
container: /src/.pip-cache
options: cached
- local: .pipenv-cache
container: /src/.pipenv-cache
working_directory: /src
environment:
PYTHONPATH: "/src"
PYTHONUSERBASE: "/src/.pip-cache"
PIPENV_VENV_IN_PROJECT: true
run_as_current_user:
enabled: true
home_directory: /home/container-user
tasks:
dep:
description: Install dependencies via pipenv
group: Utility tasks
run:
container: build-env
command: sh -c 'pip install --user pipenv; python -m pipenv install'
shell:
description: Start a shell in the development environment.
group: Utility tasks
prerequisites:
- dep
run:
container: build-env
command: /bin/sh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment