Configure Github actions to build base images

This commit is contained in:
roschaefer 2020-06-08 14:17:47 +02:00
parent 178e8fe1bb
commit 0a6c222a95
4 changed files with 36 additions and 26 deletions

View File

@ -13,29 +13,53 @@ jobs:
uses: actions/checkout@v2
with:
submodules: recursive
- name: Rebrand
run: cp -r webapp/* fyphe_O/webapp/
- name: Build neo4j
- 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/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/webapp
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: fyphe_O/neo4j/
- name: Build backend
path: neo4j/
push: true
- 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: fyphe_O/backend/
- name: Build webapp
path: backend/
push: true
- 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: fyphe_O/webapp/
path: webapp/
push: true

3
.gitmodules vendored
View File

@ -0,0 +1,3 @@
[submodule "Human-Connection"]
path = Human-Connection
url = https://github.com/The-Schools-in-Motion-Network/fyphe_O.git

1
Human-Connection Submodule

@ -0,0 +1 @@
Subproject commit 73c1f3c88bd13ecfd520b76bb396e4ec460f9d79

View File

@ -3,8 +3,6 @@ version: "3.4"
services:
webapp:
image: schoolsinmotion/webapp:latest
build:
context: webapp
ports:
- 3000:3000
- 3002:3002
@ -12,8 +10,6 @@ services:
- hc-network
depends_on:
- backend
volumes:
- webapp_node_modules:/webapp/node_modules
environment:
- HOST=0.0.0.0
- GRAPHQL_URI=http://backend:4000
@ -22,17 +18,12 @@ services:
command: yarn run dev
backend:
image: schoolsinmotion/backend:latest
build:
context: backend
networks:
- hc-network
depends_on:
- neo4j
ports:
- 4000:4000
volumes:
- backend_node_modules:/backend/node_modules
- uploads:/backend/public/uploads
environment:
- NEO4J_URI=bolt://neo4j:7687
- GRAPHQL_URI=http://backend:4000
@ -47,8 +38,6 @@ services:
command: yarn run dev
neo4j:
image: schoolsinmotion/neo4j:latest
build:
context: neo4j
networks:
- hc-network
environment:
@ -58,12 +47,5 @@ services:
ports:
- 7687:7687
- 7474:7474
volumes:
- neo4j_data:/data
networks:
hc-network:
volumes:
webapp_node_modules:
backend_node_modules:
neo4j_data:
uploads: