Sunrise is a private server for osu! written in C#. This repository has both endpoints for game-client and for the website. The server is currently in development and is not yet ready for public use.
Note
Want to help? Have a question?  Feel free then to join our Discord server, there you can ask any question to maintainers of this project!
 Feel free then to join our Discord server, there you can ask any question to maintainers of this project!
If you are planning to host your own instance of Sunrise, please follow the official documentation for instructions on how to do so.
They are more in depth and cover various aspects of the setup process in comparison to this README.
- Login and registration system
- Score submission and leaderboards
- Chat implementation
- Chat Bot (as a replacement for Bancho Bot)
- Multiplayer
- !mp commands (mostly)
- Server website (located at Sunset)
- Support for non-standard gamemodes (e.g. Relax, Autopilot, ScoreV2)
- osu!Direct
- Spectating
- Achievements (Medals)
- Rank snapshots
- Automated tests (unit and integration)
- Prometheus metrics with Grafana dashboard
- Rate limiter for both internal and external requests
- Redis caching for faster response times
- Docker support
- Database migrations
- Database backups
Important
The list of features is in priority order. The higher the feature is, the more important it is.
- Clone the repository
- Open the project's folder in any CLI environment.
- Create the file Sunrise.Server/appsettings.Production.jsonand fill it following theSunrise.Server/appsettings.Production.json.exampleexample
- Set up the beatmap manager by following the instructions in
the Observatory repository. After setting up the beatmap manager,
you need to set the General:ObservatoryUrlin theSunrise.Server/appsettings.Production.jsonfile to the address of the beatmap manager.- NB: Make sure that the PORT is defined properly (sunrise checks port 3333 by default) and POSTGRES_PORT value doesn't conflict with other PC ports.
 
- β οΈ Please create- sunrise.pfxfile and move it to- Sunrise/sunrise.pfxfolder, for more instructions follow Local connection βοΈ.
- Start server by running:
docker compose -f docker-compose.yml up -d 
- (Optional) If you want to connect to the server locally, please refer to the Local connection βοΈ section.
- Clone the repository
- Open the project's folder in any CLI environment.
- Set up development environment by running:
docker compose -f docker-compose.dev.yml up -d 
- Set up the beatmap manager by following the instructions in
the Observatory repository. After setting up the beatmap manager,
you need to set the General:ObservatoryUrlin theSunrise.Server/appsettings.{Your Environment}.jsonfile to the address of the beatmap manager.- NB: Make sure that the PORT is defined properly (sunrise checks port 3333 by default) and POSTGRES_PORT value doesn't conflict with other PC ports.
 
- β οΈ Please create- sunrise.pfxfile and move it to- Sunrise/sunrise.pfxfolder, for more instructions follow Local connection βοΈ.
- Run the project
- (Optional) If you want to connect to the server locally, please refer to the Local connection βοΈ section.
- 
Add a launch argument -devserver sunrise.localto your osu! shortcut.
- 
Open the hostsfile located inC:\Windows\System32\drivers\etc\hosts(C:\ is your system drive) with a text editor and add the following line:... (rest of the file) # Sunrise Web Section 127.0.0.1 sunrise.local 127.0.0.1 api.sunrise.local # Sunrise osu! Section 127.0.0.1 osu.sunrise.local 127.0.0.1 a.sunrise.local 127.0.0.1 c.sunrise.local 127.0.0.1 assets.sunrise.local 127.0.0.1 cho.sunrise.local 127.0.0.1 assets.sunrise.local 127.0.0.1 c4.sunrise.local 127.0.0.1 b.sunrise.local 
Warning
Don't forget to save the file after editing.
- 
Generate a self-signed certificate for the domain sunrise.localby running the following commands in the terminal:openssl req -x509 -newkey rsa:4096 -sha256 -days 3650 -nodes -keyout sunrise.local.key -out sunrise.local.crt -subj "/CN=sunrise.local" -addext "subjectAltName=DNS:sunrise.local,DNS:*.sunrise.local,IP:10.0.0.1" 
- 
Convert the certificate to the PKCS12 format (for ASP.Net) by running the following command in the terminal: openssl pkcs12 -export -out sunrise.pfx -inkey sunrise.local.key -in sunrise.local.crt -password pass:password 
- 
Import the certificate to the Trusted Root Certification Authorities store by running the following command in the terminal: certutil -addstore -f "ROOT" sunrise.local.crt
- 
Move the generated sunrise.pfxfile to theSunrisedirectory.
- 
Run the server and navigate to https://api.sunrise.local/docsto check if the server is running.
If you want to contribute to the project, feel free to fork the repository and submit a pull request. We are open to any suggestions and improvements.

