Package Details: mastodon 4.5.6-1

Git Clone URL: https://aur.archlinux.org/mastodon.git (read-only, click to copy)
Package Base: mastodon
Description: Your self-hosted, globally interconnected microblogging community
Upstream URL: https://github.com/mastodon/mastodon
Keywords: activitypub fediverse mastodon server
Licenses: AGPL3
Submitter: flacks
Maintainer: bolleyboll
Last Packager: Vamp898
Votes: 27
Popularity: 1.01
First Submitted: 2018-06-19 19:35 (UTC)
Last Updated: 2026-02-05 15:45 (UTC)

Latest Comments

1 2 3 4 5 6 .. 12 Next › Last »

zoltix commented on 2026-04-12 11:09 (UTC) (edited on 2026-04-12 11:09 (UTC) by zoltix)

I updated to 4.5.8 and tested on my instance

# Maintainer: Vamp898 <vamp898-aur@ikaros.space>
pkgname=mastodon
pkgver=4.5.8
pkgrel=1
pkgdesc='Your self-hosted, globally interconnected microblogging community'
arch=(any)
url=https://github.com/mastodon/mastodon
license=(AGPL3)
depends=(corepack
     ffmpeg
         git
         libidn
         libpqxx
         libvips
         libxml2
         libxslt
         libyaml
         nodejs
         postgresql
         protobuf
         ruby-bundler
         sudo
         valkey
         zlib
         yarn-berry)
backup=(etc/mastodon.conf)
install=mastodon.install
options=(!strip)
source=(https://github.com/mastodon/mastodon/archive/v$pkgver.tar.gz
        mastodon.target
        mastodon.sysusers.d
        mastodon.tmpfiles.d
        devise_pam.patch)
sha256sums=('8d6df5fff6b320bff8e7e4cc4eabb1e621ed833ae51625b5c81101e1e291e45d'
            'e9928ced31f6490476100f02f2e158e41a076988dd7f3dff8f21d245bc2bb0ff'
            '1b67693f7de5802a34985b9ac969497fc6e6042dcae0b8abf6595b9fe15ee80e'
            '3fdd54dd1f374b7206c8beaebafdf890e74d30385f0c93f9cd99e1e4be92f8fa'
            '8415cded8d5f159623439b8ab0a87c1ac653a32f6945eebc9140195289c1ece6')
prepare() {
    cd mastodon-$pkgver
    patch -p1 < ../devise_pam.patch
}

build() {
    export COREPACK_ENABLE_DOWNLOAD_PROMPT=0
    cd mastodon-$pkgver
    sed -i '/husky install/d' package.json # Stop husky from hijacking git hooks
    bundle config set deployment true
    bundle config without 'development test'
    bundle config with 'pam_authentication'
    # Disable LTO which breaks the C extension of the google-protobuf gem https://github.com/protocolbuffers/protobuf/issues/11935
    bundle config --local build.google-protobuf "-- --with-cflags='$(ruby -r rbconfig -e 'print RbConfig::CONFIG["CFLAGS"]' | sed -e 's/-Werror=format-security//' -e 's/-flto=auto/-fno-lto/')' --with-ldflags='$(ruby -r rbconfig -e 'print RbConfig::CONFIG["LDFLAGS"]' | sed -e 's/-flto=auto/-fno-lto/')'"
    bundle config set frozen false
    bundle add erb
    BUNDLE_BUILD__CHARLOCK_HOLMES="--with-cxxflags=-std=c++17" bundle install -j$(getconf _NPROCESSORS_ONLN)
    corepack enable --install-directory . yarn
    ./yarn install --immutable
    # https://aur.archlinux.org/packages/mastodon?O=0#comment-986425
    cd vendor/bundle/ruby/*/gems/ox-*/ext/ox
    make
    cp ox.so ../../lib
}

