Skip to content

Development (Bare Metal Non Docker) Deployment

tkaixiang edited this page Nov 26, 2021 · 3 revisions

Dependencies

Get The Repo

git clone https://github.com/IRS-Cybersec/ctf_platform.git

Install Stuff

cd ctf_platform
cd client && npm i
cd ../api && npm i

Change API MongoDB Address

  • Edit /api/Utils/mongoDB.js and change the address from ctf-mongodb:27017 to localhost:27017
  • ALTERNATIVELY, we recommend adding the following line to your hosts file so that it automatically resolves ctf-mongodb to localhost:
    • 127.0.0.1 ctf-mongodb # Sieberrsec CTF Development
      
  • Please make sure that your MongoDB server is running beforehand on localhost:27017

Start the API & React dev server

# Starting the API
cd api
npm install -g nodemon # nodemon is used for fast refresh
npm run dev 

# Starting the client
cd client
npm start

Start development 😄

Footnotes:

  • You will likely want to change the Sieberrsec CTF logos to your own CTF's logos etc. and do your own styling
  • In this mode, static file paths (such as profile picutures and category images) specified inside the API will most likely not work, and you have to create them yourself
  • Validation, Indexes & Secret keys should be inserted automatically if they are not found