Skip to content

Commit

Permalink
Update deps (#657)
Browse files Browse the repository at this point in the history
* Update SDK
* Update direct deps
* Add install-deps target
* Regenerate stubs
* Update alpine and its packages
* Fix linter errors
* Increase timeout
  • Loading branch information
mostafa authored Jan 25, 2025
1 parent 788b759 commit c629f90
Show file tree
Hide file tree
Showing 18 changed files with 166 additions and 157 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ jobs:
test:
name: Test GatewayD
runs-on: ubuntu-latest
# Timeout after 5 minutes, to avoid hanging tests
timeout-minutes: 5
# Timeout after 6 minutes, to avoid hanging tests
timeout-minutes: 6
services:
postgres:
image: postgres
Expand Down
2 changes: 0 additions & 2 deletions .golangci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,6 @@ linters-settings:
- "github.com/google/go-cmp"
- "github.com/google/go-github/v53/github"
- "github.com/codingsince1985/checksum"
- "golang.org/x/exp/maps"
- "golang.org/x/exp/slices"
- "gopkg.in/yaml.v3"
- "github.com/zenizh/go-capturer"
- "gopkg.in/natefinch/lumberjack.v2"
Expand Down
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# syntax=docker/dockerfile:1

# Use the official golang image to build the binary.
FROM golang:1.23-alpine3.20 AS builder
FROM golang:1.23-alpine3.21 AS builder

ARG TARGETOS
ARG TARGETARCH
Expand All @@ -10,12 +10,12 @@ ARG TARGETPLATFORM
WORKDIR /gatewayd
COPY . /gatewayd

RUN apk --no-cache add git=2.45.2-r0 make=4.4.1-r2 openssl=3.3.2-r1 && \
RUN apk --no-cache add git=2.47.2-r0 make=4.4.1-r2 openssl=3.3.2-r4 && \
mkdir -p dist && \
make build-platform GOOS=${TARGETOS} GOARCH=${TARGETARCH} OUTPUT_DIR=dist/${TARGETOS}-${TARGETARCH}

# Use alpine to create a minimal image to run the gatewayd binary.
FROM alpine:3.20 AS runner
FROM alpine:3.21 AS runner

ARG TARGETOS
ARG TARGETARCH
Expand Down
7 changes: 7 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,13 @@ update-direct-deps:
@go list -f '{{if not (or .Main .Indirect)}}{{.Path}}{{end}}' -m all | xargs -n1 go get
@go mod tidy

install-deps:
@go install github.com/bufbuild/buf/cmd/buf@latest
@go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
@go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest
@go install github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-grpc-gateway@latest
@go install github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2@latest

lint:
@buf lint

Expand Down
14 changes: 7 additions & 7 deletions api/v1/api.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/v1/api.swagger.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions cmd/plugin_install.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import (
"errors"
"fmt"
"io"
"maps"
"net/http"
"os"
"path"
Expand All @@ -24,7 +25,6 @@ import (
"github.com/google/go-github/v53/github"
"github.com/spf13/cast"
"github.com/spf13/cobra"
"golang.org/x/exp/maps"
yamlv3 "gopkg.in/yaml.v3"
)

Expand Down Expand Up @@ -162,7 +162,7 @@ var pluginInstallCmd = &cobra.Command{

// Check if the plugin is already installed and prompt the user to confirm the update.
if len(existingPluginURLs) > 0 {
pluginNames := strings.Join(maps.Keys[map[string]string](existingPluginURLs), ", ")
pluginNames := strings.Join(slices.Sorted(maps.Keys(existingPluginURLs)), ", ")
cmd.Printf("The following plugins are already installed: %s\n", pluginNames)

if noPrompt {
Expand Down
2 changes: 1 addition & 1 deletion cmd/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package cmd
import (
"context"
"log"
"maps"
"os"
"syscall"

Expand All @@ -13,7 +14,6 @@ import (
"github.com/getsentry/sentry-go"
"github.com/spf13/cobra"
"go.opentelemetry.io/otel"
"golang.org/x/exp/maps"
)

var (
Expand Down
2 changes: 1 addition & 1 deletion config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (
"math"
"os"
"reflect"
"slices"
"sort"
"strings"

Expand All @@ -21,7 +22,6 @@ import (
"github.com/knadh/koanf/providers/structs"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/attribute"
"golang.org/x/exp/slices"
)

type IConfig interface {
Expand Down
67 changes: 34 additions & 33 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,49 +1,49 @@
module github.com/gatewayd-io/gatewayd

go 1.23.4
go 1.23.5

require (
github.com/Masterminds/semver/v3 v3.3.1
github.com/NYTimes/gziphandler v1.1.1
github.com/codingsince1985/checksum v1.3.0
github.com/cybercyst/go-scaffold v0.0.0-20240606114431-816e6211c151
github.com/docker/go-connections v0.5.0
github.com/envoyproxy/protoc-gen-validate v1.1.0
github.com/gatewayd-io/gatewayd-plugin-sdk v0.3.5
github.com/getsentry/sentry-go v0.30.0
github.com/envoyproxy/protoc-gen-validate v1.2.1
github.com/gatewayd-io/gatewayd-plugin-sdk v0.4.0
github.com/getsentry/sentry-go v0.31.1
github.com/go-co-op/gocron v1.37.0
github.com/google/go-github/v53 v53.2.0
github.com/grpc-ecosystem/grpc-gateway/v2 v2.24.0
github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.0
github.com/hashicorp/go-hclog v1.6.3
github.com/hashicorp/go-plugin v1.6.2
github.com/hashicorp/raft v1.7.1
github.com/hashicorp/raft-boltdb v0.0.0-20241202213821-f9dd2ba30efd
github.com/invopop/jsonschema v0.12.0
github.com/jackc/pgx/v5 v5.7.1
github.com/hashicorp/go-plugin v1.6.3
github.com/hashicorp/raft v1.7.2
github.com/hashicorp/raft-boltdb v0.0.0-20250113192317-e8660f88bcc9
github.com/invopop/jsonschema v0.13.0
github.com/jackc/pgx/v5 v5.7.2
github.com/knadh/koanf v1.5.0
github.com/mitchellh/mapstructure v1.5.0
github.com/prometheus/client_golang v1.20.5
github.com/prometheus/client_model v0.6.1
github.com/prometheus/common v0.61.0
github.com/prometheus/common v0.62.0
github.com/redis/go-redis/v9 v9.7.0
github.com/rs/zerolog v1.33.0
github.com/santhosh-tekuri/jsonschema/v5 v5.3.1
github.com/spaolacci/murmur3 v1.1.0
github.com/spf13/cast v1.7.0
github.com/spf13/cast v1.7.1
github.com/spf13/cobra v1.8.1
github.com/stretchr/testify v1.10.0
github.com/testcontainers/testcontainers-go v0.34.0
github.com/testcontainers/testcontainers-go v0.35.0
github.com/zenizh/go-capturer v0.0.0-20211219060012-52ea6c8fed04
go.opentelemetry.io/otel v1.33.0
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.33.0
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.33.0
go.opentelemetry.io/otel/sdk v1.33.0
go.opentelemetry.io/otel/trace v1.33.0
golang.org/x/exp v0.0.0-20241210194714-1829a127f884
go.opentelemetry.io/otel v1.34.0
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0
go.opentelemetry.io/otel/sdk v1.34.0
go.opentelemetry.io/otel/trace v1.34.0
golang.org/x/exp v0.0.0-20250106191152-7588d65b2ba8
golang.org/x/text v0.21.0
google.golang.org/genproto/googleapis/api v0.0.0-20241209162323-e6fa225c2576
google.golang.org/grpc v1.69.0
google.golang.org/protobuf v1.35.2
google.golang.org/genproto/googleapis/api v0.0.0-20250124145028-65684f501c47
google.golang.org/grpc v1.70.0
google.golang.org/protobuf v1.36.4
gopkg.in/natefinch/lumberjack.v2 v2.2.1
gopkg.in/yaml.v3 v3.0.1
)
Expand Down Expand Up @@ -94,6 +94,7 @@ require (
github.com/google/go-querystring v1.1.0 // indirect
github.com/google/uuid v1.6.0 // indirect
github.com/hashicorp/go-immutable-radix v1.0.0 // indirect
github.com/hashicorp/go-metrics v0.5.4 // indirect
github.com/hashicorp/go-msgpack v0.5.5 // indirect
github.com/hashicorp/go-msgpack/v2 v2.1.2 // indirect
github.com/hashicorp/golang-lru v0.5.1 // indirect
Expand All @@ -107,7 +108,7 @@ require (
github.com/lufia/plan9stats v0.0.0-20240909124753-873cd0166683 // indirect
github.com/magiconair/properties v1.8.7 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
github.com/mattn/go-colorable v0.1.13 // indirect
github.com/mattn/go-colorable v0.1.14 // indirect
github.com/mattn/go-isatty v0.0.20 // indirect
github.com/mitchellh/copystructure v1.2.0 // indirect
github.com/mitchellh/reflectwalk v1.0.2 // indirect
Expand All @@ -123,7 +124,7 @@ require (
github.com/opencontainers/go-digest v1.0.0 // indirect
github.com/opencontainers/image-spec v1.1.0 // indirect
github.com/pelletier/go-toml v1.9.5 // indirect
github.com/pganalyze/pg_query_go/v5 v5.1.0 // indirect
github.com/pganalyze/pg_query_go/v6 v6.0.0 // indirect
github.com/pjbgf/sha1cd v0.3.0 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
Expand All @@ -144,22 +145,22 @@ require (
github.com/tetratelabs/wazero v1.8.2 // indirect
github.com/tklauser/go-sysconf v0.3.14 // indirect
github.com/tklauser/numcpus v0.8.0 // indirect
github.com/wasilibs/go-pgquery v0.0.0-20241011013927-817756c5aae4 // indirect
github.com/wasilibs/wazero-helpers v0.0.0-20240620070341-3dff1577cd52 // indirect
github.com/wasilibs/go-pgquery v0.0.0-20241226024732-8bfaa0ac5969 // indirect
github.com/wasilibs/wazero-helpers v0.0.0-20250123031827-cd30c44769bb // indirect
github.com/wk8/go-ordered-map/v2 v2.1.8 // indirect
github.com/xanzy/ssh-agent v0.3.3 // indirect
github.com/yusufpapurcu/wmi v1.2.4 // indirect
go.opentelemetry.io/auto/sdk v1.1.0 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.55.0 // indirect
go.opentelemetry.io/otel/metric v1.33.0 // indirect
go.opentelemetry.io/proto/otlp v1.4.0 // indirect
go.opentelemetry.io/otel/metric v1.34.0 // indirect
go.opentelemetry.io/proto/otlp v1.5.0 // indirect
go.uber.org/atomic v1.11.0 // indirect
golang.org/x/crypto v0.31.0 // indirect
golang.org/x/net v0.33.0 // indirect
golang.org/x/oauth2 v0.24.0 // indirect
golang.org/x/crypto v0.32.0 // indirect
golang.org/x/net v0.34.0 // indirect
golang.org/x/oauth2 v0.25.0 // indirect
golang.org/x/sync v0.10.0 // indirect
golang.org/x/sys v0.28.0 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20241209162323-e6fa225c2576 // indirect
golang.org/x/sys v0.29.0 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20250124145028-65684f501c47 // indirect
gopkg.in/warnings.v0 v0.1.2 // indirect
oras.land/oras-go/v2 v2.5.0 // indirect
)
Expand Down
Loading

0 comments on commit c629f90

Please sign in to comment.