forked from DiscordBots/lilJudd
chore: improve documentation of self-hosting using docker / docker-compose
Signed-off-by: moonleay <contact@moonleay.net>
This commit is contained in:
parent
52703b4b61
commit
5ad7fe0ae6
3 changed files with 49 additions and 6 deletions
|
@ -1,3 +1,4 @@
|
|||
**.nils
|
||||
/run
|
||||
/run/
|
||||
docker-compose.yml
|
||||
|
|
22
README.md
22
README.md
|
@ -33,12 +33,22 @@ More information can be found on the [Homepage](https://liljudd.ink).
|
|||
|
||||
## How to self-host (using the Docker container)
|
||||
|
||||
1. Pull the container from [Docker Hub](https://hub.docker.com/repository/docker/limiteddev/liljudd/general)
|
||||
2. Map /data/ to a folder on disk
|
||||
3. Run the Bot once
|
||||
4. follow step 4 and 5 from the JAR section
|
||||
5. Run the Bot again
|
||||
6. Profit.
|
||||
1. Copy the docker-compose.yml file from the repository.
|
||||
2. Install docker and docker-compose.
|
||||
3. Create a directory called "data" in the same directory as the docker-compose.yml file.
|
||||
4. Create a directory called "config" in the same directory as the docker-compose.yml file.
|
||||
5. Start the bot once.
|
||||
6. After 10 seconds, stop the bot.
|
||||
7. Open the config file "credentials.nils" in the config directory.
|
||||
8. Put in your credentials.
|
||||
1. token: your Discord bot token
|
||||
2. dbDomain: the domain and port of your postgresql database (e.g.: "postgresql", when using the docker-compose.yml
|
||||
file)
|
||||
3. dbName: the name of the database
|
||||
4. dbUser: the username of the database
|
||||
5. dbPassword: the password to the db user
|
||||
9. Start the bot again.
|
||||
10. The bot should now be up and running.
|
||||
|
||||
## How to self-host (using the JAR)
|
||||
|
||||
|
|
32
docker-compose.yml
Normal file
32
docker-compose.yml
Normal file
|
@ -0,0 +1,32 @@
|
|||
version: "3"
|
||||
services:
|
||||
lilJudd:
|
||||
container_name: liljudd
|
||||
image: limiteddev/liljudd:x.x.x
|
||||
deploy:
|
||||
resources:
|
||||
limits:
|
||||
cpus: "1"
|
||||
memory: 1G
|
||||
networks:
|
||||
- traefik
|
||||
restart: unless-stopped
|
||||
volumes:
|
||||
- ./config/liljudd/:/data/
|
||||
postgresql:
|
||||
container_name: postgresql
|
||||
image: postgres:13.3-alpine
|
||||
deploy:
|
||||
resources:
|
||||
limits:
|
||||
cpus: "1"
|
||||
memory: 1G
|
||||
environment:
|
||||
- POSTGRES_USER=liljudd
|
||||
- POSTGRES_PASSWORD=changeme
|
||||
- POSTGRES_DB=liljudd
|
||||
networks:
|
||||
- traefik
|
||||
restart: unless-stopped
|
||||
volumes:
|
||||
- ./data/postgresql/:/var/lib/postgresql/data/
|
Loading…
Reference in a new issue