Skip to content
Snippets Groups Projects
Commit df2ba323 authored by spmohanty's avatar spmohanty
Browse files

Addresses #2 : Setups CI to deploy docs to S3

parent 45efbdf1
No related branches found
No related tags found
No related merge requests found
image: themattrix/tox image: themattrix/tox
##########################################
##########################################
## We have to set the following env vars
## in the admin interface :
## - AWS_DEFAULT_REGION
## - BUCKET_NAME
## - AWS_ACCESS_KEY_ID
## - AWS_SECRET_ACCESS_KEY
stages:
- tests
- deploy_docs
cache: cache:
paths: paths:
- .tox - .tox
...@@ -13,3 +25,20 @@ tests: ...@@ -13,3 +25,20 @@ tests:
- apt install -y libgl1-mesa-glx xvfb - apt install -y libgl1-mesa-glx xvfb
- pip install tox - pip install tox
- xvfb-run -s "-screen 0 800x600x24" tox - xvfb-run -s "-screen 0 800x600x24" tox
build_and_deploy_docs:
image: "python:latest"
stage: deploy_docs
only:
- master
dependencies:
- tests
before_script:
- pip install awscli
script:
- pip install -r requirements_dev.txt
- make docs
- aws s3 sync ./docs/_build/html s3://${BUCKET_NAME}
environment:
name: ${CI_COMMIT_REF_SLUG}
url: http://${BUCKET_NAME}.s3-website.${AWS_DEFAULT_REGION}.amazonaws.com/
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment