- golang
- nodejs
- docker
- postgresql
First, run cp ./backend/.env.example ./backend/.env && cp ./frontend/.env.example ./frontend/.env.local
to generate the env files for both backend and frontend.
Edit the .env
file in backend
folder
OPEN_AI_KEY
- OpenAI API keyDATABASE_URL
- PostgreSQL database URL (eg.postgres://user:password@localhost:5432/database
)DOCKER_HOST
- Docker SDK API (eg.DOCKER_HOST=unix:///Users/<my-user>/Library/Containers/com.docker.docker/Data/docker.raw.sock
) more info
Optional:
PORT
- Port to run the server (default:8080
)OPEN_AI_MODEL
- OpenAI model (default:gpt-4-0125-preview
). The list of supported OpenAI models can be found here.
Edit the .env.local
file in frontend
folder
VITE_API_URL
- Backend API URL. Omit the URL scheme (e.g.,localhost:8080
NOThttp://localhost:8080
).
Run the command(s) in backend
folder
- Run
go run .
to start the server
The first run can be a long wait because the dependencies and the docker images need to be download to setup the backend environment. When you see output below, the server has started successfully:
<your-date> <your-time> connect to http://localhost:<your-port>/playground for GraphQL playground
Run the command(s) in frontend
folder
- Run
yarn
to install the dependencies - Run
yarn dev
to run the web app
Open your browser and visit the web app URL.