Skip to content
This repository has been archived by the owner on Dec 5, 2023. It is now read-only.

Commit

Permalink
Merge pull request #37 from elieser1101/add-github-actions
Browse files Browse the repository at this point in the history
initial github actions workflow
  • Loading branch information
elieser1101 authored Nov 12, 2020
2 parents 69b5cc6 + 0141a69 commit 2616b7f
Showing 1 changed file with 51 additions and 0 deletions.
51 changes: 51 additions & 0 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: ci

on:
push:
branches:
- "*" # run for branches
tags:
- "*" # run for tags
pull_request:
branches:
- "*" # run for branches
tags:
- "*" # run for tags

jobs:
test:
runs-on: ubuntu-latest
env:
GROUP: weaveworksdemos
COMMIT: ${{ github.sha }}
REPO: carts
steps:
- uses: actions/checkout@v2


- name: Set up JDK 1.8
uses: actions/setup-java@v1
with:
java-version: 1.8

#
#
# Build
- name: Build jar files
run: ./scripts/build.sh

#
#
# Push to dockerhub
- name: Push to Docker Hub
uses: docker/build-push-action@v1
if: startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/master'
with:
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_PASS }}
repository: ${{ env.GROUP }}/${{ env.REPO }}
tag_with_ref: true
tag_with_sha: true
path: docker/carts
dockerfile: docker/carts/Dockerfile

0 comments on commit 2616b7f

Please sign in to comment.