Skip to content

Commit

Permalink
Fix bug with dockerfile
Browse files Browse the repository at this point in the history
- fix: bug with Dockerfile for cgo problems within alpine due to stdlib.h
- chore: update versions for deployments. now we will be using v0.x
  • Loading branch information
isu-kim committed Feb 20, 2024
1 parent e5e86b2 commit b289081
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion ai-engine/Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# SPDX-License-Identifier: Apache-2.0

IMAGE_NAME = 5gsec/sentryflow-ai-engine
TAG = v0.0.1
TAG = v0.1

.PHONY: build

Expand Down
4 changes: 2 additions & 2 deletions deployments/sentryflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ spec:
spec:
containers:
- name: sentryflow
image: 5gsec/sentryflow-ai-engine:v0.0.1
image: 5gsec/sentryflow-ai-engine:v0.1
ports:
- containerPort: 5000
protocol: TCP
Expand Down Expand Up @@ -91,7 +91,7 @@ spec:
serviceAccountName: sa-sentryflow
containers:
- name: sentryflow
image: 5gsec/sentryflow:v0.0.1
image: 5gsec/sentryflow:v0.1
ports:
- containerPort: 4317
protocol: TCP
Expand Down
4 changes: 3 additions & 1 deletion sentryflow/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ FROM golang:1.19-alpine3.17 as builder

RUN apk --no-cache update
RUN apk add --no-cache git clang llvm make gcc protobuf make
RUN apk add --update alpine-sdk
RUN go install github.com/golang/protobuf/protoc-gen-go@latest
RUN go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest

Expand All @@ -21,6 +22,7 @@ WORKDIR /app
COPY /sentryflow .

RUN go mod tidy
RUN export CGO_ENABLED=1; export CC=gcc;
RUN go build -o sentryflow

### Make executable image
Expand All @@ -34,4 +36,4 @@ RUN apk add bash

COPY --from=builder /app/sentryflow .

CMD ["./sentryflow"]
CMD ["./sentryflow"]

0 comments on commit b289081

Please sign in to comment.