Mastodon is a free, open-source social network server.
A decentralized solution to commercial platforms, it avoids the risks of a single company monopolizing your communication. Anyone can run Mastodon and participate in the social network seamlessly.
An alternative implementation of the GNU social project. Based on ActivityStreams, Webfinger, PubsubHubbub and Salmon.
This repo shows how to run a Mastodon instance on Barge with Vagrant instantly.
Note: You may find LOCAL_HTTPS=false
in .env.provision
here, therefor, it's just for a local test and don't use this setting in the public.
$ vagrant up
Or you can do the same procedure one by one as below.
$ vagrant up --no-provision
$ vagrant provision --provision-with build
$ vagrant provision --provision-with config
$ vagrant provision --provision-with setup
$ vagrant provision --provision-with mastodon
Cf.) https://github.com/tootsuite/mastodon/tree/v1.2#running-with-docker-and-docker-compose
http://localhost:3000/
You will receive a confirmation email to activate your account and click a link in the email.
http://localhost:1080/
Or you can authorize yourself manually from your local console as below, just in case of missing the email or whatever.
$ vagrant ssh
[bargee@barge ~]$ cd /opt/mastodon
[bargee@barge mastodon]$ docker-compose run --rm web rails mastodon:confirm_email USER_EMAIL=<your email address>
[bargee@barge mastodon]$ docker-compose run --rm web rails mastodon:make_admin USERNAME=<your username>
Now you can access to the admin page.
http://localhost:3000/admin/settings
$ vagrant ssh
[bargee@barge ~]$ cd /opt/mastodon
[bargee@barge mastodon]$ docker-compose down
[bargee@barge mastodon]$ cd ..
[bargee@barge opt]$ sudo mv mastodon mastodon.bak
$ git fetch
$ git checkout <new version>
$ vagrant provision --provision-with build
[bargee@barge ~]$ cd /opt/mastodon
[bargee@barge mastodon]$ sudo cp -pR ../mastodon.bak/public .
[bargee@barge mastodon]$ sudo cp /vagrant/.env.production .
And then you have to copy the secrets from /opt/mastodon.bak/.env.production
.
Follow an upgrade instruction in the release notes. https://github.com/tootsuite/mastodon/releases
$ vagrant provision --provision-with mastodon