Skip to content

Sparkiy Talk (Discourse)

Aleksandar Toplek edited this page May 23, 2015 · 1 revision

Setup guide

We are using Microsoft Azure as Cloud infrastructure provider.

Create new VM instance of Docker on Ubuntu Server

Create 2GB swap file

sudo install -o root -g root -m 0600 /dev/null /swapfile
sudo dd if=/dev/zero of=/swapfile bs=1k count=2048k
sudo mkswap /swapfile
sudo swapon /swapfile
echo "/swapfile       swap    swap    auto      0       0" | sudo tee -a /etc/fstab
sudo sysctl -w vm.swappiness=10
echo vm.swappiness = 10 | sudo tee -a /etc/sysctl.conf

Enable firewall

sudo ufw allow http
sudo ufw allow https
sudo ufw allow ssh
sudo ufw enable

Get Discourse

sudo mkdir /var/discourse
sudo git clone https://github.com/discourse/discourse_docker.git /var/discourse
cd /var/discourse
sudo cp samples/standalone.yml containers/app.yml

Edit app.yml file sudo nano containers/app.yml

  • DISCOURSE_DEVELOPER_EMAILS to [email protected],[email protected]
  • DISCOURSE_HOSTNAME to talk.sparkiy.com
  • DISCOURSE_SMTP_ADDRESS to smtp.mandrillapp.com
  • DISCOURSE_SMTP_PORT to 587
  • DISCOURSE_SMTP_USER_NAME to [email protected]
  • DISCOURSE_SMTP_PASSWORD to API key from Mandrill app

Install discourse and start

sudo ./launcher bootstrap app
sudo ./launcher start app

Source Article

Update guide

Reboot the machine if required (wait ~30s after shutdown)

sudo shutdown -r now

Rebuild Discourse

cd /var/discourse
sudo ./launcher rebuild app   
Clone this wiki locally