wiki.rogs.me

my personal wiki

User Tools

Site Tools


Sidebar

cloud

Clouds

First server: Mail (@rogs.me)

Specs

  • DigitalOcean $5 server
  • Ubuntu 18.04 LTS
  • 1GB RAM
  • 1 CPU
  • 25GB SSD

Stack

Mailcow dockerized running clean on the server. You can check the installation instructions here, but it is pretty straightforward.

Second server: Everything else

Specs

  • DigitalOcean $10 server
  • Ubuntu 18.04 LTS
  • 2GB RAM
  • 1 CPU
  • 50GB SSD

Stack

Nextcloud

I'm running a dockerized version of Nextcloud for my cloud solution. On my Nextcloud I manage my files, contacts, calendar and tasks.

Here is the dockerfile:

version: '2'
volumes:
  nextcloud:
  db:
services:
  db:
    image: mariadb
    command: --transaction-isolation=READ-COMMITTED --binlog-format=ROW
    restart: always
    volumes:
      - db:/var/lib/mysql
    environment:
      - MYSQL_ROOT_PASSWORD=my-super-secure-root-password
      - MYSQL_PASSWORD=my-super-secure-password
      - MYSQL_DATABASE=nextcloud
      - MYSQL_USER=nextcloud
  app:
    image: nextcloud
    ports:
      - 8080:80
    links:
      - db
    volumes:
      - nextcloud:/var/www/html
    restart: always

To serve it online, I'm using a reverse proxy trough NGINX for port 8080

Collabora

I'm using Collabora with Nextcloud to host my “Google drive” clone. Installation is pretty easy, just point a subdomain to your server and run the following docker command:

docker run -t -d -p 9980:9980 -e "domain=my-nextcloud-domain.com" --restart always --cap-add MKNOD collabora/code

After it, run a reverse proxy trough NGINX to serve the Collabora image on your subdomain.

In the Nextcloud apps, install Collabora and configure it on the “Settings/Collabora Online section”

To serve it online, I'm using a reverse proxy trough NGINX for port 9980

Dokuwiki

For Dokuwiki I'm also running a docker container. Here is the command:

docker run -d -p 8000:80 --name wiki --restart always \
-v /data/docker/dokuwiki/data:/dokuwiki/data \
-v /data/docker/dokuwiki/conf:/dokuwiki/conf \ 
-v /data/docker/dokuwiki/lib/plugins:/dokuwiki/lib/plugins \
-v /data/docker/dokuwiki/lib/tpl:/dokuwiki/lib/tpl \
-v /data/docker/dokuwiki/logs:/var/log \
mprasil/dokuwiki

I'm running bind mounts for backup purposes. To serve it online, I'm using a reverse proxy trough NGINX for port 8000

Wallabag

Wallabag is my go-to for offline reading. Here is the dockerfile I'm using:

version: '3'
services:
  db:
    image: mariadb
    restart: always
    environment:
      - MYSQL_ROOT_PASSWORD=my-super-secure-root-password
  redis:
    image: redis:alpine
    restart: always
  wallabag:
    image: wallabag/wallabag
    environment:
      - MYSQL_ROOT_PASSWORD=my-super-secure-root-password
      - SYMFONY__ENV__DATABASE_DRIVER=pdo_mysql
      - SYMFONY__ENV__DATABASE_HOST=db
      - SYMFONY__ENV__DATABASE_PORT=3306
      - SYMFONY__ENV__DATABASE_NAME=wallabag
      - SYMFONY__ENV__DATABASE_USER=wallabag
      - SYMFONY__ENV__DATABASE_PASSWORD=my-super-secure-password
      - SYMFONY__ENV__DATABASE_CHARSET=utf8mb4
      - SYMFONY__ENV__MAILER_HOST=my.host.com
      - [email protected]
      - SYMFONY__ENV__MAILER_PASSWORD=my-mail-user-password
      - [email protected]
      - SYMFONY__ENV__DOMAIN_NAME=http://my-wallabag-url
      - SYMFONY__ENV__FOSUSER_CONFIRMATION=false
    ports:
      - 7777:80
    links: 
      - db
    restart: always

To serve it online, I'm using a reverse proxy trough NGINX for port 7777

Ghost

I use Ghost for my blogging platform. Here is the docker-compose file for my installation:

version: '3.1'
services:
  ghost:
    image: ghost:1-alpine
    restart: always
    ports:
      - 7000:2368
    environment:
      database__client: mysql
      database__connection__host: db
      database__connection__user: root
      database__connection__password: my-super-secure-root-password
      database__connection__database: ghost
      url: https://blog.rogs.me
  db:
    image: mysql:5.7
    restart: always
    environment:
      MYSQL_ROOT_PASSWORD: my-super-secure-root-password

To serve it online, I'm using a reverse proxy trough NGINX for port 7000

Matomo

I use Matomo as an open-source replacement for Google Analytics. Here is the docker compose for my installation:

version: "3"
services:
  app:
    image: matomo:3.5-apache
    restart: always
    links:
      - db
    volumes:
      - "./config:/var/www/html/config:rw"
      - "./logs:/var/www/html/logs"
    ports:
      - "9000:80"
  db:
    image: mariadb:latest
    restart: always
    volumes:
      - "./mysql/runtime2:/var/lib/mysql"
    environment:
      - "MYSQL_DATABASE=matomo"
      - "MYSQL_ROOT_PASSWORD=my-super-secure-root-password"
      - "MYSQL_USER=matomo"
      - "MYSQL_PASSWORD=my-super-secure-password"

To serve it online, I'm using a reverse proxy trough NGINX for port 9000

Commento

I use Commento as an open-source replacement for Disquss, used on my blog. Here is the docker compose for my installation:

version: '3'

services:
  server:
    image: registry.gitlab.com/commento/commento
    restart: always
    ports:
      - 5000:8080
    environment:
      COMMENTO_ORIGIN: https://commento.rogs.me
      COMMENTO_PORT: 8080
      COMMENTO_POSTGRES: postgres://postgres:[email protected]:5432/commento?sslmode=disable
    depends_on:
      - db
  db:
    image: postgres
    restart: always
    environment:
      POSTGRES_DB: commento
      POSTGRES_USER: postgres
      POSTGRES_PASSWORD: postgress-pass
    volumes:
      - postgres_data_volume:/var/lib/postgresql/data

volumes:
  postgres_data_volume:

To serve it online, I'm using a reverse proxy trough NGINX for port 5000

Others

SSL Certificates

For SSL Certificates I'm using Let's Encrypt with Certbot.

Firewall

For the firewall, I'm using Uncomplicated_Firewall, which is basically iptables.

Backups / Long term storage

For backups I'm using Wasabi. It is a new bucket service that works like Amazon S3, but it is way cheaper.

cloud.txt · Last modified: 2019/11/25 02:10 by roger