Skip to content

WIP: Multiple Namespaces (#138) #440

WIP: Multiple Namespaces (#138)

WIP: Multiple Namespaces (#138) #440

Workflow file for this run

name: ci
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
workflow_run:
workflows: [Publish]
types:
- completed
jobs:
build:
name: build
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.13
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v2
- name: Get dependencies
run: |
go get -v -t -d ./...
if [ -f Gopkg.toml ]; then
curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
dep ensure
fi
- name: Build
run: go build -v cmd/clouddriver/clouddriver.go
- name: Test
run: go test -v ./...
env:
GOOGLE_APPLICATION_CREDENTIALS: test/credentials/test-keyfile.json
golangci:
name: lint
runs-on: ubuntu-latest
steps:
- uses: actions/setup-go@v3
with:
go-version: '1.20.4'
check-latest: false
- uses: actions/checkout@v3
- name: golangci-lint
uses: golangci/golangci-lint-action@v3
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.52
args: --skip-files .*_test.go --enable wsl --enable misspell --timeout 180s
# publish:
# name: Publish
# runs-on: ubuntu-latest
# if: github.ref == 'refs/heads/master'
# steps:
# - name: Checkout
# uses: actions/checkout@v2
# - name: Login to Docker Hub
# uses: docker/login-action@v1
# with:
# username: ${{ secrets.DOCKER_HUB_USERNAME }}
# password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
# # - name: Set up Docker Buildx
# # uses: docker/setup-buildx-action@v1
# -
# name: Login to Docker Hub
# uses: docker/login-action@v1
# with:
# username: ${{ secrets.DOCKER_HUB_USERNAME }}
# password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
# -
# name: Build and push
# uses: docker/build-push-action@v2
# with:
# context: ./
# file: ./docker/Dockerfile
# push: true
# tags: ${{ secrets.DOCKER_HUB_USERNAME }}/go-clouddriver:latest