Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Snyk] Security upgrade alpine from 3.17 to 3.18.6 #187

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion docker/Dockerfile

This file was deleted.

40 changes: 40 additions & 0 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# __
# .-----.-----.______.-----.----.-----.--.--.--.--.______.----.---.-.----| |--.-----.
# | _ | _ |______| _ | _| _ |_ _| | |______| __| _ | __| | -__|
# |___ |_____| | __|__| |_____|__.__|___ | |____|___._|____|__|__|_____|
# |_____| |__| |_____|
#
# Copyright (c) 2023 Fabio Cicerchia. https://fabiocicerchia.it. MIT License
# Repo: https://github.com/fabiocicerchia/go-proxy-cache

FROM golang:1.20.1-alpine3.17 AS builder

ARG BUILD_CMD=build

WORKDIR /go/src/github.com/fabiocicerchia/go-proxy-cache

ENV CGO_CFLAGS -march=native -O3

RUN apk update \
&& apk add --no-cache \
gcc \
libc-dev \
make

COPY . ./

RUN make $BUILD_CMD

FROM alpine:3.18.6

WORKDIR /app

COPY --from=builder /go/src/github.com/fabiocicerchia/go-proxy-cache/go-proxy-cache /usr/local/bin/
COPY --from=builder /go/src/github.com/fabiocicerchia/go-proxy-cache/config.yml.dist /app/config.yml

RUN apk upgrade

RUN go-proxy-cache --version \
&& go-proxy-cache --test

CMD ["go-proxy-cache"]
Loading