-
Hi there! I'm trying to prettify my OpenMediaVault installation (Debian based) with ReProxy to manage with unhandy port service bindings, e. g.:
and so on. Static routes works fine, but I can't get to working routes into containers for a couple of days. ReProxy logs:
ReProxy routes: {
"git.nas.local": [
{
"route": "^/(.*)",
"destination": "http://172.21.0.2:3000/$1",
"server": "git.nas.local",
"match": "proxy",
"provider": "docker",
"ping": "http://172.21.0.2:3000/ping"
}
],
"omv.nas.local": [
{
"route": "^/(.*)",
"destination": "http://nas.local:8080/$1",
"server": "omv.nas.local",
"match": "proxy",
"provider": "static"
}
],
"portainer.nas.local": [
{
"route": "^/(.*)",
"destination": "http://nas.local:9000/$1",
"server": "portainer.nas.local",
"match": "proxy",
"provider": "static"
}
],
"rss.nas.local": [
{
"route": "^/(.*)",
"destination": "http://172.20.0.2:8080/$1",
"server": "rss.nas.local",
"match": "proxy",
"provider": "docker",
"ping": "http://172.20.0.2:8080/ping"
}
]
} ReProxy compose: services:
reproxy:
image: umputun/reproxy:master
container_name: reproxy
hostname: reproxy
ports:
- "80:8080"
- "443:8443"
- "8081:8081"
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
environment:
- TZ=Europe/Moscow
- LISTEN=0.0.0.0:8080
- DOCKER_ENABLED=true
- STATIC_ENABLED=true
- STATIC_RULES=
omv.nas.local,^/(.*),http://nas.local:8080/@1;
portainer.nas.local,^/(.*),http://nas.local:9000/@1;
- DEBUG=true
- LOGGER=stdout
- MGMT_ENABLED=true
- MAX=0
- HEALTH_CHECK_ENABLED=false Miniflux compose: version: '3.4'
services:
miniflux:
image: miniflux/miniflux:latest
container_name: miniflux
ports:
- "8083:8080"
depends_on:
- db
environment:
- DATABASE_URL=postgres://***:***@db/miniflux?sslmode=disable
- RUN_MIGRATIONS=1
- CREATE_ADMIN=1
- ADMIN_USERNAME=***
- ADMIN_PASSWORD=***
restart: unless-stopped
labels:
- reproxy.server=rss.nas.local
- reproxy.route=^/(.*)
- reproxy.dest=/@1
- reproxy.port=8080
db:
image: postgres:latest
container_name: miniflux_db
environment:
- POSTGRES_USER=***
- POSTGRES_PASSWORD=***
- PUID=1000
- PGID=100
volumes:
- /mnt/data/appdata/miniflux/db:/var/lib/postgresql/data
healthcheck:
test: ["CMD", "pg_isready", "-U", "miniflux"]
interval: 10s
start_period: 30s
restart: unless-stopped
labels:
- reproxy.exclude=true Gitea compose: version: "2"
services:
server:
image: gitea/gitea
container_name: gitea
environment:
- USER_UID=1002
- USER_GID=1000
restart: always
volumes:
- /mnt/data/appdata/gitea:/data
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
ports:
- "3000:3000"
- "222:22"
labels:
- reproxy.server=git.nas.local
- reproxy.route=^/(.*)
- reproxy.dest=/@1
- reproxy.port=3000 Of course dockerized services (miniflux and gitea) are accessible from the host. Gitea: nas.local$ curl -is 172.21.0.2:3000 | head -n15
HTTP/1.1 200 OK
Content-Type: text/html; charset=UTF-8
...
<!DOCTYPE html>
<html lang="en-US" class="theme-">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title> Gitea: Git with a cup of tea</title>
... Miniflux: nas.local$ curl -is 172.20.0.2:8080 | head -n20
HTTP/1.1 200 OK
Cache-Control: no-cache, max-age=0, must-revalidate, no-store
Content-Type: text/html; charset=utf-8
...
<!DOCTYPE html>
<html lang="en-US">
<head>
<meta charset="utf-8">
<title>Sign In - Miniflux</title>
... What I'm doing wrong? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
To make reproxy to see/access networks from your other composes, you need to define the network and add it to your composes. This is not related to reproxy, but rather the docker / docker-compose thing. See https://docs.docker.com/compose/networking/ for more details, but generally, all you need is to add smth like this to reporxy compose and use it for networks:
proxy:
external:
name: reproxy this is not an actual issue/bug report, I'll be moving it to discussions |
Beta Was this translation helpful? Give feedback.
To make reproxy to see/access networks from your other composes, you need to define the network and add it to your composes. This is not related to reproxy, but rather the docker / docker-compose thing. See https://docs.docker.com/compose/networking/ for more details, but generally, all you need is to add smth like this to reporxy compose and use it for
networks:
in your other composesthis is not an actual issue/bug report, I'll be moving it to discussions