Aggregate behind nGinx

Hi,

I've installed the latest version of Aggregate v2.0.5 successfully on a new server using docker-compose. After doing that configured nGinx as a front for SSL + proxying Aggregate.

  • Initial install done
  • Aggregate loads on tomcat without issue
  • Postgresql shows the new DB
  • Can load the https://servername/aggregate successfully
  • Did an Administrator login and password change.
  • Added a new user for "data collector", and it worked
  • In ODK Collect v1.28.2 successfully used the newly created user/pass using the above URL
  • "Get Blank Forms" shows the list of forms

But when I click on "Get Selected", the file doesn't download.

Keeping everything else same, when I use http://servername:8080/aggregate (directly accessing tomcat), then this also works without problems. While this solves the problem, ideally we would prefer to have tomcat running behind nGinx.

The logs on Aggregate doesn't show any problems.

Can someone please advise where this could be going wrong?

Hi @cartes,

we run aggregate behind jwilder/nginx-proxy container and its letsencrypt-nginx-proxy-companion, it just need to define env. vars on aggregate container :
--env "VIRTUAL_HOST=odk.yourdomain.tld"
--env "VIRTUAL_PORT=8080"
--env "LETSENCRYPT_HOST=odk.yourdomain.tld"
--env "LETSENCRYPT_EMAIL=mail@yourdomain.tld" \

Then we can reach and use https://odk.yourdomain.tld/aggregate

But in fact it is much a workaround than a solution to you problem, as both nginx and letsencypt container manage the conf, so i do not know how to configure it by hand :frowning:

1 Like

Thanks @mathieubossaert for your comment. The letsencrypt-nginx-proxy-companion looks like a very handy product to have in hand.

I think you could be right that the SSL is probably interfering with the desired solution. Will run some test and see. Thanks again!