feat: implement new georchestra header #50
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: Build | |
on: | |
push: | |
branches: | |
- georchestra-datafeeder | |
tags: | |
- '*' | |
jobs: | |
build: | |
if: github.repository == 'georchestra/geonetwork-ui' | |
runs-on: ubuntu-latest | |
timeout-minutes: 10 | |
steps: | |
- name: 'Checking out' | |
uses: actions/checkout@v1 | |
- name: Install dependencies | |
run: npm ci | |
- name: Getting image tag | |
if: github.repository == 'georchestra/geonetwork-ui' | |
id: version | |
run: echo ::set-output name=VERSION::$(echo $GITHUB_REF | cut -d / -f 3) | |
- name: 'Building docker image' | |
if: github.repository == 'georchestra/geonetwork-ui' | |
run: npx nx docker-build datafeeder | |
- name: 'Logging in to docker.io' | |
if: github.repository == 'georchestra/geonetwork-ui' | |
uses: azure/docker-login@v1 | |
with: | |
username: '${{ secrets.DOCKER_HUB_USERNAME }}' | |
password: '${{ secrets.DOCKER_HUB_PASSWORD }}' | |
- name: 'Pushing latest docker image onto docker.io' | |
if: github.ref == 'refs/heads/georchestra-datafeeder' && github.repository == 'georchestra/geonetwork-ui' | |
run: | | |
docker push georchestra/datafeeder-frontend:latest | |
- name: 'Pushing release docker image to docker.io' | |
if: contains(github.ref, 'refs/tags/') && github.repository == 'georchestra/geonetwork-ui' | |
run: | | |
docker tag georchestra/datafeeder-frontend:latest georchestra/datafeeder-frontend:${{ steps.version.outputs.VERSION }} | |
docker push georchestra/datafeeder-frontend:${{ steps.version.outputs.VERSION }} |