Skip to content

Minor CSS change

Minor CSS change #21

Workflow file for this run

name: Build and Deploy
on:
push:
branches: [ develop, master ]
pull_request:
branches: [ develop, master ]
release:
types:
- published
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 5.0.100
- name: Restore
run: dotnet restore src/Giraffe.Website/Giraffe.Website.fsproj
- name: Build
run: dotnet build --configuration Release --no-restore src/Giraffe.Website/Giraffe.Website.fsproj
deploy:
needs: build
if: github.event_name == 'release'
runs-on: ubuntu-latest
env:
PROJECT: giraffefsharp
IMAGE: giraffe-website
steps:
# Checkout repo
- name: Checkout
uses: actions/checkout@v2
# Build the Docker image
- name: Build Docker image
run: |
PATTERN="refs/tags/v"
SUB=""
TAG="${GITHUB_REF/$PATTERN/$SUB}"
docker build --build-arg version=$TAG -t "$PROJECT"/"$IMAGE":"$TAG" -f src/Giraffe.Website/Dockerfile .
# Auth with Docker Hub
- name: Login to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_ACCESS_TOKEN }}
# Push the Docker image to Docker Hub
- name: Publish Docker image
run: |
PATTERN="refs/tags/v"
SUB=""
TAG="${GITHUB_REF/$PATTERN/$SUB}"
docker push $PROJECT/$IMAGE:$TAG