clburlison / Flygon-Admin

Admin panel for Flygon

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Flygon Admin

Discord

Pre Requisites

  1. Go 1.20
  2. Node 18
  3. Yarn 1.22
  4. Flygon
  5. Golbat (Optional)

Standard Setup

  1. Clone Repo
git clone https://github.com/UnownHash/Flygon-Admin.git`
  1. Create the config file
cp config.toml.example config.toml
  1. Fill out the config file
nano config.toml
  1. Compile the client
cd client
yarn install
yarn build
  1. Compile the server
cd ../server
go build
  1. Run server
./server

Updating

  1. Pull repo
git pull
  1. Repeat steps 4-6 from the standard setup

PM2 Setup

  1. Install PM2
npm install pm2 -g
  1. Follow steps 1-5 from the standard setup
  2. From the server directory, add to PM2:
pm2 start server --name "Flygon-Admin"
  1. Save PM2 processes
pm2 save

Updating

  1. Follow steps 4-5 from the standard setup
  2. Restart PM2 process
pm2 restart Flygon-Admin

Docker Setup

  1. Copy docker-compose file
cp docker-compose.yml docker-compose.override.yml
  1. Fill out the docker-compose.override.yml file, not the docker-compose.yml file
nano docker-compose.override.yml
  1. Run docker-compose
docker-compose up -d

Updating

docker-compose pull
docker-compose down
docker-compose up -d

Development

Pre Requisites

  1. Same as above
  2. gow (Recommended)

Terminal 1

Run the client in dev mode with hot reloading

cd client
yarn install
yarn dev

Terminal 2

Run the server in dev mode with file watching

cd server
gow run . # or go run .

About

Admin panel for Flygon

License:MIT License


Languages

Language:TypeScript 86.0%Language:Go 10.1%Language:JavaScript 2.5%Language:HTML 0.9%Language:Dockerfile 0.5%