Skip to content

Commit

Permalink
Push test + adding rename step
Browse files Browse the repository at this point in the history
  • Loading branch information
nataliejschultz committed May 26, 2024
1 parent c58b5dd commit 14775b5
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 7 deletions.
4 changes: 2 additions & 2 deletions .github/fetch_runID.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
For e-mission-server: id = 35580278
'''

download_url = "https://api.github.com/repos/e-mission/e-mission-server/actions/workflows/35580278/runs"
download_url = "https://api.github.com/repos/MukuFlash03/e-mission-server/actions/workflows/75506902/runs"
logging.debug("About to fetch workflow runs present in docker image workflow present in e-mission-server from %s" % download_url)
r = requests.get(download_url)
if r.status_code != 200:
Expand All @@ -33,7 +33,7 @@
successful_runs = [run for run in workflow_runs \
if run["status"] == "completed" and \
run["conclusion"] == "success" and \
run["head_branch"] == "main"
run["head_branch"] == "consolidate-differences"
]
if successful_runs:
sorted_runs = successful_runs.sort(reverse=True, key=lambda x: x["updated_at"])
Expand Down
11 changes: 8 additions & 3 deletions .github/workflows/image_build_push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -130,13 +130,18 @@ jobs:
- name: build docker image
run: |
if [ "${{ github.event_name }}" == "workflow_dispatch" ]; then
SERVER_IMAGE_TAG=$DOCKER_IMAGE_TAG_2 FRONTEND_TAG=$DOCKER_USER/${GITHUB_REPOSITORY#*/}:${GITHUB_REF##*/}_${{ steps.date.outputs.date }} VIZ_TAG=$DOCKER_USER/${GITHUB_REPOSITORY#*/}_notebook:${GITHUB_REF##*/}_${{ steps.date.outputs.date }} docker compose -f docker-compose.yml build
SERVER_IMAGE_TAG=$DOCKER_IMAGE_TAG_2 docker compose -f docker-compose-dev.yml build
else
SERVER_IMAGE_TAG=$DOCKER_IMAGE_TAG_1 FRONTEND_TAG=$DOCKER_USER/${GITHUB_REPOSITORY#*/}:${GITHUB_REF##*/}_${{ steps.date.outputs.date }} VIZ_TAG=$DOCKER_USER/${GITHUB_REPOSITORY#*/}_notebook:${GITHUB_REF##*/}_${{ steps.date.outputs.date }} docker compose -f docker-compose.yml build
SERVER_IMAGE_TAG=$DOCKER_IMAGE_TAG_1 docker compose -f docker-compose-dev.yml build
fi
docker images
- name: push docker image
- name: rename docker images
run: |
docker image tag em-pub-dash-dev/frontend:latest $DOCKER_USER/${GITHUB_REPOSITORY#*/}:${GITHUB_REF##*/}_${{ steps.date.outputs.date }}
docker image tag em-pub-dash-dev/viz-scripts:latest $DOCKER_USER/${GITHUB_REPOSITORY#*/}_notebook:${GITHUB_REF##*/}_${{ steps.date.outputs.date }}
- name: push docker images
run: |
docker push $DOCKER_USER/${GITHUB_REPOSITORY#*/}:${GITHUB_REF##*/}_${{ steps.date.outputs.date }}
docker push $DOCKER_USER/${GITHUB_REPOSITORY#*/}_notebook:${GITHUB_REF##*/}_${{ steps.date.outputs.date }}
Expand Down
4 changes: 2 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
version: "3"
services:
dashboard:
image: ${FRONTEND_TAG}
image: em-pub-dash-prod/frontend
build: frontend
depends_on:
- db
Expand All @@ -13,7 +13,7 @@ services:
networks:
- emission
notebook-server:
image: ${VIZ_TAG}
image: em-pub-dash-prod/viz-scripts
build:
context: viz_scripts
dockerfile: Dockerfile
Expand Down

0 comments on commit 14775b5

Please sign in to comment.