Is it advisable or even possible to install ODK central and ODKX sync endpoint on the same Linux Server
Is it advisable or even possible to install ODK central and ODKX sync endpoint on the same Linux Virtual Machine?
Sync-endpoint software is pretty isloated as a docker stack running in a swarm so you shouldn’t have any issues as long as you can direct the web-requests correctly. Handling and accepting port 80 and port 443 requests and sending it to the proper software would be the issue. However if you use something like nginx or another routing software it should work.
Thank you for the response. With you advise, I will start the journey, trying to follow the two separate guides on setting up ODK central and ODKX sync-endpoint on Ubuntu linux server.
As an FYI … Sync-endpoint’s default setup uses nginx inside the docker swarm to direct the traffic within swarm… it takes the ports 80 and 443 on the machine and sends it to the proper docker container that can handle the request.
I have so far managed to install both ODK central and ODK-X sync endpoint on digital ocean under a single droplet. I also succeeded in creating the users for each. However, I can only access ODK central using the subdomain. After installing nginx and configuring the firewall on ports 80 and 443, I am not able to access ODK-X login. The challenge now is how to use a second subdomain, which I have, to access ODK-X sync.
You can specify the subdomain in the python initialization script and it will automatically get the TLS/SSL certificate installed if you have a DNS properly configured. However, DNS resolves to the IP address of the machine so unless you put something like nginx that routes the requests for you to ODK central or ODK-X’s nginx then you might have a problem. I would reconfigure ODK-X’s nginx to route ODK central’s request seems the easiest to me but up to you how to do it since I am not familiar with ODK central’s configuration.
Dear W_Brunette, I am unable execute what you’ve suggested above. I was only able to amend the docker-compose.yml files residing in odkxsync and odkcentral folders. I discovered that both Odk-X and Odk central take the ports 80 and 443 on the machine, however editing one of the files (for Odk central) in order to enable nginx reverse proxy has failed. Probably I am not doing it right. Do you have any advise on this, or a guide on how to implement the advise in your previous post. On a lighter note, would you mind having a look at the server itself and trouble shoot? I am new to setting up servers of this nature, but once I get this running, working with Odk files will be easier!
First to be clear, the default Docker setup for Sync-Endpoint is in a different repo than the Sync-Endpoint itself.
You will need to combine the docker files to run in one docker setup and have nginx route to proper services. ODK-X does this already with separating the traffic between
Web-UI: GitHub - odk-x/sync-endpoint-web-ui: Sync Endpoint Web UI is the user interface module for the sync-endpoint server
Sync-Endpoint: GitHub - odk-x/sync-endpoint: Sync Endpoint is a server that enables data to replicated between mobile devices. It communicates with your ODK-X Android applications to synchronize your data and application files.
In the default setup, here is how ODK-X separates the traffic:
NOTE: Everything with a “/odktables” goes to the Sync-Endpoint and everything with a “/web-ui” goes to the Web-UI