Compare commits

...

3 commits

6 changed files with 44 additions and 11 deletions

View file

@ -78,10 +78,6 @@
vars:
lemmy_docker_image: "dessalines/lemmy:{{ lookup('file', 'VERSION') }}"
lemmy_docker_ui_image: "dessalines/lemmy-ui:{{ lookup('file', 'VERSION') }}"
lemmy_port: "8536"
lemmy_ui_port: "1235"
pictshare_port: "8537"
iframely_port: "8538"
- name: add config file (only during initial setup)
template:

View file

@ -27,6 +27,15 @@ services:
depends_on:
- lemmy
lemmy-lite:
image: ironoxidizer/lemmy-lite:0.3.0-rc2
ports:
- "127.0.0.1:1131:1131"
environment:
- LEMMY_INTERNAL_HOST=lemmy:8536
depends_on:
- lemmy
postgres:
image: postgres:12-alpine
environment:
@ -40,8 +49,6 @@ services:
pictrs:
image: asonix/pictrs:v0.2.4-r0
user: 991:991
ports:
- "127.0.0.1:8537:8080"
volumes:
- ./volumes/pictrs:/mnt
restart: always

View file

@ -51,7 +51,7 @@ server {
# Upload limit for pictrs
client_max_body_size 20M;
# frontend
# standard frontend
location / {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $host;
@ -61,21 +61,29 @@ server {
# lemmy_ui_port: 1235
# lemmy_port: 8536
set $proxpass "http://0.0.0.0:{{ lemmy_ui_port }}";
set $proxpass "http://0.0.0.0:1235";
if ($http_accept = "application/activity+json") {
set $proxpass "http://0.0.0.0:{{ lemmy_port }}";
set $proxpass "http://0.0.0.0:8536";
}
if ($request_method = POST) {
set $proxpass "http://0.0.0.0:{{ lemmy_port }}";
set $proxpass "http://0.0.0.0:8536";
}
proxy_pass $proxpass;
rewrite ^(.+)/+$ $1 permanent;
}
# lemmy lite frontend
location /lite {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_pass "http://0.0.0.0:1131";
}
# backend
location ~ ^/(api|docs|pictrs|feeds|nodeinfo|.well-known) {
proxy_pass http://0.0.0.0:{{ lemmy_port }};
proxy_pass http://0.0.0.0:8536;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";

View file

@ -26,6 +26,14 @@ services:
- LEMMY_HTTPS=false
depends_on:
- lemmy
lemmy-lite:
image: ironoxidizer/lemmy-lite:0.3.0-rc2
ports:
- "1131:1131"
environment:
- LEMMY_INTERNAL_HOST=lemmy:8536
depends_on:
- lemmy
postgres:
image: postgres:12-alpine

View file

@ -16,6 +16,7 @@ services:
- pictrs
- iframely
- lemmy-alpha-ui
- lemmy-alpha-lite
- lemmy-beta-ui
- lemmy-gamma-ui
- lemmy-delta-ui
@ -36,6 +37,12 @@ services:
- LEMMY_HTTPS=false
depends_on:
- lemmy-alpha
lemmy-alpha-lite:
image: ironoxidizer/lemmy-lite:0.3.0-rc2
environment:
- LEMMY_INTERNAL_HOST=lemmy-alpha:8541
depends_on:
- lemmy-alpha
lemmy-alpha:
image: lemmy-federation:latest
environment:

View file

@ -43,6 +43,13 @@ http {
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
location /lite {
proxy_pass http://lemmy-alpha-lite:1131;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
}
upstream lemmy-beta {