Skip to content

barsikus007/fastapi-react-boilerplate

Repository files navigation

fasta-react-boilerplate

Features

  • boilerplate
  • ???
  • PROFIT
  • (and cute http.cat error pages)

Installation

Install docker

On Windows

Windows 11 or with winget installed
wsl --install -d Ubuntu
winget install Docker.DockerDesktop -h
Below Windows 11

Installer

On Linux

Convinient script

# install docker
curl -sSL https://get.docker.com | sh
sudo groupadd docker
sudo usermod -aG docker $USER
newgrp docker; exit

On MacOS

Installer

Arm issues resolution

Due to possible issues with several packages, which haven't builds for linux aarch64, you can use buildx

COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 DOCKER_DEFAULT_PLATFORM=linux/amd64 docker-compose up -d --build {issued-service}
docker-compose up -d --build {other-services}

Launch app

Copy .env.example to .env and change settings

Development mode

docker compose up -d --build

Production mode

docker compose -f compose.prod.yaml up -d --build

Untemplating

  • s/fastapi-react-boilerplate/your-project-name/g

FastAPI React Boilerplate TODO

frontend

backend

devops

  • tasks for database backup and restore
  • file serving example
    • nginx serve static files
    • max filesize deps for FastAPI
    • nginx client_max_body_size 100M;
    • GUID in env or another workaround for correct file rights (container user not root) (migrations for example)
  • update && fix compose.debug.yaml
    • backend
    • frontend
  • docker secrets
  • prod related
  • nginx to traefik ?
    • https is easier in traefik

other