## page was renamed from diaspora #language en ~-[[DebianWiki/EditorGuide#translation|Translation(s)]]: none-~ ---- ||<>|| We have two options to install diaspora in debian. First is to use `diaspora-installer` package from contrib section and second is to use `diaspora` package from main. Both will create necessary database initialization and configuration using {{{postgresql}}} or optionally {{{mysql}}}. Both options provide systemd services and init scripts to manage the services. More details are available in [[https://salsa.debian.org/ruby-team/diaspora-installer/-/blob/master/README|package's README]]. {{{ # systemctl status diaspora # systemctl status diaspora-sidekiq # systemctl status diaspora-unicorn }}} If you are using sysvinit, {{{ # /etc/init.d/diaspora status }}} = Using diaspora package in main = {{{#!wiki warning This is very early version of the `diaspora` package and not recommended for production yet. See [[Diaspora#Using_diaspora-installer_package_in_contrib]] for installing diaspora in production. }}} == Bullseye Backports/personal repo == See https://people.debian.org/~praveen/diaspora-bullseye/README for instructions to use this repository. Note: Once bullseye is released, we hope to get diaspora in official bullseye-backports. == Buster Fasttrack/personal repo == Add the following repo {{{ deb http://deb.debian.org/debian buster main deb http://security.debian.org/ buster/updates main deb http://deb.debian.org/debian buster-backports main deb https://people.debian.org/~praveen/diaspora-buster buster-backports main deb https://people.debian.org/~praveen/diaspora-buster buster-fasttrack main }}} Add repo signing key as trusted key {{{ # wget https://people.debian.org/~praveen/diaspora-buster/praveen.key.new.asc # apt-key add praveen.key.new.asc }}} {{{ apt -t buster-backports install diaspora diaspora-common/buster-fasttrack ruby-redis/buster ruby-active-model-serializers/buster-backports apt-mark hold ruby-active-model-serializers }}} == Unstable == `diaspora` package is available in debian unstable, but it is broken (diaspora needs rails 5 and unstable has rails 6). {{{ # apt-get install diaspora }}} == Experimental == `diaspora` is available for experimental. {{{ # sudo apt install diaspora/experimental diaspora-common/experimental \ unicorn/experimental ruby-unicorn-worker-killer/experimental \ ruby-devise-two-factor/experimental ruby-sidekiq/experimental \ ruby-uglifier/experimental ruby-toml-rb/experimental \ ruby-autoprefixer-rails/experimental ruby-nokogiri/experimental \ ruby-hamlit/experimental ruby-zip/experimental ruby-rotp/experimental \ libjs-autosize/experimental }}} = Using diaspora-installer package in contrib = This will install gems via rubygems.org (hence it is in contrib). This is production ready and powers pods like poddery.com and diasp.in == Buster Backports (Recommended) == Buster Backports has diaspora 0.7.14. {{{ # apt-get -t buster-backports install diaspora-installer }}} == Buster (upgrade to Buster Backports) == Buster has diaspora version 0.7.6.0. It is recommended to update to the version in Buster Backports. {{{ # apt-get install diaspora-installer }}} == Sid/Unstable == If you have contrib section in your sources list, you can just run {{{ # apt-get install diaspora-installer[-mysql] }}} The source code of diaspora-installer package could be found [[https://sources.debian.net/src/diaspora-installer/unstable/|here]]. = Maintainers corner = Documentation for diaspora package maintainers. == TODO == 1. Add autopkgtest (see gitlab for how to do it) * [[https://git.fosscommunity.in/debian-ruby/TaskTracker/issues?label_name%5B%5D=diaspora|Team's task tracker]] == Policy for dependency updates == Help keep the gem versions in sync. If deb version of a library is older than required by diaspora (run 'bundle install --local' on a develop branch checkout of [[https://github.com/diaspora/diaspora|diaspora upstream]]), [[https://wiki.debian.org/Teams/Ruby/Packaging#Updating_a_package_to_a_newer_version|update the deb version]]. If debian already has a new version of a library, [[https://github.com/diaspora/diaspora/issues/3855|update the corresponding gem version in diaspora]]. 1. tiny version change, patch gemfile 2. minor version change, test compatibility 3. major version change, test compatibility and embed gem if needed Coordinate with upstream for major version updates. You can find the packaging work at {{{http://anonscm.debian.org/cgit/pkg-ruby-extras/diaspora.git}}} See below for the team effort to package the dependencies of Diaspora and Diaspora itself for Debian. == Diaspora packaging and testing == * [[/packaging|packaging]] * [[/testing|testing]] == Manually starting the service == We are still working on integrating systemd unit files with the package (See [[DebianBug:887085]]) so we have to start the service manually for now. {{{ # cd /usr/share/diaspora # export GEM_HOME=/var/lib/diaspora/.gem/ # export $(cat /etc/diaspora/diaspora.conf | xargs) # sudo -u diaspora -E -H bundle exec sidekiq & # sudo -u diaspora -E -H bundle exec unicorn -c config/unicorn.rb & }}} To stop the services, {{{ # fg Press Control + C (stops unicorn) # fg Press Control + C (stops sidekiq) }}} == Replacing a packaged gem with rubygems.org gem == Sometimes we have to use gems from rubygems.org as a work around when packaged versions have bugs or are incompatible. Setup environment variables (see `Manually starting the service` section above). Stop unicorn service. Taking activestorage as an example. {{{ # dpkg -r --force-all ruby-activestorage # unset GEM_HOME; gem install -v 5.2.3 activestorage # truncate -s0 Gemfile.lock # export GEM_HOME=/var/lib/diaspora/.gem/ # export $(cat /etc/diaspora/diaspora.conf | xargs) # sudo -u diaspora -E -H bundle install --local # sudo -u diaspora -E -H bundle exec rake tmp:cache:clear # sudo -u diaspora -E -H bundle exec rake assets:precompile }}} Start unicorn again. Note: when using gem install GEM_HOME should not be set, but when running bundle install --local, GEM_HOME should be set. == Enabling Chat == * [[Diaspora/XMPP|prosody setup]]