Skip to content

Multi Site Instance Discord Uploading

Yukimi Kazari edited this page Oct 13, 2022 · 10 revisions


If you want to upload to Sequenzia from multiple sites or instances, you would want to setup another Framework + MQ locally on each site.

NOTICE: If you just to run another FileWorker within the same site then you will want to enable external access and use the 'External Database' guide to configure, Then just start the FileWorker on that host.
This guide only applies if you are attempting to upload from completely separate locations/sites/cloud zones.

Enable External Access (Directly)

You will need to start your main server with external access enabled. This will expose the database and MQ ports, You are responsible for applying host firewall rules and or setting up a VPN

Start Sequenzia with External Access:

./sequenzia mode append external
./sequenzia start

Ports:

  • 3306 (MySQL)
  • 5672 (MQ)
  • Optional - 15672, this is the MQ Web Interface that can be used to configure shovels and debug

Enable External Access (LANTIS)

You can use LANTIS to access the database remotely. The above setup does not apply Start Sequenzia with External Access:

./sequenzia mode append router
./sequenzia router keygen-setup
./sequenzia start
LANTIS_ENABLED='false'
  • Copy the common/config/keys/setup.key and common/config/keys/setup.key.pub to your new site servers keys folder
  • Open port 65200 on your main host firewall and or port forward so that your new site can access it.

Configure the Site

  1. Follow the "Prerequisites" and "Download the Compose Scripts" on the new host
  2. Modify the environment file
./sequenzia env
SYSTEM_NAME='SITE-B'
DATABASE_HOST='hostname'
DATABASE_NAME='kanmi_system'
DATABASE_USERNAME='kanmi'
DATABASE_PASSWORD='PAssword'

WAIT_HOSTS='hostname:3306, mq.backend.acr:5672'
  • Replace hostname with the IP, FQDN
    • If your using LANTIS, set to router.backend.acr
  • Add port numbers if they are not the default
  • SYSTEM_NAME should be unique
  1. Modify the user configuration
./sequenzia config
  "DiscordHomeGuild": "991736826568134797",
  "Discord_Upload_Only": true
  • The following MUST be added otherwise the systems will fight with each other!
  • Home guild should match your main instance

Configure LANTIS

./sequenzia router config
CONNECTION_NAME="KanmiBackend"
ENABLED="true"

REMOTE_HOST="MAIN_SITE_IP"
REMOTE_PORT="65200"
REMOTE_USER="root"
REMOTE_SETUP="true"
LOCAL_OPEN="true"

LOCAL_USER="root"
LOCAL_PORT="65200"
REMOTE_LPORT="65301"

#FORWARD_PORTS="80:frontend.acr:80 443:frontend.acr:443"
#FORWARD_PUBLIC="true"
REVERSE_PORTS="3306:sql.backend.acr:3306"
REVERSE_PUBLIC="true"

#CONNECT_REMOTE_COMMANDS=""
#DISCONNECT_REMOTE_COMMANDS=""
#DROPPED_REMOTE_COMMANDS=""
  • Update the REMOTE_HOST and REMOTE_USER to your remote host
  • Leave LOCAL_USER, 'LOCAL_PORT', and LOCAL_LPORT as default
  • REVERSE_PORTS is the port binding to allow your local site to connect to the main servers SQL server
  • REVERSE_PUBLIC allows hosts within the docker environment to connect (NOT your network, you have to expose them to allow that)
  • CONNECT_REMOTE_COMMANDS and DISCONNECT_REMOTE_COMMANDS can be commented out

Start Uploader

Set operator mode and start:

./sequenzia mode uploader
./sequenzia start
  • If your using LANTIS the command will be ./sequenzia mode "uploader router"

Enable Insights

You can enable Insights for other sites running the following commands from #console

juzo SITE-B status enable #dashboard

Screen Shot 2022-10-12 at 01 41 08
You can configure Discord_Insights_Custom_Image_URL in user-config.json to set a custom footer image for this site

Multiple FileWorkers

Other FileWorkers on the same site can be configured by using the main instances SQL server and the new sites MQ. Refer to External FileWorkers for configuration. If you are using LANTIS, you must expose the ports by adding the forwarded ports to the ports list in the docker file