4 # communication to web and clients
6 # communication between lemmy services
18 # actual and only port facing any connection from outside
22 - ./nginx.conf:/etc/nginx/nginx.conf:ro
29 # image: dessalines/lemmy:dev
30 # use this to build your local lemmy server image for development
31 # run docker compose up --build
34 dockerfile: docker/Dockerfile
36 # RUST_RELEASE_MODE: release
37 # this hostname is used in nginx reverse proxy and also for lemmy ui to connect to the backend, do not change
43 - RUST_LOG="warn,lemmy_server=debug,lemmy_api=debug,lemmy_api_common=debug,lemmy_api_crud=debug,lemmy_apub=debug,lemmy_db_schema=debug,lemmy_db_views=debug,lemmy_db_views_actor=debug,lemmy_db_views_moderator=debug,lemmy_routes=debug,lemmy_utils=debug,lemmy_websocket=debug"
46 - ./lemmy.hjson:/config/config.hjson
52 image: dessalines/lemmy-ui:0.17.1
53 # use this to build your local lemmy ui image for development
54 # run docker compose up --build
55 # assuming lemmy-ui is cloned besides lemmy directory
57 # context: ../../lemmy-ui
58 # dockerfile: dev.dockerfile
62 # this needs to match the hostname defined in the lemmy service
63 - LEMMY_UI_LEMMY_INTERNAL_HOST=lemmy:8536
64 # set the outside hostname here
65 - LEMMY_UI_LEMMY_EXTERNAL_HOST=localhost:1236
73 image: asonix/pictrs:0.4.0-beta.19
74 # this needs to match the pictrs url in lemmy.hjson
76 # we can set options to pictrs like this, here we set max. image size and forced format for conversion
77 # entrypoint: /sbin/tini -- /usr/local/bin/pict-rs -p /mnt -m 4 --image-format webp
81 - PICTRS_OPENTELEMETRY_URL=http://otel:4137
82 - PICTRS__API_KEY=API_KEY
85 - PICTRS__MEDIA__VIDEO_CODEC=vp9
86 - PICTRS__MEDIA__GIF__MAX_WIDTH=256
87 - PICTRS__MEDIA__GIF__MAX_HEIGHT=256
88 - PICTRS__MEDIA__GIF__MAX_AREA=65536
89 - PICTRS__MEDIA__GIF__MAX_FRAME_COUNT=400
92 - ./volumes/pictrs:/mnt
96 image: postgres:15-alpine
97 # this needs to match the database host in lemmy.hson
98 # Tune your settings via
99 # https://pgtune.leopard.in.ua/#/
100 # You can use this technique to add them here
101 # https://stackoverflow.com/a/30850095/1655478
105 "-c", "session_preload_libraries=auto_explain",
106 "-c", "auto_explain.log_min_duration=5ms",
107 "-c", "auto_explain.log_analyze=true",
108 "-c", "track_activity_query_size=1048576"
112 # adding the external facing network to allow direct db access for devs
115 # use a different port so it doesnt conflict with potential postgres db running on the host
118 - POSTGRES_USER=lemmy
119 - POSTGRES_PASSWORD=password
122 - ./volumes/postgres:/var/lib/postgresql/data
126 image: otel/opentelemetry-collector:latest
127 command: --config otel-local-config.yaml
136 target: /otel-local-config.yaml
137 restart: unless-stopped
142 image: jaegertracing/all-in-one:1
148 # To view traces, visit http://localhost:16686
150 restart: unless-stopped