|
7 | 7 | jobs: |
8 | 8 | build: |
9 | 9 | runs-on: ubuntu-latest |
10 | | - container: golangci/golangci-lint:v1.46.0 |
| 10 | + container: golangci/golangci-lint:v1.54.2 |
11 | 11 | steps: |
12 | 12 | - uses: actions/checkout@v2 |
13 | 13 | with: |
14 | 14 | # Required for Codecov report uploading. |
15 | 15 | fetch-depth: 0 |
16 | 16 | - run: make install-cc-test-reporter install-changelog BIN_PATH=/usr/local/bin |
17 | | - - run: make build build-test test-update-linters lint test-tidy test-changelog |
| 17 | + - run: | |
| 18 | + # Required to avoid error 'fatal: detected dubious ownership in repository at' while calling |
| 19 | + # 'git status --porcelain'. |
| 20 | + git config --global --add safe.directory /__w/terraform-provider-flexkube/terraform-provider-flexkube |
| 21 | + make build build-test test-update-linters lint test-tidy test-changelog |
18 | 22 | - run: make test-cover-upload |
19 | 23 | e2e: |
20 | 24 | runs-on: ubuntu-latest |
21 | 25 | steps: |
22 | 26 | - uses: actions/setup-go@v2 |
23 | 27 | with: |
24 | | - go-version: '1.18' |
| 28 | + go-version: '1.21' |
25 | 29 | - uses: actions/cache@v2 |
26 | 30 | with: |
27 | 31 | path: | |
|
33 | 37 | - uses: actions/checkout@v2 |
34 | 38 | - uses: hashicorp/setup-terraform@v1 |
35 | 39 | - name: Setup containerd |
36 | | - uses: crazy-max/ghaction-setup-containerd@v1.3.0 |
| 40 | + run: | |
| 41 | + # From https://docs.docker.com/engine/install/ubuntu/. |
| 42 | + sudo apt-get remove docker docker-engine docker.io containerd runc |
| 43 | + sudo apt-get update |
| 44 | + sudo apt-get install \ |
| 45 | + ca-certificates \ |
| 46 | + curl \ |
| 47 | + gnupg \ |
| 48 | + lsb-release |
| 49 | + sudo mkdir -p /etc/apt/keyrings |
| 50 | + curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg |
| 51 | + echo \ |
| 52 | + "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \ |
| 53 | + $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null |
| 54 | + sudo apt-get update |
| 55 | + sudo apt-get install docker-ce docker-ce-cli containerd.io docker-compose-plugin |
| 56 | + # From Flatcar default configuration and image-builder containerd role. |
| 57 | + sudo sed -i 's/^disabled_plugins.*/disabled_plugins = []/g' /etc/containerd/config.toml |
| 58 | + cat <<EOF | sudo tee -a /etc/containerd/config.toml |
| 59 | + [plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runc] |
| 60 | + # setting runc.options unsets parent settings |
| 61 | + runtime_type = "io.containerd.runc.v2" |
| 62 | + [plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runc.options] |
| 63 | + SystemdCgroup = true |
| 64 | + EOF |
| 65 | + sudo systemctl restart containerd |
37 | 66 | - name: Fetch dependencies and configure tests |
38 | 67 | run: | |
39 | 68 | curl https://raw.githubusercontent.com/helm/helm/master/scripts/get-helm-3 | bash |
|
0 commit comments