Skip to content

Commit

Permalink
first attempt at action
Browse files Browse the repository at this point in the history
  • Loading branch information
gonuke committed Apr 10, 2024
1 parent 04a0ebe commit 8092cbe
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 1 deletion.
54 changes: 54 additions & 0 deletions .github/workflows/docker_publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: Build & Publish docker image for ParaStell CI

on:
# allows us to run workflows manually
workflow_dispatch:
push:
paths:
- 'Dockefile'
- '.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@v2
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Checkout repository
uses: actions/checkout@v4

- 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
tags: ghcr.io/svalinn/parstell:ci-testing

test-dependency-img:
runs-on: ghcr.io/svalinn/parastell:ci-testing

name: Testing CI image
steps:
- name: populate environment
run: |
echo "rlmSERVER=${{ secrets.rlmSERVER }}" >> "$GITHUB_ENV"
echo "rlmPASSWD=${{ secrets.rlmPASSWORD}}" >> "$GITHUB_ENV"
- name: test secrets
run: |
echo "${rlmSERVER}"
echo "${rlmPASSWORD}"
sed -e "s/@SERVER@/${rlmSERVER}/" /opt/Coreform-Cubit-2023.11/bin/licenses/rlmcloud.in
2 changes: 1 addition & 1 deletion dockerfile → Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ RUN wget -O /cubit.deb https://f002.backblazeb2.com/file/cubit-downloads/Corefor
# install cubit
RUN dpkg -i cubit.deb
ENV PYTHONPATH=/opt/Coreform-Cubit-2023.11/bin/
COPY ./rlmcloud.in /opt/Coreform-Cubit-2023.11/bin/licenses
COPY ./rlmcloud.in /opt/Coreform-Cubit-2023.11/bin/licenses/rlmcloud.in

# parastell env
COPY ./environment.yml /environment.yml
Expand Down

0 comments on commit 8092cbe

Please sign in to comment.