Skip to content

Update golangci/golangci-lint-action action to v4 #1665

Update golangci/golangci-lint-action action to v4

Update golangci/golangci-lint-action action to v4 #1665

Workflow file for this run

name: Execute automated checks
on:
- push
jobs:
# https://github.com/golangci/golangci-lint-action#how-to-use
lint:
name: Lint go code
runs-on: ubuntu-latest
steps:
- name: Checkout git repo
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- name: Lint go code with golangci-lint
uses: golangci/golangci-lint-action@3cfe3a4abbb849e10058ce4af15d205b6da42804 # v4
with:
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version.
version: v1.53.3
args: --timeout=5m
test:
name: Verify go test
runs-on: ubuntu-latest
steps:
- name: Checkout git repo
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- name: Setup golang
uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5
with:
go-version: '1.17.0'
- name: Print go version
run: go version
- name: Execute go tests
run: go test -v ./...
tilt-ci-dev:
name: Verify tilt ci (development images)
runs-on: ubuntu-latest
steps:
- name: Checkout git repo
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- name: Create k8s Kind Cluster
uses: helm/kind-action@dda0770415bac9fc20092cacbc54aa298604d140 # v1.8.0
- name: Install tilt & helm
uses: yokawasa/action-setup-kube-tools@af4ebb1af1efd30c5bd84a2e9773355ad6362a33 # v0.9.3
with:
setup-tools: |
tilt
helm
tilt: 'v0.33.10'
helm: 'v3.6.3'
- name: Install helmfile
run: |
curl --fail -L -s --max-time 60 -o /usr/local/bin/helmfile https://github.com/roboll/helmfile/releases/download/v0.140.0/helmfile_linux_amd64
chmod +x /usr/local/bin/helmfile
- name: Install helm diff
run: |
helm plugin install https://github.com/databus23/helm-diff
- name: Install dependencies
run: |
helmfile sync
- name: Verify tilt ci
run: |
timeout 600 tilt ci
tilt-ci-prod:
name: Verify tilt ci (production images)
runs-on: ubuntu-latest
steps:
- name: Checkout git repo
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- name: Create k8s Kind Cluster
uses: helm/kind-action@dda0770415bac9fc20092cacbc54aa298604d140 # v1.8.0
- name: Install tilt cli
uses: yokawasa/action-setup-kube-tools@af4ebb1af1efd30c5bd84a2e9773355ad6362a33 # v0.9.3
with:
setup-tools: |
tilt
helm
tilt: 'v0.33.10'
helm: 'v3.6.3'
- name: Install helmfile
run: |
curl --fail -L -s --max-time 60 -o /usr/local/bin/helmfile https://github.com/roboll/helmfile/releases/download/v0.140.0/helmfile_linux_amd64
chmod +x /usr/local/bin/helmfile
- name: Install helm diff
run: |
helm plugin install https://github.com/databus23/helm-diff
- name: Install dependencies
run: |
helmfile sync
- name: Verify tilt ci
run: |
PROD=1 timeout 600 tilt ci