switch-to-buf #1

Merged
rmcguire merged 6 commits from switch-to-buf into main 2025-07-20 15:42:59 +00:00
16 changed files with 457 additions and 668 deletions
Showing only changes of commit 4e66a97391 - Show all commits

View File

@ -7,7 +7,7 @@ ARG GOPROXY
ARG GONOSUMDB=gitea.libretechconsulting.com ARG GONOSUMDB=gitea.libretechconsulting.com
ARG VER_PKG=gitea.libretechconsulting.com/rmcguire/go-app/pkg/config.Version ARG VER_PKG=gitea.libretechconsulting.com/rmcguire/go-app/pkg/config.Version
ARG VERSION=(devel) ARG VERSION=(devel)
ARG APP_NAME=demo-app ARG APP_NAME=go-server-with-otel
COPY ./go.mod ./go.sum ./ COPY ./go.mod ./go.sum ./
RUN go mod download RUN go mod download
@ -17,7 +17,7 @@ RUN go build -C . -v -ldflags "-extldflags '-static' -X ${VER_PKG}=${VERSION}" -
FROM alpine:latest FROM alpine:latest
ARG APP_NAME=demo-app ARG APP_NAME=go-server-with-otel
WORKDIR /app WORKDIR /app
USER 100:101 USER 100:101

View File

@ -73,7 +73,8 @@ rename:
exit 1; \ exit 1; \
fi fi
@sed -i "s|APP_NAME=.*|APP_NAME=$(APP)|g" Dockerfile @sed -i "s|APP_NAME=.*|APP_NAME=$(APP)|g" Dockerfile
@sed -i "s|CMD_NAME := .*|CMD_NAME := $(APP)|g" Makefile @sed -i "s|^CMD_NAME := .*|CMD_NAME := $(APP)|g" Makefile
@sed -i "s|merge_file_name=.*|merge_file_name=$(APP)|g" buf.gen.yaml
@find . -type f -a \ @find . -type f -a \
\( -name '*.go' -o -name 'go.mod' \ \( -name '*.go' -o -name 'go.mod' \
-o -name 'go.sum' -o -name '*.proto' \ -o -name 'go.sum' -o -name '*.proto' \