-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2de0d9b
commit f603e98
Showing
8 changed files
with
192 additions
and
16 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
name: "Checks" | ||
|
||
on: | ||
workflow_call: | ||
outputs: | ||
client-goat: | ||
description: "Client goat changed" | ||
value: ${{ jobs.checks.outputs.client-goat }} | ||
|
||
keycloak-theme: | ||
description: "Keycloak theme changed" | ||
value: ${{ jobs.checks.outputs.keycloak-theme }} | ||
|
||
storybook: | ||
description: "Storybook changed" | ||
value: ${{ jobs.checks.outputs.storybook }} | ||
|
||
sha-short: | ||
description: "Short sha" | ||
value: ${{ jobs.checks.outputs.sha-short }} | ||
|
||
jobs: | ||
checks: | ||
name: checks | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 3 | ||
permissions: | ||
pull-requests: read | ||
contents: read | ||
steps: | ||
- name: 📥 Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: 📥 Checkout PR | ||
uses: ./.github/actions/pr-git-checkout | ||
|
||
- name: 🕵️ Detect changes | ||
uses: dorny/paths-filter@v2 | ||
id: changes | ||
with: | ||
filters: | | ||
client-goat: | ||
- 'apps/goat/**' | ||
- 'packages/**' | ||
- '.prettier*' | ||
- 'pnpm-lock.yaml' | ||
keycloak-theme: | ||
- 'packages/keycloak-theme/**' | ||
- 'packages/eslint-config-p4b/**' | ||
- 'packages/prettier-config/**' | ||
- 'packages/tsconfig/**' | ||
- 'packages/types/**' | ||
- 'packages/ui/**' | ||
- '.prettier*' | ||
- 'pnpm-lock.yaml' | ||
storybook: | ||
- 'apps/storybook/**' | ||
- 'packages/ui/**' | ||
- 'packages/eslint-config-p4b/**' | ||
- 'packages/prettier-config/**' | ||
- 'packages/tsconfig/**' | ||
- 'packages/types/**' | ||
- '.prettier*' | ||
- 'pnpm-lock.yaml' | ||
- name: 🕵️ Set sha-short | ||
id: sha-short | ||
run: echo "sha-short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT | ||
|
||
outputs: | ||
client-goat: ${{ steps.changes.outputs.client-goat }} | ||
keycloak-theme: ${{ steps.changes.outputs.keycloak-theme }} | ||
storybook: ${{ steps.changes.outputs.storybook }} | ||
sha-short: ${{ steps.sha-short.outputs.sha-short }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
name: "Keycloak Theme Build" | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
keycloak-theme-artifact-id: | ||
description: "Keycloak theme artifact id" | ||
required: false | ||
type: string | ||
default: "p4b-keycloak-theme" | ||
|
||
push: | ||
description: "Push to S3" | ||
required: false | ||
type: boolean | ||
default: false | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 10 | ||
steps: | ||
- name: 📥 Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: 📥 Checkout PR | ||
uses: goat-community/.github/.github/actions/pr-git-checkout@main | ||
|
||
- name: 📥 Monorepo install | ||
uses: goat-community/.github/.github/actions/pnpm-install@main | ||
with: | ||
enable-corepack: true | ||
cwd: ${{ github.workspace }} | ||
|
||
- name: 🏗️ Keycloak build | ||
shell: bash | ||
run: | | ||
cd ${{github.workspace}}/packages/keycloak-theme | ||
KEYCLOAKIFY_ARTIFACT_ID="${{ github.event.inputs.keycloak-theme-artifact-id }}" KEYCLOAKIFY_GROUP_ID="com.plan4better.auth.keycloak" pnpm run build-keycloak-theme | ||
mv build_keycloak/target/*.jar build_keycloak/target/${{github.event.inputs.keycloak-theme-artifact-id}}.jar | ||
- uses: aws-actions/configure-aws-credentials@v1 | ||
name: 📥 Configure AWS credentials | ||
if: ${{ github.event.inputs.push }} | ||
with: | ||
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} | ||
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | ||
aws-region: eu-central-1 | ||
|
||
- name: | ||
if: ${{ github.event.inputs.push }} | ||
shell: bash | ||
run: | | ||
cd ${{github.workspace}}/packages/keycloak-theme | ||
aws s3 cp build_keycloak/target/${{github.event.inputs.keycloak-theme-artifact-id}}.jar s3://plan4better-assets/other/keycloak/ | ||
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
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,3 +20,4 @@ export const WithAnotherMessage: StoryFn<typeof PageStory> = () => ( | |
}} | ||
/> | ||
); | ||
|