Official React-based website for Penn Labs' club directory and events listings. The REST API written in Django for Penn Clubs infrastructure.
You will need to start both the backend and the frontend to do Penn Clubs development.
Questions? Check out our extended guide for FAQs for both Mac and Windows.
Running the backend requires Python 3.
In production, you will need to set the following environment variables:
NEXT_PUBLIC_SITE_NAME(optional, defaults to
To run the server,
cd to the folder where you cloned
penn-clubs. Then run:
psycopg2 (this is necessary if you want to be able to modify
dependencies, you can revisit later if not)
$ brew install postgresql
$ brew install openssl
$ brew unlink openssl && brew link openssl --force
$ echo 'export PATH="/usr/local/opt/openssl@3/bin:$PATH"' >> ~/.zshrc
$ export LDFLAGS="-L/usr/local/opt/openssl@3/lib"
$ export CPPFLAGS="-I/usr/local/opt/openssl@3/include"
$ apt-get install gcc python3-dev libpq-dev
Now, you can run
$ pipenv installto install Python dependencies. This may take a few minutes. Optionally include the
--devargument if you are installing locally for development. If you skipped installing
psycopg2earlier, you might see an error with locking -- this is expected!
$ pipenv shell
$ pre-commit install
$ ./manage.py migrateOR
$ python3 manage.py migrate
$ ./manage.py populateOR
$ python3 manage.py populate(in development, to populate the database with dummy data)
$ ./manage.py runserverOR
$ python3 manage.py runserver
You will need to set the following environment variables on the frontend:
clubsto show Penn Clubs and
fyhto show Hub@Penn.
- Enter the
frontenddirectory with a new terminal window. Don't kill your backend server!
- Install dependencies using
yarn installin the project directory.
- Run application using
- Access application at http://localhost:3000.
Login to log in as a test user. The
./manage.py populate command creates a test user for you with username
bfranklin and password
test. Go to
/api/admin to login to this account.