The website for Birdflop, a 501(c)(3) nonprofit aiming to provide accessible hosting and resources.
To contribute to the Birdflop website, you'll need to set up a local development environment.
- Node.js (version 23 or higher)
- pnpm package manager
- Clone the Repository: Fork the Birdflop website repository on GitHub https://github.com/birdflop/web and clone it
- Install Dependencies: Navigate to the project directory and run
pnpm installto install all necessary dependencies. - Build the Project: Run
pnpm buildto build the project. This is only necessary the first time you set up the project to setup the RGBirdflop package and Cloudflare worker types to avoid type errors. - Run the Development Server: Start the development server with
pnpm start. The website should now be accessible athttp://localhost:5173.
The Birdflop website uses Cloudflare D1 for its database, setting up a local database may be required for contributing to the Presets and other systems that require database setup, otherwise Flopbird will give you an error while opening some pages. To set up a local database:
- Migrate the Database: Run
pnpm wrangler:migrate-localto set up the local database schema on your machine. - Run the server: Start the development server with
pnpm start.
For login with Discord to work, you will need to set up a Discord application from the dev portal and set up environment variables. Create a .env file in the root of the project and add the following variables:
AUTH_SECRET=this_can_be_any_random_string
AUTH_DISCORD_ID=the_client_id_from_your_discord_application
AUTH_DISCORD_SECRET=the_client_secret_from_your_discord_application
ADMINS=your_user_id_in_profile_page_after_you_login
