add docker stuff
This commit is contained in:
parent
87d3150a50
commit
7aa4b8997c
|
@ -0,0 +1,3 @@
|
||||||
|
/target
|
||||||
|
Dockerfile
|
||||||
|
docker-compose.yml
|
|
@ -1 +1,2 @@
|
||||||
/target
|
/target
|
||||||
|
docker-compose.yml
|
||||||
|
|
|
@ -3,11 +3,13 @@ FROM rust:alpine3.19 as builder
|
||||||
WORKDIR /opt/build
|
WORKDIR /opt/build
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|
||||||
|
RUN apk add --no-cache musl-dev
|
||||||
RUN cargo b -r
|
RUN cargo b -r
|
||||||
|
|
||||||
FROM alpine:3.19
|
FROM alpine:3.19
|
||||||
|
LABEL maintainer='blek! <me@blek.codes>'
|
||||||
|
|
||||||
COPY . /usr/share/invite-maker-src
|
COPY . /usr/share/invite-maker-src
|
||||||
COPY --from=builder /opt/build/target/invite-maker /usr/bin/invite-maker
|
COPY --from=builder /opt/build/target/release/invite-maker /usr/bin/invite-maker
|
||||||
|
|
||||||
CMD [ "/usr/bin/invite-maker" ]
|
CMD [ "/usr/bin/invite-maker" ]
|
|
@ -0,0 +1,12 @@
|
||||||
|
# modify this file to suit your server configuration
|
||||||
|
|
||||||
|
services:
|
||||||
|
server:
|
||||||
|
build:
|
||||||
|
target: .
|
||||||
|
dockerfile: Dockerfile
|
||||||
|
restart: always
|
||||||
|
ports:
|
||||||
|
- 8080:8080
|
||||||
|
environment:
|
||||||
|
LISTEN: 0.0.0.0:8080
|
Loading…
Reference in New Issue