Skip to content

Commit

Permalink
update github workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Roman Andriushchenko committed Sep 20, 2024
1 parent ed86b17 commit 5b16207
Showing 1 changed file with 26 additions and 25 deletions.
51 changes: 26 additions & 25 deletions .github/workflows/buildtest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
push:
branches:
- master
- mdp
schedule:
# run weekly
- cron: '0 10 * * 3'
Expand All @@ -28,40 +29,40 @@ jobs:
buildType:
- {name: "Release", imageName : "randriu/paynt", dockerTag: "latest", setupArgs: ""}
fail-fast: false
if: github.ref == 'refs/heads/master'
steps:
- name: Git clone
uses: actions/checkout@v4
- name: Build paynt image from Dockerfile
run: docker build -t ${{ matrix.buildType.imageName }}:${{ matrix.buildType.dockerTag }} . --build-arg setup_args=${{ matrix.buildType.setupArgs }} --build-arg setup_args_pycarl=${{ matrix.buildType.setupArgs }} --build-arg no_threads=${NR_JOBS}
- name: Login into docker
# Only login if using master on original repo (and not for pull requests or forks)
if: github.repository_owner == 'randriu' && github.ref == 'refs/heads/master'
if: github.repository_owner == 'randriu'
run: echo '${{ secrets.STORMPY_CI_DOCKER_PASSWORD }}' | docker login -u randriu --password-stdin
- name: Deploy paynt image
# Only deploy if using master on original repo (and not for pull requests or forks)
if: github.repository_owner == 'randriu' && github.ref == 'refs/heads/master'
if: github.repository_owner == 'randriu'
run: docker push ${{ matrix.buildType.imageName }}:${{ matrix.buildType.dockerTag }}

# deploy-learning:
# name: Deploy on latest with learning dependencies (${{ matrix.buildType.name }})
# runs-on: ubuntu-latestx
# strategy:
# matrix:
# buildType:
# - {name: "Release", imageName : "randriu/paynt", dockerTag: "latest", setupArgs: ""}
# fail-fast: false
# steps:
# - name: Git clone
# uses: actions/checkout@v4
# - name: Build paynt image from Dockerfile
# run: docker build -t ${{ matrix.buildType.imageName }}:${{ matrix.buildType.dockerTag }} . --build-arg setup_args=${{ matrix.buildType.setupArgs }} --build-arg setup_args_pycarl=${{ matrix.buildType.setupArgs }} --build-arg no_threads=${NR_JOBS}
# - name: Build paynt image with learner dependencies
# run: docker build -t ${{ matrix.buildType.imageName }}-learner:${{ matrix.buildType.dockerTag }} . -f paynt-learner.dockerfile --build-arg paynt_base=${{ matrix.buildType.imageName }}:${{ matrix.buildType.dockerTag }}
# - name: Login into docker
# # Only login if using master on original repo (and not for pull requests or forks)
# if: github.repository_owner == 'randriu' && github.ref == 'refs/heads/master'
# run: echo '${{ secrets.STORMPY_CI_DOCKER_PASSWORD }}' | docker login -u randriu --password-stdin
# - name: Deploy paynt image with learner dependencies
# # Only deploy if using master on original repo (and not for pull requests or forks)
# if: github.repository_owner == 'randriu' && github.ref == 'refs/heads/master'
# run: docker push ${{ matrix.buildType.imageName }}-learner:${{ matrix.buildType.dockerTag }}
deploy-mdp:
name: Deploy on latest (mdp) (${{ matrix.buildType.name }})
runs-on: ubuntu-latest
strategy:
matrix:
buildType:
- {name: "Release", imageName : "randriu/paynt", dockerTag: "mdp", setupArgs: ""}
fail-fast: false
if: github.ref == 'refs/heads/mdp'
steps:
- name: Git clone
uses: actions/checkout@v4
- name: Build paynt image from Dockerfile
run: docker build -t ${{ matrix.buildType.imageName }}:${{ matrix.buildType.dockerTag }} . --build-arg setup_args=${{ matrix.buildType.setupArgs }} --build-arg setup_args_pycarl=${{ matrix.buildType.setupArgs }} --build-arg no_threads=${NR_JOBS}
- name: Login into docker
# Only login if using mdp on original repo (and not for pull requests or forks)
if: github.repository_owner == 'randriu'
run: echo '${{ secrets.STORMPY_CI_DOCKER_PASSWORD }}' | docker login -u randriu --password-stdin
- name: Deploy paynt image
# Only deploy if using mdp on original repo (and not for pull requests or forks)
if: github.repository_owner == 'randriu'
run: docker push ${{ matrix.buildType.imageName }}:${{ matrix.buildType.dockerTag }}

0 comments on commit 5b16207

Please sign in to comment.