docs: update default dev port; document env vars for manual prod setup

This commit is contained in:
Dragory 2024-04-07 09:10:47 +00:00
parent ae03c9e03b
commit bea395982c
No known key found for this signature in database
2 changed files with 19 additions and 6 deletions

View file

@ -23,7 +23,7 @@ Below you can find instructions for setting up the environment and getting start
4. Run `docker compose -f docker-compose.development.yml up` to start the development environment
5. In VSCode: Install the `Remote - SSH` plugin
6. In VSCode: Run `Remote-SSH: Connect to Host...`
* As the address, use `ubuntu@127.0.0.1:3002` (where `3002` matches `DEVELOPMENT_SSH_PORT` in `.env`)
* As the address, use `ubuntu@127.0.0.1:3022` (where `3022` matches `DEVELOPMENT_SSH_PORT` in `.env`)
* Use the password specified in `.env` as `DEVELOPMENT_SSH_PASSWORD`
7. In VSCode: Once connected, click `Open folder...` and select `/home/ubuntu/zeppelin`
@ -35,7 +35,7 @@ Below you can find instructions for setting up the environment and getting start
5. Choose `Connect via SSH` and create a new connection:
* Username: `ubuntu`
* Host: `127.0.0.1`
* Port: `3002` (matching the `DEVELOPMENT_SSH_PORT` value in `.env`)
* Port: `3022` (matching the `DEVELOPMENT_SSH_PORT` value in `.env`)
6. Click `Check Connection and Continue` and enter the password specified in `.env` as `DEVELOPMENT_SSH_PASSWORD` when asked
7. In the next pane:
* IDE version: WebStorm, PHPStorm, or IntelliJ IDEA
@ -49,12 +49,12 @@ Below you can find instructions for setting up the environment and getting start
4. Run `docker compose -f docker-compose.development.yml up` to start the development environment
5. Use the following credentials for connecting with your IDE:
* Host: `127.0.0.1`
* Port: `3002` (matching the `DEVELOPMENT_SSH_PORT` value in `.env`)
* Port: `3022` (matching the `DEVELOPMENT_SSH_PORT` value in `.env`)
* Username: `ubuntu`
* Password: As specified in `.env` as `DEVELOPMENT_SSH_PASSWORD`
## Starting the project
These commands are run inside the dev container. You should be able to open a terminal in your IDE after connecting.
These commands are run inside the dev container. You should be able to open a terminal in your IDE after connecting to the dev environment.
### 1. Install dependencies

View file

@ -18,7 +18,7 @@ Zeppelin's production environment uses Docker. There are a few different ways to
2. Make a copy of `.env.example` called `.env`
3. Fill in the missing values in `.env` (including the "PRODUCTION - STANDALONE" section)
**Note:** The dashboard and API are exposed with a self-signed certificate. It is recommended to set up a proxy with a proper certificate in front of them. A popular option for this is [Cloudflare Tunnel](https://www.cloudflare.com/products/tunnel/).
**Note:** The dashboard and API are served insecurely over HTTP. It is recommended to set up a proxy with a TLS certificate in front of them. A popular option for this is [Cloudflare Tunnel](https://www.cloudflare.com/products/tunnel/).
### Running the bot
`docker compose -f docker-compose.standalone.yml up -d`
@ -68,4 +68,17 @@ If you're using an application platform such as Railway, you can simply point it
For the start command, you can use the same commands as above: `npm run start-bot`, `npm run start-api`, `npm run start-dashboard`.
Make sure to also run migrations when you update the bot.
**Note:** You'll need to provide the necessary env variables. For example, `docker run --env-file .env zeppelin`
### Environment variables
You'll need to provide the necessary env variables in the manual setup. For example, `docker run -e NODE_ENV=production --env-file .env zeppelin`
The following env variables can be used to set up the database credentials:
* `DB_HOST`
* `DB_PORT`
* `DB_USER`
* `DB_PASSWORD`
* `DB_DATABASE`
The following env variable can be used to configure the API path prefix:
* `API_PATH_PREFIX`
Remember to always set `NODE_ENV` to `production` for production setups.