Compare commits

...

6 Commits

Author SHA1 Message Date
a0135f0f9a add catppuccin theme 2024-04-09 00:47:36 +12:00
9b52524548 Merge pull request 'simple-build' (#1) from simple-build into main
Reviewed-on: Ayaka/redlib#1
2024-04-09 00:41:39 +12:00
91eecdab9d add build 2024-04-09 00:39:22 +12:00
333aa3d810 Update Dockerfile.old 2024-04-09 00:38:30 +12:00
92648d9ea4 monumental fuckup :D
revert revert
2024-04-09 00:34:24 +12:00
bafc2e2773 revert e79242c9e7
revert v0.31.2
2024-04-09 00:33:39 +12:00
3 changed files with 53 additions and 5 deletions

View File

@ -1,16 +1,28 @@
FROM alpine:3.19
FROM rust:1.77.1-buster AS builder
WORKDIR /app
COPY ./ ./
RUN cargo build --release
FROM debian:stable
ARG TARGET
RUN apk add --no-cache curl
RUN apt-get update
RUN apt-get install -y ca-certificates wget
RUN curl -L https://github.com/redlib-org/redlib/releases/latest/download/redlib-${TARGET}.tar.gz | \
tar xz -C /usr/local/bin/
RUN apt-get clean -y; \
rm -rf /var/lib/apt/lists/* /var/cache/apt/*
COPY --from=builder /app/target/release/ /usr/local/bin
RUN adduser --home /nonexistent --no-create-home --disabled-password redlib
USER redlib
# Tell Docker to expose port 8080
# Tell Docker to expose port 808
EXPOSE 8080
# Run a healthcheck every minute to make sure redlib is functional

20
Dockerfile.old Normal file
View File

@ -0,0 +1,20 @@
FROM alpine:3.19
ARG TARGET
RUN apk add --no-cache curl
RUN curl -L https://github.com/redlib-org/redlib/releases/latest/download/redlib-${TARGET}.tar.gz | \
tar xz -C /usr/local/bin/
RUN adduser --home /nonexistent --no-create-home --disabled-password redlib
USER redlib
# Tell Docker to expose port 8080
EXPOSE 8080
# Run a healthcheck every minute to make sure redlib is functional
HEALTHCHECK --interval=1m --timeout=3s CMD wget --spider --q http://localhost:8080/settings || exit 1
CMD ["redlib"]

View File

@ -0,0 +1,16 @@
.dark {
--accent: #b4befe; /* lavender */
--green: #a6e3a1; /* green */
--text: #cdd6f4; /* text */
--foreground: #11111b; /* crust */
--background: #1e1e2e; /* base */
--outside: #11111b; /* crust */
--post: #11111b; /* crust */
--panel-border: none;
--highlighted: #313244; /* surface0 */
--visited: #6c7086; /* overlay0 */
--shadow: 0 0 0 transparent;
--nsfw: #fab387; /* peach */
--admin: #eba0ac; /* maroon */
}