403 forbidden after installation

Hello!

I’m a newbie in this kind of installation and I saw this forum “Discourse” like a month ago and today I tried to install it on my website but something went wrong… ^^’

I use Debian so I followed this Discourse on Debian Wheezy via Docker – Jan-Philip Gehrcke, PhD tutorial for my installation.

I have my /var/discourse/shared/standalone file, but on my website, it doesn’t work… On my FTP, my file forum.gameguides.fr is empty ='(

On Putty I have this :

[193] 31 Mar 14:36:33.763 * Saving the final RDB snapshot before exiting.
2015-03-31 14:36:33 UTC [74-2] LOG: database system is shut down
[193] 31 Mar 14:36:33.800 * DB saved on disk
[193] 31 Mar 14:36:33.802 # Redis is now ready to exit, bye bye…
cf42aa40d0ef575fb3310414cc068ee85e4af0d69377ad0e9e6021ea7f5c3277
73b294b37be7316f11789214c6cc2469d0692feb8b351ea29da2d3088e75dca4
Removing old container

  • /usr/bin/docker rm app
    app
  • /usr/bin/docker run -d --restart=always -e LANG=en_US.UTF-8 -e RAILS_ENV=production -e UNICORN_WORKERS=2 -e UNICORN_SIDEKIQS=1 -e RUBY_GC_MALLOC_LIMIT=40000000 -e RUBY_HEAP_MIN_SLOTS=800000 -e DISCOURSE_DB_SOCKET=/var/run/postgresql -e DISCOURSE_DB_HOST= -e DISCOURSE_DB_PORT= -e HOME=/root -e DISCOURSE_DEVELOPER_EMAILS=contact.aion@. -e DISCOURSE_HOSTNAME=forum.gameguides.fr -e DISCOURSE_SMTP_ADDRESS=smtp.. -e DISCOURSE_SMTP_PORT=587 -e DISCOURSE_SMTP_USER_NAME=contact.aion@. -e DISCOURSE_SMTP_PASSWORD=*** -h Gameguides.fr-app -e DOCKER_HOST_IP=172.17.42.1 --name app -t -p 127.0.0.1:20080:80 -p 2222:22 -v /var/discourse/shared/standalone:/shared -v /var/discourse/shared/standalone/log/var-log:/var/log local_discourse/app /sbin/boot
    0ff0e1fb83e97e63463e569a3a514542dc1320f30d3a721bf9da9d57745e5b68

If someone can help me it will be awsome ^^’

Greetings,
Elano.

That “Forbidden” page is served up by an Apache webserver.

Only one application at a time can listen on any given socket. The first server that starts will claim the HTTP socket for itself, preventing the other server from accepting any connections. You can run Discourse alongside Apache, but it requires a specific setup:

  • Apache needs to run with mpm_event, mod_proxy, mod_proxy_http and probably mod_proxy_balancer.
  • You must modify Discourse’s configuration: disable SSL support and expose "127.0.0.1:4000:80".
  • Change your Apache config to proxy requests for forum.gameguides.fr to Discourse at localhost:4000.

You can find further info and examples here on meta. Some Apache config samples are here and here.

3 Likes

Or, if @Elano would prefer nginx to be the front proxy, there are complete instructions here:

No modules/plugins are required, and your Discourse install will not be exposed on a side port.

You say that as if nginx’s proxy code wasn’t wrapped into modules as well… the only difference is that most distros have decided to build nginx with all modules enabled and Apache with most modules built as external libs. :slight_smile:

Oh, and Apache can proxy to unix sockets as of version 2.4.7, too. :smiley:

Hi ^^

Thanks for your answers =) I think I’ll try the Apache version ^^

Greetings,
Elano.