Skip to content
This repository has been archived by the owner on Jul 23, 2024. It is now read-only.

Commit

Permalink
feat: add release manual action
Browse files Browse the repository at this point in the history
This is not to replace the current work, is to avoid the pain suffered
over the last releases where things didn't work as good as expected.

Manual workflow, triggered manually, to release it. As I said, not
perfect, but want to reduce the current friction.

Signed-off-by: Eloy Coto <eloy.coto@acalustra.com>
  • Loading branch information
eloycoto committed Jun 16, 2023
1 parent fe03390 commit 0b09dd0
Show file tree
Hide file tree
Showing 3 changed files with 64 additions and 3 deletions.
61 changes: 61 additions & 0 deletions .github/workflows/release_manual.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: Release new version

on:
workflow_dispatch:

permissions:
pull-requests: write
contents: write

jobs:
release:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v3

- uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '17'

- name: "Git config"
run: |
git config user.name 'Parodos bot'
git config user.email 'parodos@redhat.com'
- name: Configure Maven settings
run: |
mkdir -p ~/.m2/
echo "<settings><servers><server><id>ossrh</id><username>${{ secrets.MAVEN_USER }}</username><password>${{ secrets.MAVEN_PASSWORD }}</password></server></servers></settings>" > ~/.m2/settings.xml
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
registry: "quay.io"
username: "${{ secrets.QUAY_GITHUB_USER }}"
password: "${{ secrets.QUAY_GITHUB_TOKEN }}"

- name: Import GPG secret key
run: |
mkdir -p ~/.gnupg/
echo "${{ secrets.GPG }}" | base64 --decode > ~/.gnupg/private.key
gpg --batch --import ~/.gnupg/private.key
- name: "Do the release"
run: |
make release-all
- name: "Commit the new changes"
run: |
export KEY=$(date +%y%m%d)
git add .
git commit -m "NON-issue: bump version on $KEY"
- name: Create Pull Request
uses: peter-evans/create-pull-request@v5
with:
title: "NON-issue: bump version"
4 changes: 2 additions & 2 deletions notification-service/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ FROM registry.access.redhat.com/ubi9/openjdk-17-runtime

WORKDIR /app

COPY target/*.jar ./notification-service.jar
COPY target/notification-service-*.*.*[^a-z].jar ./notification-service.jar

EXPOSE 8080

ENTRYPOINT ["java","-jar","-Djava.security.egd=file:/dev/./urandom", "notification-service.jar"]
ENTRYPOINT ["java","-jar","-Djava.security.egd=file:/dev/./urandom", "notification-service.jar"]
2 changes: 1 addition & 1 deletion workflow-service/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ FROM registry.access.redhat.com/ubi9/openjdk-17-runtime

WORKDIR /app

COPY workflow-service/target/*.jar ./workflow-service.jar
COPY workflow-service/target/workflow-service-*.*.*[^a-z].jar ./workflow-service.jar
COPY workflow-examples/target/*jar-with-dependencies.jar ./workflow-examples.jar

EXPOSE 8080
Expand Down

0 comments on commit 0b09dd0

Please sign in to comment.