Skip to content

Refactoring

Refactoring #177

name: Deploy Develop on fxsr server
on:
push:
branches: [ develop ]
jobs:
build:
name: Build and Push Docker Image
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: 'Login to Docker Registry'
run: echo ${{ secrets.REGISTRY_PASSWORD }} | docker login -u ${{ secrets.REGISTRY_USERNAME }} --password-stdin
- name: Extract version from package.json
id: get_version
run: |
VERSION=$(jq -r '.version' package.json)
echo "VERSION=$VERSION" >> $GITHUB_ENV
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build Inventory Image
run: |
docker build . --tag fxsrdocker/eckwerkstuttgart:${{ env.VERSION }}
docker push fxsrdocker/eckwerkstuttgart:${{ env.VERSION }}
- name: Cache docker-compose.yml
uses: actions/cache@v3
with:
path: docker-compose.yml
key: ${{ runner.os }}-docker-compose-${{ github.sha }}
restore-keys: |
${{ runner.os }}-docker-compose-