[add] Custom Dockerfile to run python scripts
This commit is contained in:
20
Dockerfile
Normal file
20
Dockerfile
Normal file
@@ -0,0 +1,20 @@
|
||||
FROM golang:1.15-alpine AS build
|
||||
|
||||
ARG VERSION
|
||||
|
||||
ARG MUBENG_VERSION=v0.10.0
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
RUN wget https://github.com/kitabisa/mubeng/archive/refs/tags/$MUBENG_VERSION.tar.gz && tar -xzf $MUBENG_VERSION.tar.gz --strip-components 1
|
||||
|
||||
RUN go mod download
|
||||
|
||||
RUN go build -ldflags "-s -w -X ktbs.dev/mubeng/common.Version=${VERSION}" \
|
||||
-o ./bin/mubeng ./cmd/mubeng
|
||||
|
||||
FROM python:3.10-alpine3.16
|
||||
|
||||
COPY --from=build /app/bin/mubeng /bin/mubeng
|
||||
ENV HOME /
|
||||
ENTRYPOINT ["/bin/mubeng"]
|
||||
@@ -1,7 +1,7 @@
|
||||
version: '3.7'
|
||||
services:
|
||||
mubeng:
|
||||
image: kitabisa/mubeng:v0.10.0
|
||||
build: .
|
||||
container_name: mubeng
|
||||
restart: always
|
||||
ports:
|
||||
|
||||
Reference in New Issue
Block a user