-
Notifications
You must be signed in to change notification settings - Fork 5
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
19 changed files
with
578 additions
and
254 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,4 @@ updates: | |
- package-ecosystem: docker | ||
directory: "/" | ||
schedule: | ||
interval: weekly | ||
interval: monthly |
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,71 @@ | ||
name: Release | ||
on: | ||
push: | ||
# Nightly schedule pending full e2e testing with other repos | ||
#schedule: | ||
# Run daily at 1:15am | ||
#- cron: "15 1 * * *" | ||
workflow_dispatch: | ||
# Inputs the workflow accepts. | ||
inputs: | ||
version: | ||
# Friendly description to be shown in the UI instead of 'name' | ||
description: "Semver type of new version (major / minor / patch)" | ||
# Input has to be provided for the workflow to run | ||
required: true | ||
type: choice | ||
options: | ||
- patch | ||
- minor | ||
- major | ||
|
||
jobs: | ||
# Run the linting and tests | ||
hadolint: | ||
uses: SkynetLabs/.github/.github/workflows/reusable_dockerfile_lint.yml@master | ||
|
||
test: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Check out repository code | ||
uses: actions/checkout@v3 | ||
- uses: actions/setup-go@v2 | ||
with: | ||
go-version: "1.18" | ||
- name: Install analyze | ||
run: go install gitlab.com/NebulousLabs/analyze@latest | ||
- name: Install golangci-lint | ||
run: curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.45.0 | ||
- name: Lint | ||
run: make lint | ||
- name: Run unit tests | ||
run: make test | ||
|
||
# Check if there were any changes since the last tag if this is not a push | ||
# event | ||
changes: | ||
needs: [hadolint, test] | ||
runs-on: ubuntu-latest | ||
outputs: | ||
updates: ${{steps.changes.outputs.any == 'true'}} | ||
if: ${{ github.event_name != 'push' }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 # Required due to the way Git works, without it this action won't be able to find any or the correct tags | ||
- uses: SkynetLabs/.github/.github/actions/changes-since-last-tag@master | ||
|
||
# Make a release if | ||
# - there were changes and this is a scheduled job | ||
# - This is a manually trigger job, i.e. workflow_dispatch | ||
release: | ||
needs: changes | ||
runs-on: ubuntu-latest | ||
if: ${{ (needs.changes.outputs.updates == 'true' && github.event_name == 'schedule') || github.event_name == 'workflow_dispatch' }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Version Release | ||
uses: SkynetLabs/.github/.github/actions/version-release@master | ||
with: | ||
github-token: ${{secrets.GITHUB_TOKEN}} | ||
version-bump: ${{inputs.version}} |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
Oops, something went wrong.