{"status":"OK","last_updated":"2026-11-29 15:34:37+00:00","data":{"image":{"name":"mastodon","initial_date":"2022-11-05","github_url":"https://github.com/linuxserver-playground/docker-mastodon","project_url":"https://github.com/mastodon/mastodon/","project_logo":"https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/mastodon-banner.png","description":"[Mastodon](https://github.com/mastodon/mastodon/) is a free, open-source social network server based on ActivityPub where users can follow friends and discover new ones..","version":"v4.7.6-ls14","version_timestamp":"2026-11-28 10:41:16+00:00","category":"Social","stable":true,"deprecated":false,"stars":0,"tags":[{"tag":"latest","desc":"Stable releases."},{"tag":"develop","desc":"Pre-releases *only*."},{"tag":"glitch","desc":"[glitch-soc](https://github.com/glitch-soc/mastodon) fork releases."}],"architectures":[{"arch":"x86_64","tag":"amd64-latest"},{"arch":"arm64","tag":"arm64v8-latest"}],"changelog":[{"date":"2026-07-05","desc":"Rebase to Alpine 3.24."},{"date":"2025-10-21","desc":"Add prometheus exporter support."},{"date":"2025-10-20","desc":"Add vips-heif."},{"date":"2025-07-08","desc":"Rebase to Alpine 3.22."},{"date":"2025-06-06","desc":"Rebase to Alpine 3.21, replace deprecated imagemagick with vips."},{"date":"2024-10-08","desc":"Rebase to Alpine 3.20, enable [Active Record Encryption](https://github.com/mastodon/mastodon/pull/29831/files). Existing users should update their nginx confs to avoid http2 deprecation warnings."},{"date":"2023-09-21","desc":"Rebase to Alpine 3.18, migrate to s6v3."},{"date":"2023-05-25","desc":"Adjust apk flags."},{"date":"2023-02-09","desc":"Add Glitch branch."},{"date":"2023-01-09","desc":"Updated nginx conf to fix bring inline with Mastodon configuration (fixes Elk integration)."},{"date":"2022-12-19","desc":"Support separate sidekiq queue instances."},{"date":"2022-11-05","desc":"Initial Release."}],"config":{"application_setup":"https://github.com/linuxserver-playground/docker-mastodon?tab=readme-ov-file#application-setup","env_vars":[{"name":"PUID","value":"1000","desc":"User ID","optional":false},{"name":"PGID","value":"1000","desc":"Group ID","optional":false},{"name":"TZ","value":"Etc/UTC","desc":"Timezone","optional":false},{"name":"LOCAL_DOMAIN","value":"example.com","desc":"This is the unique identifier of your server in the network. It cannot be safely changed later.","optional":false},{"name":"REDIS_HOST","value":"redis","desc":"Redis server hostname","optional":false},{"name":"REDIS_PORT","value":"6379","desc":"Redis port","optional":false},{"name":"DB_HOST","value":"db","desc":"Postgres database hostname","optional":false},{"name":"DB_USER","value":"mastodon","desc":"Postgres username","optional":false},{"name":"DB_NAME","value":"mastodon","desc":"Postgres db name","optional":false},{"name":"DB_PASS","value":"mastodon","desc":"Postgres password","optional":false},{"name":"DB_PORT","value":"5432","desc":"Postgres port","optional":false},{"name":"ES_ENABLED","value":"false","desc":"Enable or disable Elasticsearch (requires a separate ES instance)","optional":false},{"name":"ACTIVE_RECORD_ENCRYPTION_PRIMARY_KEY","value":"","desc":"Primary key for [Active Record Encryption](https://github.com/mastodon/mastodon/pull/29831/files).","optional":false},{"name":"ACTIVE_RECORD_ENCRYPTION_DETERMINISTIC_KEY","value":"","desc":"Deterministic key for [Active Record Encryption](https://github.com/mastodon/mastodon/pull/29831/files).","optional":false},{"name":"ACTIVE_RECORD_ENCRYPTION_KEY_DERIVATION_SALT","value":"","desc":"Derivation salt for [Active Record Encryption](https://github.com/mastodon/mastodon/pull/29831/files).","optional":false},{"name":"SECRET_KEY_BASE","value":"","desc":"Browser session secret. Changing it will break all active browser sessions.","optional":false},{"name":"OTP_SECRET","value":"","desc":"MFA secret. Changing it after initial setup will break two-factor authentication.","optional":false},{"name":"VAPID_PRIVATE_KEY","value":"","desc":"Push notification private key. Changing it after initial setup will break push notifications.","optional":false},{"name":"VAPID_PUBLIC_KEY","value":"","desc":"Push notification public key. Changing it after initial setup will break push notifications.","optional":false},{"name":"SMTP_SERVER","value":"mail.example.com","desc":"SMTP server for email notifications","optional":false},{"name":"SMTP_PORT","value":"25","desc":"SMTP server port","optional":false},{"name":"SMTP_LOGIN","value":"","desc":"SMTP username","optional":false},{"name":"SMTP_PASSWORD","value":"","desc":"SMTP password","optional":false},{"name":"SMTP_FROM_ADDRESS","value":"notifications@example.com","desc":"From address for emails send from Mastodon","optional":false},{"name":"S3_ENABLED","value":"false","desc":"Enable or disable S3 storage of uploaded files","optional":false},{"name":"WEB_DOMAIN","value":"mastodon.example.com","desc":"This can be set if you want your server identifier to be different to the subdomain hosting Mastodon. See [https://docs.joinmastodon.org/admin/config/#basic](https://docs.joinmastodon.org/admin/config/#basic)","optional":true},{"name":"ES_HOST","value":"es","desc":"Elasticsearch server hostname","optional":true},{"name":"ES_PORT","value":"9200","desc":"Elasticsearch port","optional":true},{"name":"ES_USER","value":"elastic","desc":"Elasticsearch username","optional":true},{"name":"ES_PASS","value":"elastic","desc":"Elasticsearch password","optional":true},{"name":"S3_BUCKET","value":"","desc":"S3 bucket hostname","optional":true},{"name":"AWS_ACCESS_KEY_ID","value":"","desc":"S3 bucket access key ID","optional":true},{"name":"AWS_SECRET_ACCESS_KEY","value":"","desc":"S3 bucket secret access key","optional":true},{"name":"S3_ALIAS_HOST","value":"","desc":"Alternate hostname for object fetching if you are front the S3 connections.","optional":true},{"name":"SIDEKIQ_ONLY","value":"false","desc":"Only run the sidekiq service in this container instance. For large scale instances that need better queue handling.","optional":true},{"name":"SIDEKIQ_QUEUE","value":"","desc":"The name of the sidekiq queue to run in this container. See [notes](https://docs.joinmastodon.org/admin/scaling/#sidekiq-queues).","optional":true},{"name":"SIDEKIQ_DEFAULT","value":"false","desc":"Set to `true` on the main container if you're running additional sidekiq instances. It will run the `default` queue.","optional":true},{"name":"SIDEKIQ_THREADS","value":"5","desc":"The number of threads for sidekiq to use. See [notes](https://docs.joinmastodon.org/admin/scaling/#sidekiq-threads).","optional":true},{"name":"DB_POOL","value":"5","desc":"The size of the DB connection pool, must be *at least* the same as `SIDEKIQ_THREADS`. See [notes](https://docs.joinmastodon.org/admin/scaling/#sidekiq-threads).","optional":true},{"name":"NO_CHOWN","value":"","desc":"Set to `true` to skip chown of /config on init. *READ THE APPLICATION NOTES BEFORE SETTING THIS*.","optional":true},{"name":"MASTODON_PROMETHEUS_EXPORTER_ENABLED","value":"","desc":"If set to `true`, Mastodon’s Ruby processes (web & Sidekiq) will enable the Prometheus instrumentation.","optional":true}],"volumes":[{"path":"/config","host_path":"/path/to/mastodon/config","desc":"Contains all relevant configuration files.","optional":false}],"ports":[{"external":"80","internal":"80","desc":"Port for web frontend","optional":false},{"external":"443","internal":"443","desc":"Port for web frontend","optional":false},{"external":"9394","internal":"9394","desc":"Port for Prometheus metrics","optional":true}]},"title":"Mastodon","sponsor":[{"name":"Mastodon","url":"https://joinmastodon.org/sponsors#donate"}],"maintainers":[],"kind":"app","categories":["Social"],"setup_instructions":"We provide aliases for the common commands that execute in the correct context so that environment variables from secrets are available to them:\n\n* To generate keys for `SECRET_KEY_BASE` & `OTP_SECRET` run `docker run --rm -it --entrypoint /bin/bash lscr.io/linuxserver/mastodon:latest generate-secret` once for each.\n\n* To generate keys for `VAPID_PRIVATE_KEY` & `VAPID_PUBLIC_KEY` run `docker run --rm -it --entrypoint /bin/bash lscr.io/linuxserver/mastodon:latest generate-vapid`\n\n* To generate keys for `ACTIVE_RECORD_ENCRYPTION_DETERMINISTIC_KEY`, `ACTIVE_RECORD_ENCRYPTION_KEY_DERIVATION_SALT`, & `ACTIVE_RECORD_ENCRYPTION_PRIMARY_KEY` run `docker run --rm -it --entrypoint /bin/bash lscr.io/linuxserver/mastodon:latest generate-active-record`\n\nBoth of the secret generation aliases above can be run without any other setup having been carried out.\n\n* To use `tootctl` you can run something like `docker exec -it lscr.io/linuxserver/mastodon /tootctl <command>`\n\nUsing `tootctl` requires you to complete the initial Mastodon configuration first.\n\nThis container *requires* separate postgres and redis instances to run.\n\nWe support all of the official [environment variables](https://docs.joinmastodon.org/admin/config) for configuration. In place of adding them all to your run/compose you can use an env file such as [this example](https://github.com/mastodon/mastodon/blob/main/.env.production.sample) from the upstream project.\n\nFor more information check out the [mastodon documentation](https://docs.joinmastodon.org/).\n\n### Running separate sidekiq instances\n\nIt is currently only supported to run a single queue per container instance *or* all queues in a single container instance.\n\nAll containers must share the same `/config` mount and be on a common docker network.\n\n### NO_CHOWN Option\n\nOn larger Mastodon instances, our init process to verify that permissions are set correctly can noticeably slow down the container startup. If you are experiencing this, you can set `NO_CHOWN` to `true` to skip that step of the init.\n\n*Do NOT set this on first run of the container. If you enable this option you are taking full responsibility for ensuring that the permissions in your /config mount are correct. If you're even slightly unsure, don't set it.*\n\n### Strict reverse proxies\n\nThis image automatically redirects to https with a self-signed certificate. If you are using a reverse proxy which validates certificates, you need to [disable this check for the container](https://docs.linuxserver.io/faq#strict-proxy).","archived":false,"release_url":"https://github.com/linuxserver-playground/docker-mastodon/releases/tag/v4.7.6-ls14","upstream_version":"v4.7.6","base":"alpine-nginx","releases":[{"branch":"develop","release_tag":"develop","channel":"prerelease","tag":"develop-v4.7.0-rc.1-ls5","upstream_version":"v4.7.0-rc.1","created":"2026-11-04T11:27:21Z","release_url":"https://github.com/linuxserver-playground/docker-mastodon/releases/tag/develop-v4.7.0-rc.1-ls5","base":"ghcr.io/linuxserver-playground/baseimage-alpine-nginx:3.24","platforms":["amd64","arm64"]},{"branch":"glitch","release_tag":"glitch","channel":"prerelease","tag":"glitch-v4.7.6-ls13","upstream_version":"v4.7.6","created":"2026-11-26T08:52:04Z","release_url":"https://github.com/linuxserver-playground/docker-mastodon/releases/tag/glitch-v4.7.6-ls13","base":"ghcr.io/linuxserver-playground/baseimage-alpine-nginx:3.24","platforms":["amd64","arm64"]},{"branch":"main","release_tag":"latest","channel":"stable","tag":"v4.7.6-ls14","upstream_version":"v4.7.6","created":"2026-11-28T10:41:16Z","release_url":"https://github.com/linuxserver-playground/docker-mastodon/releases/tag/v4.7.6-ls14","base":"ghcr.io/linuxserver-playground/baseimage-alpine-nginx:3.24","platforms":["amd64","arm64"]}],"docs_url":"https://linuxserver-playground.github.io/site/images/mastodon/","registries":{"ghcr":"ghcr.io/linuxserver-playground/mastodon","packages_url":"https://github.com/orgs/linuxserver-playground/packages/container/package/mastodon"},"snippets":{"docker_compose":"---\nservices:\n  mastodon:\n    image: ghcr.io/linuxserver-playground/mastodon:latest\n    container_name: mastodon\n    environment:\n      - PUID=1000\n      - PGID=1000\n      - TZ=Etc/UTC\n      - LOCAL_DOMAIN=example.com\n      - REDIS_HOST=redis\n      - REDIS_PORT=6379\n      - DB_HOST=db\n      - DB_USER=mastodon\n      - DB_NAME=mastodon\n      - DB_PASS=mastodon\n      - DB_PORT=5432\n      - ES_ENABLED=false\n      - ACTIVE_RECORD_ENCRYPTION_PRIMARY_KEY=\n      - ACTIVE_RECORD_ENCRYPTION_DETERMINISTIC_KEY=\n      - ACTIVE_RECORD_ENCRYPTION_KEY_DERIVATION_SALT=\n      - SECRET_KEY_BASE=\n      - OTP_SECRET=\n      - VAPID_PRIVATE_KEY=\n      - VAPID_PUBLIC_KEY=\n      - SMTP_SERVER=mail.example.com\n      - SMTP_PORT=25\n      - SMTP_LOGIN=\n      - SMTP_PASSWORD=\n      - SMTP_FROM_ADDRESS=notifications@example.com\n      - S3_ENABLED=false\n      - WEB_DOMAIN=mastodon.example.com #optional\n      - ES_HOST=es #optional\n      - ES_PORT=9200 #optional\n      - ES_USER=elastic #optional\n      - ES_PASS=elastic #optional\n      - S3_BUCKET= #optional\n      - AWS_ACCESS_KEY_ID= #optional\n      - AWS_SECRET_ACCESS_KEY= #optional\n      - S3_ALIAS_HOST= #optional\n      - SIDEKIQ_ONLY=false #optional\n      - SIDEKIQ_QUEUE= #optional\n      - SIDEKIQ_DEFAULT=false #optional\n      - SIDEKIQ_THREADS=5 #optional\n      - DB_POOL=5 #optional\n      - NO_CHOWN= #optional\n      - MASTODON_PROMETHEUS_EXPORTER_ENABLED= #optional\n    volumes:\n      - /path/to/mastodon/config:/config\n    ports:\n      - 80:80\n      - 443:443\n      - 9394:9394 #optional\n    restart: unless-stopped\n","docker_run":"docker run -d \\\n  --name=mastodon \\\n  -e PUID=1000 \\\n  -e PGID=1000 \\\n  -e TZ=Etc/UTC \\\n  -e LOCAL_DOMAIN=example.com \\\n  -e REDIS_HOST=redis \\\n  -e REDIS_PORT=6379 \\\n  -e DB_HOST=db \\\n  -e DB_USER=mastodon \\\n  -e DB_NAME=mastodon \\\n  -e DB_PASS=mastodon \\\n  -e DB_PORT=5432 \\\n  -e ES_ENABLED=false \\\n  -e ACTIVE_RECORD_ENCRYPTION_PRIMARY_KEY= \\\n  -e ACTIVE_RECORD_ENCRYPTION_DETERMINISTIC_KEY= \\\n  -e ACTIVE_RECORD_ENCRYPTION_KEY_DERIVATION_SALT= \\\n  -e SECRET_KEY_BASE= \\\n  -e OTP_SECRET= \\\n  -e VAPID_PRIVATE_KEY= \\\n  -e VAPID_PUBLIC_KEY= \\\n  -e SMTP_SERVER=mail.example.com \\\n  -e SMTP_PORT=25 \\\n  -e SMTP_LOGIN= \\\n  -e SMTP_PASSWORD= \\\n  -e SMTP_FROM_ADDRESS=notifications@example.com \\\n  -e S3_ENABLED=false \\\n  -e WEB_DOMAIN=mastodon.example.com `#optional` \\\n  -e ES_HOST=es `#optional` \\\n  -e ES_PORT=9200 `#optional` \\\n  -e ES_USER=elastic `#optional` \\\n  -e ES_PASS=elastic `#optional` \\\n  -e S3_BUCKET= `#optional` \\\n  -e AWS_ACCESS_KEY_ID= `#optional` \\\n  -e AWS_SECRET_ACCESS_KEY= `#optional` \\\n  -e S3_ALIAS_HOST= `#optional` \\\n  -e SIDEKIQ_ONLY=false `#optional` \\\n  -e SIDEKIQ_QUEUE= `#optional` \\\n  -e SIDEKIQ_DEFAULT=false `#optional` \\\n  -e SIDEKIQ_THREADS=5 `#optional` \\\n  -e DB_POOL=5 `#optional` \\\n  -e NO_CHOWN= `#optional` \\\n  -e MASTODON_PROMETHEUS_EXPORTER_ENABLED= `#optional` \\\n  -p 80:80 \\\n  -p 443:443 \\\n  -p 9394:9394 `#optional` \\\n  -v /path/to/mastodon/config:/config \\\n  --restart unless-stopped \\\n  ghcr.io/linuxserver-playground/mastodon:latest\n"},"links":{"builds":"https://linuxserver-playground.github.io/hub/api/v1/catalog/mastodon/builds.json","docs":"https://linuxserver-playground.github.io/hub/stores/docs/images/docker-mastodon.md","documentation":"https://linuxserver-playground.github.io/hub/api/v1/catalog/mastodon/docs.json","proxy":"https://linuxserver-playground.github.io/hub/api/v1/catalog/mastodon/proxy.json","kubernetes":"https://linuxserver-playground.github.io/hub/api/v1/catalog/mastodon/kubernetes.yaml","quadlet":"https://linuxserver-playground.github.io/hub/api/v1/catalog/mastodon/quadlet.container","mods":"https://linuxserver-playground.github.io/hub/api/v1/catalog/mastodon/mods.json"}}}}