We can test diaspora installation using an lxc container. Use unstable for testing latest versions.

# lxc-create -n diaspora -t debian -- -r unstable

If you want to test on buster use,

# lxc-create -n diaspora -t debian -- -r buster

Now start and attach to the container,

# lxc-start -n diaspora
# lxc-attach -n diaspora

See LXC for more details on managing a container.

Inside the container

You will need a utf-8 locale to install postgresql. Run dpkg-reconfigure locales and choose a locale with utf-8 support (for example en_IN.UTF-8). Reboot the container (reboot command) and run lxc-attach again.

  1. Enable contrib section in /etc/apt/sources.list. apt update && apt install diaspora-installer. For buster, use deb https://people.debian.org/~praveen/diaspora-buster buster main contrib in your sources.list till the bug fixes are available from official archives.

  2. During installation, choose diaspora.lxc as the hostname

  3. Disable https in debconf wizard
  4. Verify the diaspora service is running /etc/init.d/diaspora status and start if not running /etc/init.d/diaspora start

  5. Run the following command to verify the diaspora service is running curl -v --unix-socket /run/diaspora/diaspora.sock http://diaspora.lxc/

If diaspora is running, /etc/init.d/diaspora status output will be similar to

● diaspora.service - LSB: Diaspora application server
   Loaded: loaded (/etc/init.d/diaspora; generated)
   Active: active (running) since Tue 2020-09-08 17:35:33 UTC; 1h 3min ago
     Docs: man:systemd-sysv-generator(8)
  Process: 169 ExecStart=/etc/init.d/diaspora start (code=exited, status=0/SUCCESS)
    Tasks: 23 (limit: 4915)
   Memory: 369.8M
   CGroup: /system.slice/diaspora.service
           ├─ 191 sudo -u diaspora -E -H ./script/server
           ├─ 423 eye monitoring v0.10.0 [diaspora] (in /var/lib/diaspora)
           ├─9263 unicorn master -c config/unicorn.rb -D
           ├─9267 ruby2.5 /usr/share/diaspora/vendor/bundle/ruby/2.5.0/bin/sidekiq
           ├─9272 unicorn worker[0] -c config/unicorn.rb -D
           └─9275 unicorn worker[1] -c config/unicorn.rb -D

Sep 08 17:35:33 diaspora-stretch systemd[1]: Starting LSB: Diaspora application server...
Sep 08 17:35:33 diaspora-stretch diaspora[169]: Starting diaspora server....
Sep 08 17:35:33 diaspora-stretch systemd[1]: Started LSB: Diaspora application server.
Sep 08 17:35:33 diaspora-stretch sudo[191]:     root : TTY=unknown ; PWD=/usr/share/diaspora ; USER=diaspora ; COMMAND=./script/server
Sep 08 17:35:33 diaspora-stretch sudo[191]: pam_unix(sudo:session): session opened for user diaspora by (uid=0)

Troubleshooting

Logs are found in /var/log/diaspora. Check startscript.log and eye_processes_stderr.log if diaspora service is not running or curl cannot access the service for any errors.

If you are getting the default nginx page, then restart nginx service with systemctl restart nginx command.

Manually starting unicorn

root@diaspora-buster:~# cd /usr/share/diaspora
root@diaspora-buster:/usr/share/diaspora# . /etc/diaspora.conf 
root@diaspora-buster:/usr/share/diaspora# sudo -u diaspora -E -H  bin/bundle exec unicorn -c config/unicorn.rb

On your host machine

  1. Add ip address of container (ip a will list the ip address) in host machine's /etc/hosts to resolve diaspora.lxc. 192.168.122.104 diaspora.lxc # Change ip address

  2. Visit http://diaspora.lxc on host browser