* (#146) Re-wrote the docker code to generate a single self-contained docker image rather than using a docker-compose network of connected containers * (#146) Push version tags to docker hub automatically * (#146) Switched to using a multistage docker build process to make the Dockerfile more readable and cache friendly without bloating the published image * #146 More readable names * #146 Documented the upgrade process and made 'artisan migrate' run on every boot to automate the upgrade process.
This commit is contained in:
26
.github/workflows/dockerhub.yml
vendored
Normal file
26
.github/workflows/dockerhub.yml
vendored
Normal file
@@ -0,0 +1,26 @@
|
||||
name: Publish Docker image
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- "v*"
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Get tag name
|
||||
run: ( echo "TAG_NAME=${GITHUB_REF#refs/*/v}"; echo "DOCKER_REPO=${{secrets.DOCKER_REPO}}") >> $GITHUB_ENV
|
||||
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Log in to Docker Hub
|
||||
run: docker login -u "${{ secrets.DOCKER_USERNAME }}" -p "${{ secrets.DOCKER_ACCESS_TOKEN }}"
|
||||
|
||||
- name: Build docker image
|
||||
run: docker build . -t $DOCKER_REPO:latest -t $DOCKER_REPO:$TAG_NAME
|
||||
|
||||
- name: Push Docker image
|
||||
run: docker push $DOCKER_REPO:latest && docker push $DOCKER_REPO:$TAG_NAME
|
||||
Reference in New Issue
Block a user