Closed fcying closed 5 years ago
Hi @fcying , I don't know what you mean. The TCP/9000 port is your frontside port and TCP/80 is the backend port inside the container. So you're not using port 80, instead you're using port 9000. If this port is occupied, you need to specify another port (ex. -p 9090:80).
@ApolloDS
I have another service, that service uses TCP/80.
so seafile can't use -p 80:80
, I want to change the seafile frontside port... ex. xx.com:9000.
but I set -p 9000:80
can't work.
Or do I need to modify seafile backend port inside the container?
Or do I need to modify seafile backend port inside the container?
Seafile Docker is listening per default in the container on TCP/80 and TCP/443. What you need is to specify the frontside and backend port when you start the container. So when you're using TCP/9000 for it and it is occupied, use another free port for it.
You don't need to change the TCP port in the container.
Seafile is described here: https://github.com/haiwen/seafile-docker
I didn't see any solution in https://github.com/haiwen/seafile-docker
. it used -p 80:80
and -p 443:443
But my TCP/80 and TCP/443 is occupied.
Or do I need to modify seafile backend port inside the container?
Seafile Docker is listening per default in the container on TCP/80 and TCP/443. What you need is to specify the frontside and backend port when you start the container. So when you're using TCP/9000 for it and it is occupied, use another free port for it.
You don't need to change the TCP port in the container.
Seafile is described here: https://github.com/haiwen/seafile-docker
I didn't see any solution in https://github.com/haiwen/seafile-docker
. it used -p 80:80
and -p 443:443
But my TCP/80 and TCP/443 is occupied.
I didn't see any solution in
https://github.com/haiwen/seafile-docker
. it used-p 80:80
and-p 443:443
But my TCP/80 and TCP/443 is occupied.
Please check this link to understand the docker networking: https://kb.novaordis.com/index.php/Docker_Networking_Concepts
Check this picture: https://kb.novaordis.com/index.php/Docker_Networking_Concepts#The_Default_Bridge_Network
-p 80:80 and/or -p 443:443 is just an example.
I didn't see any solution in
https://github.com/haiwen/seafile-docker
. it used-p 80:80
and-p 443:443
But my TCP/80 and TCP/443 is occupied.Please check this link to understand the docker networking: https://kb.novaordis.com/index.php/Docker_Networking_Concepts
Check this picture: https://kb.novaordis.com/index.php/Docker_Networking_Concepts#The_Default_Bridge_Network
-p 80:80 and/or -p 443:443 is just an example.
I know the docker network. I just want a way to modify seafile default port. Using -p PORT:80
can't work.
I know the docker network. I just want a way to modify seafile default port. Using
-p PORT:80
can't work.
So then you need create your own seafile docker image with this option in it. The standard image uses only 80/443.
I know the docker network. I just want a way to modify seafile default port. Using
-p PORT:80
can't work.So then you need create your own seafile docker image with this option in it. The standard image uses only 80/443.
create my own docker image, and then modify the nginx config host
to http_host
now I can set -p 9000:80
to visit seafile by useing port 9000. tks
=======================================================
modify docker-compose.yml
, and then use
volumes:
- ./seafile.nginx.conf.template:/templates/seafile.nginx.conf.template:ro
can use origin seafile image
Port 80 is occupied by another service. How can I use another port number?
-p 9000:80
can't work.