Skip to content

Commit

Permalink
Remove 2.0 branch. Bring back dataplaneapi v2 as /usr/local/bin/datap…
Browse files Browse the repository at this point in the history
…laneapi-v2
  • Loading branch information
dkorunic committed Sep 11, 2024
1 parent 8261f99 commit 3d28277
Show file tree
Hide file tree
Showing 13 changed files with 68 additions and 231 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/docker_manual.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
packages: write
strategy:
matrix:
branch: ["2.0", "2.2", "2.4", "2.6", "2.8", "2.9", "3.0", "3.1"]
branch: ["2.2", "2.4", "2.6", "2.8", "2.9", "3.0", "3.1"]
env:
DOCKER_PLATFORMS: linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64
DOCKER_IMAGE: haproxytech/haproxy-alpine
Expand Down
82 changes: 0 additions & 82 deletions 2.0/Dockerfile

This file was deleted.

17 changes: 0 additions & 17 deletions 2.0/docker-entrypoint.sh

This file was deleted.

102 changes: 0 additions & 102 deletions 2.0/haproxy.cfg

This file was deleted.

9 changes: 8 additions & 1 deletion 2.2/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
FROM golang:alpine3.20 AS builder

ENV DATAPLANE_MINOR 3.0.0
ENV DATAPLANE_V2_MINOR 2.9.6
ENV DATAPLANE_URL https://github.com/haproxytech/dataplaneapi.git

RUN apk add --no-cache ca-certificates git make && \
git clone "${DATAPLANE_URL}" "${GOPATH}/src/github.com/haproxytech/dataplaneapi" && \
cd "${GOPATH}/src/github.com/haproxytech/dataplaneapi" && \
git checkout "v${DATAPLANE_MINOR}" && \
make build && cp build/dataplaneapi /dataplaneapi
make build && cp build/dataplaneapi /dataplaneapi && \
make clean && \
git checkout "v${DATAPLANE_V2_MINOR}" && \
make build && cp build/dataplaneapi /dataplaneapi-v2

FROM alpine:3.18

Expand All @@ -32,6 +36,7 @@ ENV HAPROXY_UID haproxy
ENV HAPROXY_GID haproxy

COPY --from=builder /dataplaneapi /usr/local/bin/dataplaneapi
COPY --from=builder /dataplaneapi-v2 /usr/local/bin/dataplaneapi-v2

RUN apk add --no-cache ca-certificates && \
apk add --no-cache --virtual build-deps gcc libc-dev \
Expand Down Expand Up @@ -68,6 +73,8 @@ RUN apk add --no-cache ca-certificates && \
rm -rf /tmp/haproxy && \
chmod +x /usr/local/bin/dataplaneapi && \
ln -s /usr/local/bin/dataplaneapi /usr/bin/dataplaneapi && \
chmod +x /usr/local/bin/dataplaneapi-v2 && \
ln -s /usr/local/bin/dataplaneapi-v2 /usr/bin/dataplaneapi-v2 && \
touch /usr/local/etc/haproxy/dataplaneapi.yml && \
chown "$HAPROXY_UID:$HAPROXY_GID" /usr/local/etc/haproxy/dataplaneapi.yml && \
apk del build-deps && \
Expand Down
9 changes: 8 additions & 1 deletion 2.4/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
FROM golang:alpine3.20 AS builder

ENV DATAPLANE_MINOR 3.0.0
ENV DATAPLANE_V2_MINOR 2.9.6
ENV DATAPLANE_URL https://github.com/haproxytech/dataplaneapi.git

RUN apk add --no-cache ca-certificates git make && \
git clone "${DATAPLANE_URL}" "${GOPATH}/src/github.com/haproxytech/dataplaneapi" && \
cd "${GOPATH}/src/github.com/haproxytech/dataplaneapi" && \
git checkout "v${DATAPLANE_MINOR}" && \
make build && cp build/dataplaneapi /dataplaneapi
make build && cp build/dataplaneapi /dataplaneapi && \
make clean && \
git checkout "v${DATAPLANE_V2_MINOR}" && \
make build && cp build/dataplaneapi /dataplaneapi-v2

FROM alpine:3.20

Expand All @@ -28,6 +32,7 @@ ENV HAPROXY_UID haproxy
ENV HAPROXY_GID haproxy

COPY --from=builder /dataplaneapi /usr/local/bin/dataplaneapi
COPY --from=builder /dataplaneapi-v2 /usr/local/bin/dataplaneapi-v2

RUN apk add --no-cache ca-certificates jemalloc && \
apk add --no-cache --virtual build-deps gcc libc-dev \
Expand Down Expand Up @@ -57,6 +62,8 @@ RUN apk add --no-cache ca-certificates jemalloc && \
rm -rf /tmp/haproxy && \
chmod +x /usr/local/bin/dataplaneapi && \
ln -s /usr/local/bin/dataplaneapi /usr/bin/dataplaneapi && \
chmod +x /usr/local/bin/dataplaneapi-v2 && \
ln -s /usr/local/bin/dataplaneapi-v2 /usr/bin/dataplaneapi-v2 && \
touch /usr/local/etc/haproxy/dataplaneapi.yml && \
chown "$HAPROXY_UID:$HAPROXY_GID" /usr/local/etc/haproxy/dataplaneapi.yml && \
apk del build-deps && \
Expand Down
13 changes: 8 additions & 5 deletions 2.6/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
FROM golang:alpine3.20 AS builder

