diff options
| author | jwijenbergh <jeroenwijenbergh@protonmail.com> | 2024-11-29 12:00:13 +0100 |
|---|---|---|
| committer | jwijenbergh <jeroenwijenbergh@protonmail.com> | 2024-12-19 11:05:08 +0100 |
| commit | 80eec548cb5ed451172d5591a4908376ae0bdcf1 (patch) | |
| tree | e4fdcd9ca271e418348900513dd9c44330566e50 | |
| parent | b536cfd5e19ff6b114405258d4f259c1d7700422 (diff) | |
CI: Use fkooman's image
| -rw-r--r-- | .forgejo/workflows/test.yml | 37 |
1 files changed, 5 insertions, 32 deletions
diff --git a/.forgejo/workflows/test.yml b/.forgejo/workflows/test.yml index fa3ac07..c7885f0 100644 --- a/.forgejo/workflows/test.yml +++ b/.forgejo/workflows/test.yml @@ -1,42 +1,15 @@ -env: - BUILD_DEPENDENCIES: apt-transport-https curl git iproute2 lsb-release make wget - GOCILINT_VERSION: 1.62.0 on: [ push ] - jobs: test: runs-on: docker container: - image: debian:latest + image: codeberg.org/fkooman/ci:latest steps: - - name: Install OS Dependencies - run: | - apt-get update - apt-get install --yes $BUILD_DEPENDENCIES - - name: Enable Go Backports - run: | - wget -O /usr/share/keyrings/go+repo@tuxed.net.gpg https://repo.tuxed.net/golang/v1/deb/go+repo@tuxed.net.gpg - echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/go+repo@tuxed.net.gpg] https://repo.tuxed.net/golang/v1/deb $(lsb_release -c -s) main" > /etc/apt/sources.list.d/golang_v1.list - apt-get update - apt-get install --yes golang-go - - name: Install linter - run: | - wget -O lint.deb https://github.com/golangci/golangci-lint/releases/download/v$GOCILINT_VERSION/golangci-lint-$GOCILINT_VERSION-linux-amd64.deb - dpkg -i lint.deb - rm lint.deb - name: Clone Repository - run: | - mkdir app - git clone -b ${{ github.ref_name }} ${{ github.server_url }}/${{ github.repository }} app + run: git clone -b ${{ github.ref_name }} ${{ github.server_url }}/${{ github.repository }} . - name: Download Go deps - run: | - cd app - go get ./... + run: GOPROXY=https://proxy.golang.org,direct go get ./... - name: Test Go - run: | - cd app - unshare -r -n bash -c "ip link set lo up && make test" + run: unshare -r -n bash -c "ip link set lo up && make test" - name: Lint - run: | - cd app - make lint + run: make lint |
