dockerify
This commit is contained in:
parent
a5d17d29aa
commit
014c031fbc
|
@ -1 +1,2 @@
|
||||||
/target
|
/target
|
||||||
|
Dockerfile
|
|
@ -0,0 +1,13 @@
|
||||||
|
# --- build ---
|
||||||
|
FROM rust:alpine as builder
|
||||||
|
|
||||||
|
WORKDIR /opt/build
|
||||||
|
COPY . .
|
||||||
|
|
||||||
|
RUN cargo b -r
|
||||||
|
|
||||||
|
# --- deploy ---
|
||||||
|
FROM alpine
|
||||||
|
|
||||||
|
COPY --from=builder /opt/build/target/release/filed /bin/filed
|
||||||
|
CMD [ "/bin/filed" ]
|
|
@ -1,3 +1,8 @@
|
||||||
# fileD - file daemon
|
# fileD - file daemon
|
||||||
This is a part of blek! File that is responsible for serving and uploading files.
|
This is a part of blek! File that is responsible for serving and uploading files.
|
||||||
This module is released under the GPLv3 with additions, copy of which is included in the top level of this repository.
|
This module is released under the GPLv3 with additions, copy of which is included in the top level of this repository.
|
||||||
|
|
||||||
|
## Building
|
||||||
|
To get started with this, copy either `Dockerfile.dev` or `Dockerfile.prod` to `Dockerfile`, depending on your environment.
|
||||||
|
|
||||||
|
Then either build it manually or start it up using the `docker-compose.yml` file, which is provided in the top level directory.
|
||||||
|
|
|
@ -0,0 +1,6 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
cargo check
|
||||||
|
cargo build
|
||||||
|
|
||||||
|
cargo watch -w src -w templates -x run
|
Loading…
Reference in New Issue