improve rename

This commit is contained in:
2025-07-20 11:31:25 -04:00
parent 0609f1c857
commit 4e66a97391
2 changed files with 4 additions and 3 deletions

View File

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

View File

@ -73,7 +73,8 @@ rename:
exit 1; \
fi
@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 \
\( -name '*.go' -o -name 'go.mod' \
-o -name 'go.sum' -o -name '*.proto' \