This commit is contained in:
Vivianne 2024-02-25 10:15:00 -05:00
commit dc494afe07
2 changed files with 72 additions and 23 deletions

45
README.org Normal file
View File

@ -0,0 +1,45 @@
#+#+title: Solarpunk Mastodon
The solarpunk.moe mastodon configuration and customizations.
* Build
Building the project requires a couple of steps.
** Copy files
To build, copy the content of this folder to a copy of the mastodon source code, then =docker compose build=.
Assuming that your local mastodon checkout is located at =~/src/mastodon=, you can run the following from this project folder:
#+begin_src sh
SOLARPUNK_REPO=$PWD
MASTODON_REPO=$HOME/src/mastodon
cp -r $SOLARPUNK_REPO/* $MASTODON_REPO/
cp -r $SOLARPUNK_REPO/.env.production $MASTODON_REPO/
#+end_src
Should you have your mastodon checkout in a different location, set =MASTODON_REPO= to that location.
** Build docker images
After copying the files, we can build the docker images with:
#+begin_src sh
cd $MASTODON_REPO
docker compose build
#+end_src
* WIP Running mastodon
To run the instance, follow these steps:
*Going to need vv to fill this part out.*
** TODO Set up external networks
** TODO Set up reverse proxy
** TODO Set up cert-bot
** TODO Run containers

View File

@ -17,7 +17,7 @@ services:
redis: redis:
restart: always restart: always
image: redis:6-alpine image: redis:7-alpine
networks: networks:
- internal_network - internal_network
healthcheck: healthcheck:
@ -25,26 +25,27 @@ services:
volumes: volumes:
- ./redis:/data - ./redis:/data
es: #es:
restart: always # restart: always
image: docker.elastic.co/elasticsearch/elasticsearch-oss:7.10.2 # image: docker.elastic.co/elasticsearch/elasticsearch-oss:7.10.2
environment: # environment:
- "ES_JAVA_OPTS=-Xms512m -Xmx512m" # - "ES_JAVA_OPTS=-Xms512m -Xmx512m"
- "cluster.name=es-mastodon" # - "cluster.name=es-mastodon"
- "discovery.type=single-node" # - "discovery.type=single-node"
- "bootstrap.memory_lock=true" # - "bootstrap.memory_lock=true"
- "cluster.routing.allocation.disk.watermark.low=0.9" # - "cluster.routing.allocation.disk.watermark.low=0.95"
- "cluster.routing.allocation.disk.watermark.high=0.94" # - "cluster.routing.allocation.disk.watermark.high=0.97"
networks: # - "cluster.routing.allocation.disk.watermark.flood_stage=0.98"
- internal_network # networks:
healthcheck: # - internal_network
test: ["CMD-SHELL", "curl --silent --fail localhost:9200/_cluster/health || exit 1"] # healthcheck:
volumes: # test: ["CMD-SHELL", "curl --silent --fail localhost:9200/_cluster/health || exit 1"]
- elasticsearch:/usr/share/elasticsearch/data # volumes:
ulimits: # - elasticsearch:/usr/share/elasticsearch/data
memlock: # ulimits:
soft: -1 # memlock:
hard: -1 # soft: -1
# hard: -1
web: web:
build: . build: .
@ -78,7 +79,7 @@ services:
# - es # - es
volumes: volumes:
- ./public/system:/mastodon/public/system - ./public/system:/mastodon/public/system
streaming: streaming:
build: build:
context: . context: .
@ -107,7 +108,7 @@ services:
depends_on: depends_on:
- db - db
- redis - redis
sidekiq-mailers: sidekiq-mailers:
build: . build: .
image: git.solarpunk.moe/solarpunk/mastodon:${MASTO_VERSION} image: git.solarpunk.moe/solarpunk/mastodon:${MASTO_VERSION}
@ -141,6 +142,7 @@ services:
- external_network - external_network
- internal_network - internal_network
- mail - mail
- httpsproxy
volumes: volumes:
- ./public/system:/mastodon/public/system - ./public/system:/mastodon/public/system
@ -159,6 +161,7 @@ services:
- external_network - external_network
- internal_network - internal_network
- mail - mail
- httpsproxy
volumes: volumes:
- ./public/system:/mastodon/public/system - ./public/system:/mastodon/public/system
@ -177,6 +180,7 @@ services:
- external_network - external_network
- internal_network - internal_network
- mail - mail
- httpsproxy
volumes: volumes:
- ./public/system:/mastodon/public/system - ./public/system:/mastodon/public/system