mirror of
https://github.com/containrrr/watchtower.git
synced 2025-09-21 21:30:48 +02:00
![dependabot[bot]](/assets/img/avatar_default.png)
Bumps [actions/setup-go](https://github.com/actions/setup-go) from 4 to 5. - [Release notes](https://github.com/actions/setup-go/releases) - [Commits](https://github.com/actions/setup-go/compare/v4...v5) --- updated-dependencies: - dependency-name: actions/setup-go dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
59 lines
1.6 KiB
YAML
59 lines
1.6 KiB
YAML
name: Push to main
|
|
|
|
on:
|
|
workflow_dispatch: {}
|
|
push:
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version: 1.20.x
|
|
- name: Build
|
|
run: ./build.sh
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version: 1.20.x
|
|
- name: Test
|
|
run: go test -v -coverprofile coverage.out -covermode atomic ./...
|
|
- name: Publish coverage
|
|
uses: codecov/codecov-action@v3
|
|
with:
|
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
publish:
|
|
needs:
|
|
- build
|
|
- test
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Publish to Docker Hub
|
|
uses: jerray/publish-docker-action@87d84711629b0dc9f6bb127b568413cc92a2088e #master@2022-10-14
|
|
with:
|
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
password: ${{ secrets.DOCKERHUB_PASSWORD }}
|
|
file: dockerfiles/Dockerfile.self-contained
|
|
repository: containrrr/watchtower
|
|
tags: latest-dev
|
|
- name: Publish to GHCR
|
|
uses: jerray/publish-docker-action@87d84711629b0dc9f6bb127b568413cc92a2088e #master@2022-10-14
|
|
with:
|
|
username: ${{ secrets.BOT_USERNAME }}
|
|
password: ${{ secrets.BOT_GHCR_PAT }}
|
|
file: dockerfiles/Dockerfile.self-contained
|
|
registry: ghcr.io
|
|
repository: containrrr/watchtower
|
|
tags: latest-dev
|