Skip to content

A Polyphony chat server, compatible with Spacebar and the Discord API.

License

Notifications You must be signed in to change notification settings

polyphony-chat/symfonia

Folders and files

NameName
Last commit message
Last commit date

Latest commit

author
bitfl0wer
Jan 23, 2025
644caa2 · Jan 23, 2025
Jan 5, 2025
Oct 13, 2024
Oct 14, 2024
Sep 25, 2024
Oct 22, 2024
Oct 23, 2024
Jun 4, 2024
Jan 23, 2025
Jul 21, 2024
Jan 15, 2025
Sep 29, 2024
Jan 15, 2025
Aug 26, 2024
Jul 26, 2024
Oct 19, 2024
Oct 14, 2024
Jul 27, 2024
Aug 20, 2024
Jan 5, 2025
Jan 6, 2025
Oct 11, 2024
Sep 29, 2024

Repository files navigation

Discord

The Symfonia logo. a dark, square background with rounded edges. on this background, there are four vertically stacked, purple lines. The lines are all vaguely u-shaped and resemble sound waves being emitted into one direction, with the lower lines being thicker and wider than the upper lines.

Symfonia

About

This is a WIP implementation of a Spacebar compatible Server in Rust!

This repository contains: A partial implementation of:

Local Development Environment

Whether you are using Docker or not, you will need to have the following installed:

If your development environment is hosted on a Windows machine, please additionally make sure that you have a bash shell available to execute pre-commit hooks. This can be done by installing Git Bash or Windows Subsystem for Linux 2 and, additionally, configuring your IDE correctly.

See the instructions below for guidance on how to run the project.

Non-Docker

  1. Install and host a PostgreSQL database
  2. Create a new database, and a user that has full access to that database
  3. Create a .env file in the root of the project with the following contents:
DATABASE_HOST=[ip/domain of your Postgres database]
DATABASE_PORT=[Postgres port, usually 5432]
DATABASE_USERNAME=[Your Postgres username]
DATABASE_PASSWORD=[Your Postgres password]
DATABASE_NAME=[Your Postgres database name]
API_BIND=[ip:port to bind the HTTP API server to. Defaults to 0.0.0.0:3001 if not set]
GATEWAY_BIND=[ip:port to bind the Gateway server to. Defaults to 0.0.0.0:3003 if not set]
  1. Install the sqlx CLI with cargo install sqlx-cli
  2. Run cargo sqlx migrate run from within the project directory to run the migrations
  3. Run the project with cargo run.

Docker

  1. Copy the compose-example.env file to .env in the root of the project and fill in the values to your liking.
  2. Adjust ports in docker-compose.yml if needed.
  3. Run docker compose up --build.

Code changes will require you to restart the container with docker compose up --build. If you want to reset to a fully clean state, run docker compose down -v.