This repository has been archived by the owner on May 28, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 54
Selfhosting
MotorTruck1221 edited this page Mar 8, 2023
·
3 revisions
- Clone the repository
$ git clone https://github.com/ruby-network/ruby.git
- Install the dependencies
$ yarn
- make a copy of the
.env.example
file and rename it to.env
$ cp .env.example .env
- Edit the
.env
file and change theURL
to the url you want to use (leave blank to disable) - Edit the
.env
file and change thePORT
to the port you want to use (leave blank to use 8080) - If you just want to use the default settings you can skip this step
- Start the server
$ yarn prod
- Open your browser and go to
localhost:8080
- Install docker and docker-compose (if you don't have it already)
- Copy the docker compose example below and paste it into a file called
docker-compose.yml
version: '2'
services:
ruby:
restart: unless-stopped
image: 'ghcr.io/ruby-network/ruby:main'
ports:
- 8080:8080
#ADVANCED ITEMS BELOW
#env_file:
# - .env.docker
#environment:
# - URL=${URL}
#networks:
# default:
# external:
# name: default_net
- You can also just simply curl the docker-compose.yml file from github
$ curl https://raw.githubusercontent.com/Ruby-Network/ruby/main/docker/docker-compose.yml > docker-compose.yml
- Change
<your port here>
to the port you want to use removing the<>
around it. - Run the docker-compose file
$ docker-compose up -d
- Run the following command
$ docker run -d -p <your port here>:8080 --restart unless-stopped --name ruby ghcr.io/ruby-network/ruby
- Change
<your port here>
to the port you want to use removing the<>
around it.
- Make a .env.docker file and paste the following into it
PORT=8080
URL=http://localhost:8080
- Change the
PORT
to the port you want to use - Change the
URL
to the url you want to use (leave blank or delete to disable) - Change your docker-compose.yml file to look like this
version: '2'
services:
ruby:
restart: unless-stopped
image: 'ghcr.io/ruby-network/ruby:main'
ports:
# - <your port here>:8080
#ADVANCED ITEMS BELOW
- ${PORT}:8080
env_file:
- .env.docker
environment:
- URL=${URL}
#networks:
# default:
# external:
# name: default_net
- Run the docker-compose file
$ docker-compose up -d
Need to use a custom network? Uncomment the networks section and change the name to the name of your network
- These are not included by default due to the size. To add them simply run the following command
$ git submodule update --init --recursive
- If you want to update the games to the latest version run the following command
$ git submodule update --recursive --remote
- If you want to remove the games run the following command
$ git submodule deinit -f .
For more support join Our Discord!