Skip to content

Commit 94ed9de

Browse files
committed
Merging develop into main
2 parents 3a73c99 + 3ee9d13 commit 94ed9de

40 files changed

Lines changed: 25392 additions & 1 deletion

.gitignore

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/node_modules
2+
/.pnp
3+
.pnp.js
4+
5+
/coverage
6+
/build
7+
/docker/resumes
8+
9+
backend/challenge_archives/*.zip
10+
11+
.DS_Store
12+
.env
13+
.env.*
14+
/docker/.env
15+
16+
npm-debug.log*
17+
yarn-debug.log*
18+
yarn-error.log*
19+
20+
*.ps1
21+
*.bat

README.md

Lines changed: 41 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,42 @@
1-
# kent-hack-it
1+
# Kent-Hack-It
22
Website repo for the Kent Hack It CTF
3+
4+
## What is this?
5+
The frontend uses ReactJS that communicates to a ExpressJS backend that handles: user login/registration, team creation/joining, and flag submission.
6+
7+
## :computer: Development Installation
8+
### :hammer: Install Dependencies
9+
```bash
10+
# if you do not have NodeJS installed
11+
sudo apt update && sudo apt install nodejs npm
12+
```
13+
14+
### :wrench: Build
15+
```bash
16+
# installs dependencies/packages tracked by this project
17+
npm install .
18+
# compile and run the frontend locally
19+
npm start
20+
```
21+
22+
Move the web related `.env` file into the project root directory, then run the following to run the backend locally.
23+
```bash
24+
nodejs backend/server.mjs
25+
```
26+
27+
## :chart_with_upwards_trend: Production
28+
This project uses Docker :whale: for production set-up
29+
```bash
30+
sudo apt update && sudo apt install docker.io docker-compose
31+
```
32+
The following commands will build the docker via compose which builds the multi-docker system.
33+
You will need to move the `.env` into the project root folder before running the following:
34+
```bash
35+
docker network create traefik
36+
docker-compose --env-file .env -p khi -f docker/docker-compose.yml up --build
37+
```
38+
The following commands will build ONLY the khi website docker image that you later start via `docker run -d ...`.
39+
```bash
40+
docker build -f docker/Dockerfile -t image_name .
41+
docker run -d -p 8080:80 --name docker_name image_name
42+
```
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Place your challenges archives here for players to download them for their associated challenges!
2+
To attach an archive to a challenge, simply write the URL in the challenge description.

0 commit comments

Comments
 (0)