2020-06-08 14:51:54 +02:00

69 lines
2.0 KiB
YAML

name: CD
on:
push:
branches: [ master ]
jobs:
build:
name: Build and push docker images
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
submodules: recursive
- name: Build neo4j base image
uses: docker/build-push-action@v1.1.0
with:
repository: humanconnection/neo4j
tags: latest
path: Human-Connection/neo4j/
push: false
- name: Build backend base image
uses: docker/build-push-action@v1.1.0
with:
repository: humanconnection/nitro-backend
tags: latest
path: Human-Connection/backend/
push: false
- name: Build webapp base image
uses: docker/build-push-action@v1.1.0
with:
repository: humanconnection/nitro-web
tags: latest
path: Human-Connection/webapp/
push: false
- name: Build neo4j customized image
uses: docker/build-push-action@v1.1.0
with:
repository: schoolsinmotion/neo4j
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
tags: latest
path: neo4j/
cache_from: humanconnection/neo4j:latest
push: false
- name: Build backend customized image
uses: docker/build-push-action@v1.1.0
with:
repository: schoolsinmotion/backend
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
tags: latest
path: backend/
cache_from: humanconnection/backend:build-and-test
push: false
- name: Build webapp customized image
uses: docker/build-push-action@v1.1.0
with:
repository: schoolsinmotion/webapp
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
tags: latest
path: webapp/
cache_from: humanconnection/webapp:build-and-test
push: false