Skip to content

update las2peer package #49

update las2peer package

update las2peer package #49

Workflow file for this run

name: Docker Build and Push
on:
push:
branches: [ master, develop ]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up JDK 17
uses: actions/setup-java@v1
with:
java-version: 17
- name: Set up MySQL
run: |
sudo /etc/init.d/mysql start
mysql -e 'CREATE DATABASE LAS2PEERMON;' -uroot -proot
- name: Create db tables
run: mysql -u root -proot LAS2PEERMON < etc/create_database.sql
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Copy properties file
run: cp etc/i5.las2peer.services.mobsos.dataProcessing.MobSOSDataProcessingService.properties.sample etc/i5.las2peer.services.mobsos.dataProcessing.MobSOSDataProcessingService.properties
- name: Run tests with Gradle
run: ./gradlew test --info --stacktrace
build:
needs: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Extract branch name
shell: bash
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})"
id: extract_branch
- name: Build the Docker image
run: |
docker build -t registry.tech4comp.dbis.rwth-aachen.de/rwthacis/mobsos-data-processing:${{ steps.extract_branch.outputs.branch }} .
- name: Push to registry
env:
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PW: ${{ secrets.DOCKER_PW }}
run: |
docker login -u $DOCKER_USERNAME -p $DOCKER_PW registry.tech4comp.dbis.rwth-aachen.de
docker push registry.tech4comp.dbis.rwth-aachen.de/rwthacis/mobsos-data-processing:${{ steps.extract_branch.outputs.branch }}