[Unit] Description=mastodon-sidekiq After=network.target PartOf={{service}}.target [Service] Type=simple User={{service}} Group={{service}} UMask=0027 WorkingDirectory=/home/{{service}}/mastodon/ Environment="RAILS_ENV=production" Environment="RAILS_LOG_LEVEL=error" Environment="DB_POOL=25" Environment="MALLOC_ARENA_MAX=2" Environment="LD_PRELOAD=libjemalloc.so" ExecStart=/home/{{service}}/.rbenv/shims/bundle exec sidekiq -c 25 TimeoutSec=15 Restart=always SyslogIdentifier=%p [Install] WantedBy={{service}}.target