mirror of
https://github.com/atuinsh/atuin.git
synced 2024-11-22 00:03:49 +01:00
fix: dockerfile with correct glibc (#198)
* fix: dockerfile with correct glibc * chore: update server docs
This commit is contained in:
parent
8f91b1410c
commit
46a1dab132
19
Dockerfile
19
Dockerfile
@ -1,23 +1,18 @@
|
||||
FROM lukemathwalker/cargo-chef as planner
|
||||
FROM lukemathwalker/cargo-chef:latest-rust-1.56.1 AS chef
|
||||
WORKDIR app
|
||||
COPY . .
|
||||
RUN cargo chef prepare --recipe-path recipe.json
|
||||
|
||||
FROM lukemathwalker/cargo-chef as cacher
|
||||
WORKDIR app
|
||||
FROM chef AS planner
|
||||
COPY . .
|
||||
RUN cargo chef prepare --recipe-path recipe.json
|
||||
|
||||
FROM chef AS builder
|
||||
COPY --from=planner /app/recipe.json recipe.json
|
||||
RUN cargo chef cook --release --recipe-path recipe.json
|
||||
|
||||
FROM rust as builder
|
||||
WORKDIR app
|
||||
COPY . .
|
||||
# Copy over the cached dependencies
|
||||
COPY --from=cacher /app/target target
|
||||
COPY --from=cacher $CARGO_HOME $CARGO_HOME
|
||||
RUN cargo build --release --bin atuin
|
||||
|
||||
FROM debian:buster-slim as runtime
|
||||
|
||||
FROM debian:bullseye-20211011-slim AS runtime
|
||||
WORKDIR app
|
||||
|
||||
ENV TZ=Etc/UTC
|
||||
|
@ -19,19 +19,50 @@ OPTIONS:
|
||||
-p, --port <port>
|
||||
```
|
||||
|
||||
## Configuration
|
||||
|
||||
The config for the server is kept separate from the config for the client, even
|
||||
though they are the same binary. Server config can be found at
|
||||
`~/.config/atuin/server.toml`.
|
||||
|
||||
It looks something like this:
|
||||
|
||||
```
|
||||
```toml
|
||||
host = "0.0.0.0"
|
||||
port = 8888
|
||||
open_registration = true
|
||||
db_uri="postgres://user:password@hostname/database"
|
||||
```
|
||||
|
||||
`open_registration` sets whether the server allows new user registrations. Set
|
||||
this to false after making your own account if you don't want others to be able
|
||||
to use your server.
|
||||
Alternatively, configuration can also be provided with environment variables.
|
||||
|
||||
```sh
|
||||
ATUIN_HOST="0.0.0.0"
|
||||
ATUIN_PORT=8888
|
||||
ATUIN_OPEN_REGISTRATION=true
|
||||
ATUIN_DB_URI="postgres://user:password@hostname/database"
|
||||
```
|
||||
|
||||
### host
|
||||
|
||||
The host address the atuin server should listen on.
|
||||
|
||||
Defaults to `127.0.0.1`.
|
||||
|
||||
### port
|
||||
|
||||
The post the atuin server should listen on.
|
||||
|
||||
Defaults to `8888`.
|
||||
|
||||
### open_registration
|
||||
|
||||
If `true`, atuin will accept new user registrations.
|
||||
Set this to `false` after making your own account if you don't want others to be
|
||||
able to use your server.
|
||||
|
||||
Defaults to `false`.
|
||||
|
||||
### db_uri
|
||||
|
||||
A valid postgres URI, where the user and history data will be saved to.
|
||||
|
Loading…
Reference in New Issue
Block a user