1
0
Fork 0
mirror of https://github.com/codex-team/codex.docs.git synced 2025-07-18 20:59:42 +02:00

add docker config and CI config (#109)

This commit is contained in:
Nikita Melnikov 2020-11-23 14:09:33 +03:00 committed by GitHub
parent 417ab0688b
commit e27bc52388
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 48 additions and 0 deletions

23
.github/workflows/build-and-push.yml vendored Normal file
View file

@ -0,0 +1,23 @@
name: Build and deploy
on: [push]
env:
DOCKER_REPO: ${{ secrets.DOCKER_USERNAME }}/codex-docs
jobs:
build_and_deploy:
runs-on: ubuntu-20.04
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Build and push docker image
uses: docker/build-push-action@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
repository: ${{ env.DOCKER_REPO }}
tag_with_ref: true
dockerfile: docker/Dockerfile.prod
push: ${{ endsWith(github.ref, '/stage') || endsWith(github.ref, '/prod') }}