ENV DATAPLANE_MINOR 3.0.0
ENV DATAPLANE_V2_MINOR 2.9.6
ENV DATAPLANE_URL https://github.com/haproxytech/dataplaneapi.git

RUN apk add --no-cache ca-certificates git make && \
git clone "${DATAPLANE_URL}" "${GOPATH}/src/github.com/haproxytech/dataplaneapi" && \
cd "${GOPATH}/src/github.com/haproxytech/dataplaneapi" && \
git checkout "v${DATAPLANE_MINOR}" && \
make build && cp build/dataplaneapi /dataplaneapi
make build && cp build/dataplaneapi /dataplaneapi && \
make clean && \
git checkout "v${DATAPLANE_V2_MINOR}" && \
make build && cp build/dataplaneapi /dataplaneapi-v2

FROM alpine:3.20

Expand All @@ -24,14 +28,11 @@ ENV HAPROXY_MINOR 2.6.18
ENV HAPROXY_SHA256 1b36d3c618360eff7cdc2b70dd53affdf9c939d0fdf8602ac2d77018535f709a
ENV HAPROXY_SRC_URL http://www.haproxy.org/download

ENV DATAPLANE_MINOR 3.0.0
ENV DATAPLANE_SHA256 ec685350576898bb0a00d656f427f5da7c28043551a3e0050c1b5301547e235a
ENV DATAPLANE_URL https://github.com/haproxytech/dataplaneapi/releases/download

ENV HAPROXY_UID haproxy
ENV HAPROXY_GID haproxy

COPY --from=builder /dataplaneapi /usr/local/bin/dataplaneapi
COPY --from=builder /dataplaneapi-v2 /usr/local/bin/dataplaneapi-v2

RUN apk add --no-cache ca-certificates jemalloc && \
apk add --no-cache --virtual build-deps gcc libc-dev \
Expand Down Expand Up @@ -61,6 +62,8 @@ RUN apk add --no-cache ca-certificates jemalloc && \
rm -rf /tmp/haproxy && \
chmod +x /usr/local/bin/dataplaneapi && \
ln -s /usr/local/bin/dataplaneapi /usr/bin/dataplaneapi && \
chmod +x /usr/local/bin/dataplaneapi-v2 && \
ln -s /usr/local/bin/dataplaneapi-v2 /usr/bin/dataplaneapi-v2 && \
touch /usr/local/etc/haproxy/dataplaneapi.yml && \
chown "$HAPROXY_UID:$HAPROXY_GID" /usr/local/etc/haproxy/dataplaneapi.yml && \
apk del build-deps && \
Expand Down
13 changes: 8 additions & 5 deletions 2.8/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
FROM golang:alpine3.20 AS builder

ENV DATAPLANE_MINOR 3.0.0
ENV DATAPLANE_V2_MINOR 2.9.6
ENV DATAPLANE_URL https://github.com/haproxytech/dataplaneapi.git

RUN apk add --no-cache ca-certificates git make && \
git clone "${DATAPLANE_URL}" "${GOPATH}/src/github.com/haproxytech/dataplaneapi" && \
cd "${GOPATH}/src/github.com/haproxytech/dataplaneapi" && \
git checkout "v${DATAPLANE_MINOR}" && \
make build && cp build/dataplaneapi /dataplaneapi
make build && cp build/dataplaneapi /dataplaneapi && \
make clean && \
git checkout "v${DATAPLANE_V2_MINOR}" && \
make build && cp build/dataplaneapi /dataplaneapi-v2

FROM alpine:3.20

Expand All @@ -24,14 +28,11 @@ ENV HAPROXY_MINOR 2.8.10
ENV HAPROXY_SHA256 0d63cd46d9d10ac7dbc02f3c6769c1908f221e0a5c5b655a194655f7528d612a
ENV HAPROXY_SRC_URL http://www.haproxy.org/download

ENV DATAPLANE_MINOR 3.0.0
ENV DATAPLANE_SHA256 ec685350576898bb0a00d656f427f5da7c28043551a3e0050c1b5301547e235a
ENV DATAPLANE_URL https://github.com/haproxytech/dataplaneapi/releases/download

ENV HAPROXY_UID haproxy
ENV HAPROXY_GID haproxy

COPY --from=builder /dataplaneapi /usr/local/bin/dataplaneapi
COPY --from=builder /dataplaneapi-v2 /usr/local/bin/dataplaneapi-v2

RUN apk add --no-cache ca-certificates jemalloc && \
apk add --no-cache --virtual build-deps gcc libc-dev \
Expand Down Expand Up @@ -62,6 +63,8 @@ RUN apk add --no-cache ca-certificates jemalloc && \
rm -rf /tmp/haproxy && \
chmod +x /usr/local/bin/dataplaneapi && \
ln -s /usr/local/bin/dataplaneapi /usr/bin/dataplaneapi && \
chmod +x /usr/local/bin/dataplaneapi-v2 && \
ln -s /usr/local/bin/dataplaneapi-v2 /usr/bin/dataplaneapi-v2 && \
touch /usr/local/etc/haproxy/dataplaneapi.yml && \
chown "$HAPROXY_UID:$HAPROXY_GID" /usr/local/etc/haproxy/dataplaneapi.yml && \
apk del build-deps && \
Expand Down
Loading

0 comments on commit 3d28277

Please sign in to comment.