Closed leic4u closed 1 month ago
You should use network_mode: host
in both s-ui and sing-box containers and remove ports sections.
Hey bro. I could use the any port by installing s-ui with this config:
---
services:
s-ui:
image: alireza7/s-ui
container_name: s-ui
hostname: "S-UI docker"
volumes:
- "singbox:/app/bin"
- "$PWD/db:/app/db"
- "/root/nginx-ui/nginx/ssl:/cert"
environment:
SINGBOX_API: "localhost:1080"
SUI_DB_FOLDER: "db"
tty: true
restart: unless-stopped
network_mode: "host"
entrypoint: "./sui"
sing-box:
image: alireza7/s-ui-singbox
container_name: sing-box
volumes:
- "singbox:/app/"
- "/root/nginx-ui/nginx/ssl:/cert"
network_mode: "host"
restart: unless-stopped
depends_on:
- s-ui
volumes:
singbox:
When I use host, an error message appears in the sing-box container. "start service: start v2ray api: listen tcp: lookup sing-box on 192.168.1.1:53: no such host" Do you know how to solve it?
Looks like the Docker routing rules were not created correctly. You can try restarting the Docker service.
Looks like the Docker routing rules were not created correctly. You can try restarting the Docker service.
Yes, I used wrong information in sing-box's api reference, I have solved it, thanks for your answer
I tried compose.yml like this, but it seems that the sing-box core could not work, with my config in s-ui panel:
How could I use the all ports conveniently? Or could you please provide a image which contains both panel and core?