====================================================== How to configure multiple resellers on the same server ====================================================== .. warning:: This documentation page is marked as obsolete works only with the OS package deployment (retired as of 2021.06.1 release). In order to have multiple resellers on the same server you need to copy the default Fleio frontend and change the nginx configuration. We will setup an additional reseller frontend for RESELLERX. with the following URL structure: .. code-block:: bash Cloud Admin: {{ your domain }}/staff All reseller url: {{ your domain }}/reseller RESELLERX: Reseller login: {{ your domain }}/resellerX Enduser-reseller1 login: {{ your domain }}/enduserresellerX Enduser-reseller1 sign up: {{ your domain }}/enduserresellerX/signup You can replace resellerx or enduserrresellerx with the desired pages. Nginx configuration ------------------- You will need to add two new nginx vhosts for each reseller. One is the vhost for /resellerx and one for /enduserresellerX .. code-block:: bash server { … location / { alias /var/webapps/fleio/frontend/site/; expires -1; try_files $uri $uri/ /index.html; } # resellerX locations location /resellerX { alias /var/webapps/fleio/frontend/resellerX/reseller/; expires -1; try_files $uri $uri/ /../resellerX/reseller/index.html; } location /enduserresellerX { alias /var/webapps/fleio/frontend/resellerX/site/; expires -1; try_files $uri $uri/ /index.html; } } After you edit the nginx configuration you can validate it by running: .. code-block:: bash nginx -t If the configuration is valid you can restart nginx using ``service nginx restart``. Reseller / end user panel ------------------------- First you will need to duplicate the existing panels. In order to do that, you need to run the following commands: .. code-block:: bash cd /var/webapps/fleio/frontend mkdir /var/webapps/fleio/frontend/resellerX cp -R /var/webapps/fleio/frontend/reseller /var/webapps/fleio/frontend/resellerX/ cp -R /var/webapps/fleio/frontend/site /var/webapps/fleio/frontend/resellerX/ rm -rf /var/webapps/fleio/frontend/resellerX/site/staff chown -R fleio:fleio /var/webapps/fleio/frontend/resellerX Now we need to apply some changes to the following files: * ``/var/webapps/fleio/frontend/resellerX/site/index.html`` Change the base href from: .. code-block:: bash to * ``/var/webapps/fleio/frontend/resellerX/reseller/index.html`` Change the base href from: .. code-block:: bash to The last step is to set the reseller's client ID in the reseller's front end constants.js file. See :doc:`/reseller/automatically_assign_users_to_reseller` .. warning:: After each Fleio update you need to re-do the reseller / end-user duplication. This may be changed in the future.