Files
personal-website/README.md
2024-08-03 03:44:47 +03:00

1.3 KiB

Personal Website

This is the source code of my personal website.

Setup with Docker Compose

Clone this repository and enter it

git clone https://git.weirdcat.su/weirdcat/personal-website
cd personal-website

Choose the stable branch

git checkout stable

Customize the .env file. Make sure to change the parameters for your site's hostname and PostgreSQL username and password, as well as the environment variables for JWT

# Trusted hostname
HOSTNAME=localhost

# --- Container ports and hostnames ---

BACKEND_HOST=personal-site-backend
FRONTEND_HOST=personal-site-frontend
DB_HOST=personal-site-db

# --- Database settings ---

DB_USER=postgres
DB_PASSWORD=postgres
DB_DB=data

# --- JWT token settings ---

JWT_SECRET=ThisValueIsObviouslyVerySecret
JWT_EXPIRATION_ACCESS=2m # Expiration time for access tokens
JWT_EXPIRATION_REFRESH=7d # Expiration time for refresh tokens
JWT_ISSUER=personal-site
JWT_AUDIENCE=users

Run the application via docker-compose

sudo docker-compose up -d

Setting up reverse proxy

In order to make the application accessible, a reverse proxy must be setup. I'm lazy to explain that now, so it's temporarily recommended to refer to this article.