Skip to content

Commit

Permalink
initial commit of workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
neilha committed Nov 15, 2024
1 parent dfd5188 commit 95ad79d
Show file tree
Hide file tree
Showing 4 changed files with 93 additions and 0 deletions.
6 changes: 6 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
version: 2
updates:
- package-ecosystem: github-actions
directory: /
schedule:
interval: weekly
43 changes: 43 additions & 0 deletions .github/workflows/build-multiarch.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Build and push multi-arch images

on:
workflow_dispatch:
inputs:
gitRef:
description: Commit, tag or branch name to deploy
required: true
type: string
default: main
pushToRegistry:
description: Push to image registry. Set to false to build without pushing.
required: true
type: boolean
default: true
# push:
# branches:
# - main
# schedule:
# - cron: '34 3 * * *'

env:
REGISTRY_BASE: ghcr.io/publishing-platform

jobs:
configure_builds:
name: Read configuration from build-matrix.json
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
matrix_versions: ${{ steps.set-matrix.outputs.matrix_versions }}
runs_on: ${{ steps.set-matrix.outputs.runs_on }}
steps:
- uses: actions/checkout@v4
with:
show-progress: false
- id: set-matrix
run: |
{
echo "matrix=$(jq -c . < build-matrix.json)"
echo "matrix_versions=$(jq -c .version < build-matrix.json)"
echo "runs_on=$(jq -c .runs_on < build-matrix.json)"
} >> "$GITHUB_OUTPUT"
23 changes: 23 additions & 0 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Run linters/fixers
on: [push]
jobs:
shellcheck:
name: Shellcheck
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
show-progress: false
- name: Run ShellCheck
uses: ludeeus/action-shellcheck@00cae500b08a931fb5698e11e79bfbd38e612a38 # 2.0.0
hadolint:
name: Hadolint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
show-progress: false
- uses: jbergstroem/hadolint-gh-action@eac45b98f6d761309202bd201205a8f8c988bfad # v1.11.0
with:
dockerfile: '**/*Dockerfile'
error_level: '1' # Fail on warning or above.
21 changes: 21 additions & 0 deletions build-matrix.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"version": [
{
"rubyver": [
"3", "2", "4"
],
"checksum": "c72b3c5c30482dca18b0f868c9075f3f47d8168eaf626d4e682ce5b59c858692",
"extra": ""
}
],
"runs_on": [
{
"runner_type": "ubuntu-latest",
"arch": "amd64"
},
{
"runner_type": "ubuntu-24.04-arm",
"arch": "arm64"
}
]
}

0 comments on commit 95ad79d

Please sign in to comment.