forked from dimatha/adcs-issuer
-
Notifications
You must be signed in to change notification settings - Fork 13
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
Showing
8 changed files
with
94 additions
and
5 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,40 @@ | ||
name: Golang lint issuer | ||
on: | ||
workflow_dispatch: | ||
push: | ||
paths: | ||
- 'api/**.go' | ||
- 'cmd/**.go' | ||
- 'globals/**.go' | ||
- 'config/**.go' | ||
- 'controllers/**.go' | ||
- 'internal/**.go' | ||
- 'version/**.go' | ||
- '**.go' | ||
|
||
branches: | ||
- main | ||
pull_request: | ||
|
||
permissions: | ||
contents: read | ||
# Optional: allow read access to pull request. Use with `only-new-issues` option. | ||
pull-requests: read | ||
|
||
jobs: | ||
golangci: | ||
name: lint | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-go@v5 | ||
with: | ||
go-version: '1.22' | ||
- name: golangci-lint | ||
uses: golangci/golangci-lint-action@v6 | ||
with: | ||
args: --timeout=3m | ||
version: v1.58 | ||
skip-cache: true | ||
skip-save-cache: true | ||
cache-invalidation-interval: 15 |
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,48 @@ | ||
name: Publish Docker image on Release | ||
|
||
on: | ||
workflow_dispatch: | ||
branches: [ main ] | ||
release: | ||
types: [published] | ||
|
||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@master | ||
|
||
- name: Get the tag version for building image | ||
id: get_version | ||
run: echo "VERSION=$(echo $GITHUB_REF | cut -d / -f 3)" >> $GITHUB_OUTPUT | ||
|
||
|
||
- name: Get current date for building image | ||
id: get_date | ||
run: echo "BUILD_TIME=$(date -u '+%Y-%m-%d_%H:%M:%S')" >> $GITHUB_OUTPUT | ||
|
||
- name: Get commit hash for building image | ||
id: get_commit | ||
run: echo "COMMIT=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT | ||
|
||
- name: Print name | ||
id: print_args | ||
run: echo "Hello VERSION. ${{ steps.get_version.outputs.VERSION }} . COMMIT. ${{ steps.get_commit.outputs.COMMIT }} BUILD_TIME. ${{steps.get_date.outputs.BUILD_TIME }}" | ||
|
||
|
||
- name: Publish to Registry | ||
uses: elgohr/Publish-Docker-Github-Action@v5 | ||
env: | ||
ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true' | ||
PROJECT: github.com/djkormo/adcs-issuer | ||
COMMIT: ${{ steps.get_commit.outputs.COMMIT }} | ||
VERSION: ${{ steps.get_version.outputs.VERSION }} | ||
BUILD_TIME: ${{steps.get_date.outputs.BUILD_TIME }} | ||
with: | ||
name: djkormo/adcs-issuer | ||
buildargs: PROJECT,COMMIT,BUILD_TIME,VERSION | ||
username: ${{ secrets.DOCKER_USERNAME }} | ||
password: ${{ secrets.DOCKER_PASSWORD }} | ||
tags: "latest,${{ env.VERSION }}" | ||
tag_semver: true |
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 |
---|---|---|
|
@@ -37,3 +37,4 @@ adcs-sim | |
*.key | ||
*-all.yaml | ||
*.exe | ||
adcs-issuer |
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 |
---|---|---|
@@ -1,5 +1,5 @@ | ||
# Build the manager binary | ||
FROM golang:1.21 as builder | ||
FROM golang:1.22 as builder | ||
|
||
|
||
ARG VERSION | ||
|
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 |
---|---|---|
@@ -1,6 +1,6 @@ | ||
APP_NAME=adcs-issuer | ||
DOCKER_REPO=djkormo | ||
VERSION=2.1.2 | ||
VERSION=2.1.3 | ||
|
||
|
||
|
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