-
Notifications
You must be signed in to change notification settings - Fork 0
31 lines (23 loc) · 1.02 KB
/
package.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
name: rojen/amusewiki:package
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Docker Login
env:
DOCKER_USER: ${{secrets.DOCKER_USER}}
DOCKER_PASSWORD: ${{secrets.DOCKER_PASSWORD}}
run: |
docker login -u $DOCKER_USER -p $DOCKER_PASSWORD
- name: Build the Docker image version
run: docker build package/ --file package/Dockerfile.getversion --tag amw_version
- name: Build the Docker image
run: docker build package/ --file package/Dockerfile --tag rojen/amusewiki:latest --tag rojen/amusewiki:package --tag rojen/amusewiki:package-$(docker run amw_version) --build-arg AMW_WORKERS=5 --build-arg AMW_NPROC=5 --build-arg AMW_USERNAME=amusewiki --build-arg AMW_PASSWORD=changeme
- name: Docker Push
run: docker push rojen/amusewiki:package; docker push rojen/amusewiki:latest; docker push rojen/amusewiki:package-$(docker run amw_version)