chore: fixing express static's weird behaviour when trying to serve index.html #14
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Server | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
build: | |
permissions: write-all | |
runs-on: ubuntu-latest | |
steps: | |
- name: Prepare - Checkout | |
uses: actions/[email protected] | |
- name: Prepare - Inject short Variables | |
uses: rlespinasse/[email protected] | |
- name: Prepare - Set up Docker Buildx | |
uses: docker/[email protected] | |
- name: Build - BUILD | |
uses: docker/[email protected] | |
with: | |
load: true | |
cache-from: type=gha | |
cache-to: type=gha,mode=max | |
tags: on-local | |
- name: Publish - Calculate Version | |
if: github.event_name != 'pull_request' | |
env: | |
BUILD_NUMBER: ${{ github.run_number }} | |
run: | | |
echo "BUILD_NUMBER=$(($BUILD_NUMBER))" >> $GITHUB_ENV | |
- name: Publish - Login to Docker Hub | |
if: github.event_name != 'pull_request' | |
uses: docker/login-action@v3 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Publish - Rename Tags | |
if: github.event_name != 'pull_request' | |
run: | | |
docker tag on-local ghcr.io/mydraft-cc/server2:dev | |
docker tag on-local ghcr.io/mydraft-cc/server2:dev-${{ env.BUILD_NUMBER }} | |
- name: Publish - Push Tags | |
if: github.event_name != 'pull_request' | |
run: | | |
docker push ghcr.io/mydraft-cc/server2:dev | |
docker push ghcr.io/mydraft-cc/server2:dev-${{ env.BUILD_NUMBER }} |