-
Notifications
You must be signed in to change notification settings - Fork 12
60 lines (51 loc) · 1.77 KB
/
docker_publish.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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
name: Build & Publish docker image for ParaStell CI
on:
# allows us to run workflows manually
workflow_dispatch:
push:
paths:
- 'Dockerfile'
- '.github/workflows/docker_publish.yml'
jobs:
build-dependency-img:
runs-on: ubuntu-latest
name: Installing Dependencies and ParaStell
steps:
- name: Log in to the Container registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build, Test, and Push ParaStell
id: build-parastell
uses: docker/build-push-action@v5
with:
cache-from: type=registry,ref=ghcr.io/svalinn/parastell:ci-layer-cache
cache-to: type=registry,ref=ghcr.io/svalinn/parastell:ci-layer-cache,mode=max
file: Dockerfile
push: true
target: parastell-deps
tags: ghcr.io/svalinn/parastell-ci
test-dependency-img:
needs: build-dependency-img
runs-on: ubuntu-latest
container: ghcr.io/svalinn/parastell-ci
name: Testing CI image
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: populate environment
run: |
. /opt/etc/bashrc
sed -e "s/@SERVER@/${rlmSERVER}/" -e "s/@PASSWORD@/${rlmPASSWD}/" /opt/Coreform-Cubit-2023.11/bin/licenses/rlmcloud.in > /opt/Coreform-Cubit-2023.11/bin/licenses/rlmcloud.lic
export PYTHONPATH=${PYTHONPATH}:`pwd`
cd tests
pytest -v .
env:
rlmSERVER: ${{ secrets.RLMSERVER }}
rlmPASSWD: ${{ secrets.RLMPASSWORD }}