Skip to content

Instantly share code, notes, and snippets.

@lopezjurip
Created May 23, 2020 17:34
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 lopezjurip/c6f10454a553d33214bbe1b4a4ec0bb5 to your computer and use it in GitHub Desktop.
Save lopezjurip/c6f10454a553d33214bbe1b4a4ec0bb5 to your computer and use it in GitHub Desktop.
pipenv, zappa and Gitlab CI
image: python:latest
stages:
- deploy
variables:
WORKON_HOME: .pipenv/venvs
PIP_CACHE_DIR: .pipenv/pipcache
cache:
key: pipenv
paths:
- .pipenv
deploy:
stage: deploy
before_script:
- pip install --upgrade pipenv
- pipenv sync
- /bin/bash -c "source $(pipenv --venv)/bin/activate"
- export VIRTUAL_ENV=$(pipenv --venv)
script:
- /bin/bash -c "$(pipenv --venv)/bin/zappa update dev"
- /bin/bash -c "$(pipenv --venv)/bin/zappa manage dev migrate"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment