forked from openperouter/openperouter
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile.openshift
More file actions
51 lines (42 loc) · 2.15 KB
/
Dockerfile.openshift
File metadata and controls
51 lines (42 loc) · 2.15 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
# Build the manager binary
FROM brew.registry.redhat.io/rh-osbs/openshift-golang-builder:rhel_9_golang_1.25 AS builder
ARG GIT_COMMIT=dev
ARG GIT_BRANCH=dev
ARG TARGETOS
ARG TARGETARCH
WORKDIR $GOPATH/openperouter
COPY . .
RUN GOEXPERIMENT=strictfipsruntime CGO_ENABLED=1 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} go build -v -mod=vendor -tags strictfipsruntime -o reloader ./cmd/reloader \
&& \
GOEXPERIMENT=strictfipsruntime CGO_ENABLED=1 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} go build -v -mod=vendor -tags strictfipsruntime -o controller ./cmd/hostcontroller \
&& \
GOEXPERIMENT=strictfipsruntime CGO_ENABLED=1 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} go build -v -mod=vendor -tags strictfipsruntime -o nodemarker ./cmd/nodemarker \
&& \
GOEXPERIMENT=strictfipsruntime CGO_ENABLED=1 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} go build -v -mod=vendor -tags strictfipsruntime -o hostbridge ./cmd/hostbridge \
&& \
GOEXPERIMENT=strictfipsruntime CGO_ENABLED=1 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} go build -v -mod=vendor -tags strictfipsruntime -o operatorbinary ./operator
FROM registry.redhat.io/openshift4/frr-rhel9:v4.21
WORKDIR /
COPY --from=builder /go/openperouter/reloader .
COPY --from=builder /go/openperouter/controller .
COPY --from=builder /go/openperouter/hostbridge .
COPY --from=builder /go/openperouter/nodemarker .
COPY --from=builder /go/openperouter/operatorbinary ./operator
COPY operator/bindata bindata
# Copy FRR startup configuration to the default location
COPY systemdmode/frrconfig/daemons /etc/frr/daemons
COPY systemdmode/frrconfig/vtysh.conf /etc/frr/vtysh.conf
COPY systemdmode/frrconfig/frr.conf /etc/frr/frr.conf
LABEL com.redhat.component="openperouter" \
name="openshift4-dev-preview-beta/openperouter-rhel9-operator" \
summary="openperouter" \
io.openshift.expose-services="" \
io.openshift.tags="openperouter" \
io.k8s.display-name="openperouter" \
io.k8s.description="openperouter" \
description="openperouter" \
distribution-scope="public" \
release="5.0" \
url="https://github.com/openperouter/openperouter" \
vendor="Red Hat, Inc."
ENTRYPOINT ["/controller"]