Skip to content

Changes how config management works in hiccup (#59) #6

Changes how config management works in hiccup (#59)

Changes how config management works in hiccup (#59) #6

Workflow file for this run

name: Release Workflow
on:
push:
tags:
- 'v*' # Matches tags starting with 'v'
jobs:
release:
name: Release
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: '14.x'
- name: Install dependencies
run: npm install
- name: Get Package Version
id: get_package_version
run: echo "VERSION=$(node -p "require('./package.json').version")" >> $GITHUB_ENV
- name: Build
run: npm run build
- name: Log in to Docker Hub
run: docker login -u bleckbeard -p ${{ secrets.DOCKER_ACCESS_TOKEN }}
- name: Build and push Docker image
run: |
VERSION=${{ env.VERSION }}
echo "Building docker image"
docker build -t bleckbeard/hiccup:latest .
docker tag bleckbeard/hiccup:latest bleckbeard/hiccup:v$VERSION
echo "Pushing it to the hub"
docker push bleckbeard/hiccup:latest
docker push bleckbeard/hiccup:v$VERSION
- name: Zip build artifacts
run: zip -r hiccup@$VERSION.zip ./build/
- name: Create Release
id: create_release
uses: softprops/action-gh-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
draft: false
prerelease: false
generate_release_notes: true
files: |
hiccup@${{ env.VERSION }}.zip