-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.example
More file actions
81 lines (65 loc) · 4.71 KB
/
.env.example
File metadata and controls
81 lines (65 loc) · 4.71 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
# Database connection details
DB_HOST=localhost
DB_USER=bitjourney
DB_PASSWORD=password
DB_NAME=bitjourney
#HTTP_API_PORT=3333 # Change (and uncomment) this to tell Navigator to listen for HTTP requests over a different port
#RT_API_PORT=3334 # Change (and uncomment) this to tell Navigator to listen for socket.io connections over a different port
# This should point to the `/sdapi/v1` URL that Forge is accessible at
# Ensure that you've started Forge with the `--api` flag
SD_API_HOST=http://localhost:7860/sdapi/v1
# Uses https://github.com/vercel/ms - ('72h', '14d', etc) set to -1 for no expiration (default 14d if not defined)
# Note: Upon changing, any existing tokens will keep their current expiration - changes require a new token to take effect
# To force invalidate tokens, change the SECRET_KEY below. To invalidate tokens with -1 expiration, this is required.
# Regardless of the setting here, if demo users are enabled below, their tokens always expire after three hours.
TOKEN_EXPIRATION_TIME=14d
# Secret key used to sign JWT tokens
SECRET_KEY=
# Insert a randomized sequence of characters here, it will act as a static-never-expiring API key that has the highest
# application privileges. Can be used to grant your own account permissions.
# When using over the HTTP API, use with the `Authorization` header but do not include the `Bearer` prefix.
SUPERUSER_ADMIN_TOKEN=
# Uncomment this to allow clients to gain access to a demo account by using the `DEMO_USER` authorization code
# Take caution when enabling this on a public instance, as it effectively is no authentication
# Demo users will have the 2nd level permission role, which allows them to download models via the API
# Commenting this back out (or setting it to false) and then restarting Navigator will cause demo sessions to be invalid
#ENABLE_DEMO_USER=true
# This is used by Navigator when authorizing new users to verify that the provided Discord ID actually exists.
# You can leave this blank if you do not want Navigator to validate the existence of Discord IDs.
BOT_TOKEN=
# Set to true if the backend supports Flux-based models
SUPPORTS_FLUX=false
# API key for CivitAI
CIVITAI_API_KEY=
# Directory where Forge stores all of the models (should contain `Stable-diffusion`,`Lora`,`VAE`, etc)
MODEL_DIR=/path/to/forge/models
# Get these details from https://discord.com/developers
# Downstream clients will need to use the same Client ID and Redirect URI
DISCORD_CLIENT_ID=
DISCORD_CLIENT_SECRET=
DISCORD_REDIRECT_URI=http://localhost/
# This controls how often (in milliseconds) will Navigator check the Forge backend for Job progress updates
# Be careful with this value, as things like saving preview images to the database will occur within this interval.
# Also, downstream clients will receive updates at this rate as well, so take caution when using third party clients
# such as Discord (ie BitJourney Discord Plugin), as you may run into rate-limits from their service.
# Additionally, if Navigator and Forge OR MySQL are not on the same server, you need to take caution that you do not
# make this value lower than the latency between these services or else strange things may happen.
# In general, you probably do not want this lower than 500 miliseconds.
JOB_PROGRESS_CHECK_INTERVAL=2500
# Allows downstream clients to request available Loras from Forge (with metadata pulled from CivitAI)
# defaults to disabled, which just returns an empty array when the endpoint is hit.
ENABLE_LORA_SUPPORT=false
# Navigator limits generated image sizes by pixel count instead of by resolution to give users more flexibility.
# The constraint is your GPU's VRAM, basically lower VRAM = lower amount of pixels that can be generated.
# Default value below is 2560 x 1440, but you can change this to whatever is the highest you've been able to reliably
# generate.
# Downstream clients can use the `/api/config/limits` endpoint to dynamically obtain this, but even if they do not then
# Navigator will enforce this anyways (by rejecting requests that are higher than this limit).
IMAGE_PIXEL_LIMIT=3686400
# Navigator can automatically unload checkpoints from Forge after a specified inactivity interval, to save on VRAM.
# This can be useful for systems that might run other VRAM heavy applications such as LLMs, or games.
# This value is measured in minutes, setting this to any value above 0 will cause Navigator to automatically request
# Forge to unload the active checkpoint if no jobs have occurred in the specified interval.
# When a new job starts after the checkpoint has been unloaded, then the checkpoint for the job will be loaded again.
# Note: The internal task for this check executes every five minutes, so setting this below five is the same as setting it to 5.
CHECKPOINT_UNLOAD_INTERVAL=-1