Skip to content

this is the public version of the 42 project ft_transcendence.

Notifications You must be signed in to change notification settings

sixie17/ft_transcendence_public

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ft_transcendence_public

I have added a base .env at your disposal, you just have to get your API credentials for Cloudinary and intra for the intra API click on your login then settings, and on your left click on API and then register new APP, after that, fill in any name however in the Redirect URI field, you need two links split by a newline, http://hostname:3000/twoFactorAuth and http://hostname:3001/auth/signin, in case you decided to test the app on the same machine, hostname is localhost and make sure it is localhost in /frontend/.env.local also, otherwise it will be the IP of the machine and dont forget to update /frontend/.env.local accordingly, example

APP_NAME="FREEEEEEE BIIIIIIIRD"
DATABASE_URL="postgresql://postgres:123@db:5432/mydb?schema=public"
JWT_SECRET="EEEEEEEEEEEEEEE"
FT_CALLBACK2="http://10.13.37.42:3000/twoFactorAuth" #unchanged
FT_CALLBACK="http://10.13.37.42:3001/auth/signin" #unchanged
CLOUDINARY_NAME=""
CLOUDINARY_KEY=""
CLOUDINARY_SECRET=""
FT_UID=""
FT_SECRET=""
POSTGRES_USER=postgres
PGUSER=postgres
POSTGRES_PASSWORD=123
POSTGRES_DB="mydb"
PG_HOST="db"
HOSTNAME="localhost"

NOTE the hostname in the intra's redirect URI should be exactly the same in the FT_CALLBACK and FT_CALLBACK2, and dont forget /frontend/.env.local.

after this set up you should be good to go just run the following command and wait for the app to run docker compose up --build

things to note during testing

  • a user can not match with themselves
  • a user can not chat with themselseves
  • a user is required to have a nickname otherwise they won't have access to any website's ressouerces and they will be invisible to other users
  • if a user lost their 2FA OTP there is no way to retrieve it
  • of course you need at least 2 intra accounts to actually test all the features
  • the owner of a channel is of course a higher grade, they can assign new admins, downgrade them kick users , change channel's permissions,etc...
  • Have fun (this website was hosted locally at 1337 for 4 hours while at least 100 users were playing and all the data was updated in realtime except the leaderboard)

About

this is the public version of the 42 project ft_transcendence.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published