diff --git a/Makefile b/Makefile index 417f50a..f6fc051 100644 --- a/Makefile +++ b/Makefile @@ -7,24 +7,14 @@ release: $(release_name) mv ./rex_client/rexclient $(release_name) mv ./rex_server/rexserver $(release_name) cp ./LICENSE.txt $(release_name) - cp ./README.md $(release_name) - mkdir -p $(release_name)/source - git ls-files | xargs -I{} cp --parents {} $(release_name)/source - date -I > $(release_name)/VERSION.txt - echo $(rev) >> $(release_name)/VERSION.txt - go version >> $(release_name)/VERSION.txt tar cvzf $(release_name).tar.gz $(release_name) $(release_name): mkdir -p $@ -container: - podman build -t rexserver -f container/Containerfile . - clean: make -C ./rex_client clean make -C ./rex_server clean - rm -rf *.tar.gz rm -rf rexforge_* -.PHONY: release clean container +.PHONY: release clean diff --git a/container/Containerfile b/container/Containerfile deleted file mode 100644 index e56067b..0000000 --- a/container/Containerfile +++ /dev/null @@ -1,24 +0,0 @@ -FROM docker.io/golang:alpine as go -WORKDIR /build -# ADD rex_server/go.mod rex_server/go.sum ./ # WARNING: Include go.sum -ADD rex_server/go.mod ./ - -RUN go mod download - -# Add the rest of the source -ADD . . - -RUN go build -o ./rexserver ./rex_server/server.go - -# Runner image, drop privileges -FROM docker.io/alpine:latest as runner -RUN adduser -D nonroot -RUN addgroup nonroot nonroot -WORKDIR /app -RUN chown nonroot:nonroot /app - -COPY --from=go /build/rexserver rexserver -EXPOSE 8080 -USER nonroot:nonroot -CMD ["./rexserver"] -