package() {
    install -d "$pkgdir"/{var/lib,etc}
    cp -a mastodon-$pkgver "$pkgdir"/var/lib/mastodon

     # Put the config file in /etc and link to it
    touch "$pkgdir"/etc/mastodon.conf
    ln -s /etc/mastodon.conf "$pkgdir"/var/lib/mastodon/.env.production
    ln -s /usr/bin/node "$pkgdir"/var/lib/mastodon/node

    install -Dm 644 mastodon.target -t "$pkgdir"/usr/lib/systemd/system
    install -Dm 644 mastodon.sysusers.d "$pkgdir"/usr/lib/sysusers.d/mastodon.conf
    install -Dm 644 mastodon.tmpfiles.d "$pkgdir"/usr/lib/tmpfiles.d/mastodon.conf

    cd mastodon-$pkgver/dist

    # Fix path discrepancies
    sed -e 's/home\/mastodon\/live/var\/lib\/mastodon/g' -e 's/home\/mastodon\/.rbenv\/shims/usr\/bin/' -i mastodon-*.service
    sed -e 's/home\/mastodon\/live/var\/lib\/mastodon/g' -i nginx.conf

    install -Dm 644 mastodon-*.service -t "$pkgdir"/usr/lib/systemd/system
}

Vamp898 commented on 2026-02-24 15:18 (UTC)

As i migrated to GoToSocial, i am no longer using Mastodon, hence testing this package. So i gave up maintainership.

darkfm commented on 2025-11-09 23:58 (UTC)

Missing dependency on corepack:

/home/kouta/.cache/rua/build/mastodon/PKGBUILD: línea 62: corepack: orden no encontrada

Maybe was transitive dependency and is no longer depended on by some of the packages?

Vamp898 commented on 2025-07-17 09:15 (UTC)

All right, i'll continue, i don't want to see this abandoned. I am working on the 4.4 Package right now, PLEASE!, read the post install instructions when you install it. I am not kidding. This needs manual intervention, you have to do this. The upgrade is coming today

ruscur commented on 2025-07-16 04:26 (UTC)

Thanks for your all your efforts, hopefully someone keeps it going

Vamp898 commented on 2025-07-10 15:08 (UTC) (edited on 2025-07-10 15:09 (UTC) by Vamp898)

I am giving up this package, anyone feel free to pickup.

I simply have no time anymore due to other projects and this pile of ruby is absolutely no fun to package and test

Vamp898 commented on 2025-07-09 04:20 (UTC) (edited on 2025-07-09 04:21 (UTC) by Vamp898)

The Mastodon Developers only support nginx though. Other Webservers did sometimes work in the past, but a after a few updates it suddenly stopped working and in case with Apache, afaik, nobody got it ever working again.

They do not care about other Webservers. The Team behind Mastodon develops and tests for nginx, if you use something else, you are on your own if it doesn't work.

So i am not sure if an Wikipage describing how to get it running in an unsupported environment is really that helpful because, when it breaks and there is nothing you can do because Mastodon expects an Nginx feature/setting, there is nothing you can do. And they would, rightfully, complain that they followed an Archlinux Wiki Page that told them, how to set it up an a way where it is known to break in the future.

Mastodon only supports nginx, nothing else. If someone doesn't want to use nginx, he should not run a mastodon server but use one of its many alternatives (imho)

Refutationalist commented on 2025-07-07 21:52 (UTC)

I came up with configuration stanzas that make it work with lighttpd, I should probably post them somewhere.

Seems like this is something that could use a wiki page.

Vamp898 commented on 2025-07-06 00:53 (UTC)

The resources are there, they are just not delivered to the browser. That is a very common error, it means your webserver config is wrong.

feedc0de commented on 2025-07-04 09:10 (UTC)

would you mind checking my post reddit? i really have no idea how i can mess up the compilation so that it delivers html correctly but the js resources are missing. https://www.reddit.com/r/Mastodon/comments/1lp4q9y/