Merge pull request 'Change dispatch to pull req' (#3) from testing into main

Reviewed-on: #3
This commit is contained in:
Skylar Grant 2023-08-04 09:52:53 -07:00
commit dd313faa60

View File

@ -1,7 +1,7 @@
name: Silvanus Production Dockerization name: Silvanus Production Dockerization
on: on:
merge: pull_request:
branches: branches:
- main - main
@ -13,13 +13,23 @@ jobs:
build: build:
runs-on: ubuntu-latest runs-on: self-hosted
steps: steps:
- uses: actions/checkout@v3 - name: Pull latest from Git
- name: Build the Docker image v0idf1sh/silvanus run: |
run: docker build . --file Dockerfile --tag v0idf1sh/silvanus pwd
whoami
cd /root/silvanus
git pull
git checkout $GITHUB_HEAD_REF
- name: Build the Docker image
run: |
cd /root/silvanus
docker build . --file Dockerfile --tag v0idf1sh/silvanus
- name: Log into Docker Hub - name: Log into Docker Hub
run: docker login -u $DHUB_UNAME -p $DHUB_PWORD run: docker login -u $DHUB_UNAME -p $DHUB_PWORD
- name: Push image to Docker Hub v0idf1sh/silvanus - name: Push image to Docker Hub
run: docker push v0idf1sh/silvanus run: |
cd /root/silvanus
docker push v0idf1sh/silvanus