Skip to content

Commit

Permalink
Merge pull request #238 from sixwaaaay/tag
Browse files Browse the repository at this point in the history
feat: update build
  • Loading branch information
sixwaaaay authored Jan 9, 2024
2 parents e0559fd + cda2d5d commit 87fc9ff
Show file tree
Hide file tree
Showing 3 changed files with 49 additions and 8 deletions.
7 changes: 6 additions & 1 deletion .github/workflows/comment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,14 @@ name: Comment
on:
push:
branches:
- '*'
- 'main'
paths:
- 'graal/**'
tags:
- ''
pull_request:
paths:
- 'graal/**'
jobs:
test:
runs-on: ubuntu-latest
Expand Down
41 changes: 38 additions & 3 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,15 @@ on:
jobs:
release:
runs-on: ubuntu-latest
strategy:
matrix:
include:
- context: ./cmd/shauser
file: ./cmd/shauser/Dockerfile
tag: shauser
- context: ./sharp/content
file: ./sharp/content/Dockerfile
tag: content
steps:
- uses: actions/checkout@v3
- name: Login to DockerHub
Expand All @@ -29,7 +38,33 @@ jobs:
- name: Build and push
uses: docker/build-push-action@v5
with:
context: ./cmd/shauser
file: ./cmd/shauser/Dockerfile
context: ${{ matrix.context }}
file: ${{ matrix.file }}
push: true
tags: ${{ secrets.DOCKERHUB_USERNAME || 'app' }}/shauser:${{ github.ref_name }}
tags: ${{ secrets.DOCKERHUB_USERNAME || 'app' }}/${{ matrix.tag }}:${{ github.ref_name }}
graal:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./graal
if: github.ref == 'refs/heads/main'
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: graalvm/setup-graalvm@v1
with:
java-version: '21'
distribution: 'graalvm' # See 'Options' for all available distributions
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Native Image Build
run: mvn -Pnative spring-boot:build-image -DskipTests

- uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Push to Docker Hub
run: |
docker tag sharing-comment:0.0.1-SNAPSHOT ${{ secrets.DOCKERHUB_USERNAME }}/sharing-comment:${{ github.ref_name }}
docker push ${{ secrets.DOCKERHUB_USERNAME }}/sharing-comment:${{ github.ref_name }}
9 changes: 5 additions & 4 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,11 @@ Sharing Has An Relly Interesting Name
[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fsixwaaaay%2Fsharing.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2Fsixwaaaay%2Fsharing?ref=badge_shield)
[![Apache 2.0](https://img.shields.io/github/license/sixwaaaay/sharing)](https://github.com/sixwaaaay/sharing/blob/main/LICENSE)

| name | CI | coverage | size | version |
|---------|--------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------|
| users | [![CI](https://github.com/sixwaaaay/sharing/actions/workflows/users.yaml/badge.svg)](https://github.com/sixwaaaay/sharing/actions/workflows/users.yaml) | [![codecov](https://codecov.io/gh/sixwaaaay/sharing/branch/main/graph/badge.svg?flag=users)](https://codecov.io/gh/sixwaaaay/sharing) | [![Container Image Size](https://img.shields.io/docker/image-size/sixwaaaay/shauser?sort=semver)](https://hub.docker.com/r/sixwaaaay/shauser) | [![Docker Image Version (latest semver)](https://img.shields.io/docker/v/sixwaaaay/shauser?sort=semver)](https://hub.docker.com/r/sixwaaaay/shauser) |
| content | [![CI](https://github.com/sixwaaaay/sharing/actions/workflows/content.yaml/badge.svg)](https://github.com/sixwaaaaay/sharing/actions/workflows/content.yaml) | [![codecov](https://codecov.io/gh/sixwaaaay/sharing/branch/main/graph/badge.svg?flag=content)](https://codecov.io/gh/sixwaaaay/sharing) | [![Container Image Size](https://img.shields.io/docker/image-size/sixwaaaay/content?sort=semver)](https://hub.docker.com/r/sixwaaaay/content) | [![Docker Image Version (latest semver)](https://img.shields.io/docker/v/sixwaaaay/content?sort=semver)](https://hub.docker.com/r/sixwaaaay/content) |
| name | CI | coverage | size | version |
|---------|--------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| users | [![CI](https://github.com/sixwaaaay/sharing/actions/workflows/users.yaml/badge.svg)](https://github.com/sixwaaaay/sharing/actions/workflows/users.yaml) | [![codecov](https://codecov.io/gh/sixwaaaay/sharing/branch/main/graph/badge.svg?flag=users)](https://codecov.io/gh/sixwaaaay/sharing) | [![Container Image Size](https://img.shields.io/docker/image-size/sixwaaaay/shauser?sort=semver)](https://hub.docker.com/r/sixwaaaay/shauser) | [![Docker Image Version (latest semver)](https://img.shields.io/docker/v/sixwaaaay/shauser?sort=semver)](https://hub.docker.com/r/sixwaaaay/shauser) |
| content | [![CI](https://github.com/sixwaaaay/sharing/actions/workflows/content.yaml/badge.svg)](https://github.com/sixwaaaaay/sharing/actions/workflows/content.yaml) | [![codecov](https://codecov.io/gh/sixwaaaay/sharing/branch/main/graph/badge.svg?flag=content)](https://codecov.io/gh/sixwaaaay/sharing) | [![Container Image Size](https://img.shields.io/docker/image-size/sixwaaaay/content?sort=semver)](https://hub.docker.com/r/sixwaaaay/content) | [![Docker Image Version (latest semver)](https://img.shields.io/docker/v/sixwaaaay/content?sort=semver)](https://hub.docker.com/r/sixwaaaay/content) |
| comment | [![CI](https://github.com/sixwaaaay/sharing/actions/workflows/comment.yaml/badge.svg)](https://github.com/sixwaaaaay/sharing/actions/workflows/comment.yaml) | [![codecov](https://codecov.io/gh/sixwaaaay/sharing/branch/main/graph/badge.svg?flag=comments)](https://codecov.io/gh/sixwaaaay/sharing) | [![Container Image Size](https://img.shields.io/docker/image-size/sixwaaaay/sharing-comment?sort=semver)](https://hub.docker.com/r/sixwaaaay/sharing-comment) | [![Docker Image Version (latest semver)](https://img.shields.io/docker/v/sixwaaaay/sharing-comment?sort=semver)](https://hub.docker.com/r/sixwaaaay/sharing-comment) |

## License

Expand Down

0 comments on commit 87fc9ff

Please sign in to comment.