Skip to content

Commit

Permalink
CI/CD configuration.
Browse files Browse the repository at this point in the history
Signed-off-by: Łukasz Dywicki <[email protected]>
  • Loading branch information
splatch committed Jan 29, 2024
1 parent b730528 commit 0360248
Show file tree
Hide file tree
Showing 3 changed files with 83 additions and 0 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Build pull request

on:
pull_request:
branches: [ "*" ]

jobs:
build:
#if: ${{ true }}
permissions:
checks: write
contents: read
uses: 'connectorio/gh-actions-shared/.github/workflows/maven.yml@master'
secrets: inherit
with:
openhab: false
server_id: thing4-snapshots
deploy: true

debug:
runs-on: 'ubuntu-latest'
steps:
- id: debug-secrets
env:
SECRETS_VARS: ${{ toJson(secrets) }}
run: echo "$SECRETS_VARS"
26 changes: 26 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Build pushed commit

on:
push:
branches: [ "*" ]

jobs:
build:
#if: ${{ true }}
permissions:
checks: write
contents: read
uses: 'connectorio/gh-actions-shared/.github/workflows/maven.yml@master'
secrets: inherit
with:
openhab: false
server_id: thing4-snapshots
deploy: ${{ github.ref_name == 'master' }}

debug:
runs-on: 'ubuntu-latest'
steps:
- id: debug-secrets
env:
SECRETS_VARS: ${{ toJson(secrets) }}
run: echo "$SECRETS_VARS"
31 changes: 31 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Release artifacts

on:
workflow_dispatch:
inputs:
release_version:
description: 'The version to be released from actual HEAD revision'
required: false
default: 'X.Y.Z'
development_version:
description: 'Version to be set as next, after release is made (appends commit to HEAD revision)'
required: false
default: 'X.Y.Z-SNAPSHOT'
perform_version:
description: 'Tag which should be used to perform release and publish its artifacts'
required: false
dry_run:
description: 'Should execution abstain from mutating repository/remote state?'
required: true
default: 'true'

jobs:
build:
uses: 'connectorio/gh-actions-shared/.github/workflows/release.yml@master'
secrets: inherit
with:
openhab: false
release_version: ${{ inputs.release_version }}
development_version: ${{ inputs.development_version }}
perform_version: ${{ inputs.perform_version }}
dry_run: ${{ inputs.dry_run }}

0 comments on commit 0360248

Please sign in to comment.