Skip to content

ci-pipeline: add task installation to each job as jobs are isolated #19

ci-pipeline: add task installation to each job as jobs are isolated

ci-pipeline: add task installation to each job as jobs are isolated #19

Workflow file for this run

name: CI Pipeline
on: push
jobs:
lint:
name: Lint Application
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: stable
cache: false
- name: Install Task CLI
uses: arduino/setup-task@v2
with:
version: 3.x
- name: Install GolangCI-Lint
run: task instal-golangci-lint
- name: Run Lint
run: task lint
test:
name: Test Application
runs-on: ubuntu-latest
needs: lint
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: stable
cache: false
- name: Install Task CLI
uses: arduino/setup-task@v2
with:
version: 3.x
- name: Run Test
run: task test
build:
name: Build Application
runs-on: ubuntu-latest
needs: test
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: stable
cache: false
- name: Install Task CLI
uses: arduino/setup-task@v2
with:
version: 3.x
- name: Build
run: task build
- name: Copy Files
run: |
mkdir artifacts
cp bin/linux_amd64/api artifacts/.
- name: Archive Artifacts
uses: actions/upload-artifact@v4
with:
name: api
path: artifacts