Skip to content

Merge pull request #104 from timescale/dependabot/go_modules/golang.o… #76

Merge pull request #104 from timescale/dependabot/go_modules/golang.o…

Merge pull request #104 from timescale/dependabot/go_modules/golang.o… #76

Workflow file for this run

name: Go CI, build and publish
on:
push:
branches: [main]
pull_request:
branches: ["**"]
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: "1.22"
- name: Check out code
uses: actions/checkout@v4
- name: Install dependencies
run: go mod download
- name: golangci-lint
uses: golangci/golangci-lint-action@v6
with:
version: v1.61
- name: Format
run: |
gofmt -l -s -w .
- name: Test
run: go test -v ./...
build-and-push:
needs: build
runs-on: ubuntu-latest
if: ${{ github.event_name != 'pull_request' }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Dockerhub
uses: docker/login-action@v3
with:
username: ${{ secrets.ORG_DOCKER_HUB_USERNAME }}
password: ${{ secrets.ORG_DOCKER_HUB_ACCESS_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v5
with:
context: .
platforms: linux/amd64,linux/arm64
push: true
tags: timescale/timescaledb-parallel-copy:latest