Simplify deployment workflow
This commit is contained in:
parent
1e40a42524
commit
0d77557ad6
3 changed files with 46 additions and 0 deletions
21
.dockerignore
Normal file
21
.dockerignore
Normal file
|
@ -0,0 +1,21 @@
|
|||
# flyctl launch added from .gitignore
|
||||
**/.env.local
|
||||
**/config.yaml
|
||||
target
|
||||
|
||||
# other things
|
||||
docs/*
|
||||
fedimovies-*
|
||||
scripts/*
|
||||
src/*
|
||||
|
||||
# flyctl launch added from .idea/.gitignore
|
||||
# Default ignored files
|
||||
.idea/shelf
|
||||
.idea/workspace.xml
|
||||
# Editor-based HTTP Client requests
|
||||
.idea/httpRequests
|
||||
# Datasource local storage ignored files
|
||||
.idea/dataSources
|
||||
.idea/dataSources.local.xml
|
||||
fly.toml
|
16
contrib/Dockerfile
Normal file
16
contrib/Dockerfile
Normal file
|
@ -0,0 +1,16 @@
|
|||
FROM ubuntu:23.04
|
||||
|
||||
RUN apt-get update && apt-get install -y \
|
||||
curl \
|
||||
wget \
|
||||
ca-certificates \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN mkdir -p /var/lib/data
|
||||
|
||||
COPY build/fedimovies /usr/local/bin
|
||||
COPY build/fedimoviesctl /usr/local/bin
|
||||
COPY secret/fedimovies.conf /etc/fedimovies.conf
|
||||
COPY files /www/frontend/
|
||||
|
||||
CMD ["/usr/local/bin/fedimovies"]
|
9
justfile
Normal file
9
justfile
Normal file
|
@ -0,0 +1,9 @@
|
|||
#!/usr/bin/env -S just --justfile
|
||||
|
||||
build-release:
|
||||
cargo build --release --target x86_64-unknown-linux-gnu
|
||||
cp target/x86_64-unknown-linux-gnu/release/fedimovies build/fedimovies
|
||||
cp target/x86_64-unknown-linux-gnu/release/fedimoviesctl build/fedimoviesctl
|
||||
|
||||
deploy: build-release
|
||||
fly deploy
|
Loading…
Reference in a new issue