stilliard / docker-pure-ftpd

Docker Pure-ftpd Server

Home Page:https://hub.docker.com/r/stilliard/pure-ftpd/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

PUBLICHOST configuration

Auggie321 opened this issue · comments

Hi there,

use docker-compose.yml

version: '2'
services:
  ftpd_server:
    image: stilliard/pure-ftpd
    container_name: pure-ftpd
    ports:
      - "21:21"
      - "30000-30009:30000-30009"
    volumes:
      - "./folder_on_disk/data:/home/username/"
      - "./folder_on_disk/passwd:/etc/pure-ftpd/passwd"
    environment:
      PUBLICHOST: "172.16.200.128"
      FTP_USER_NAME: cassa
      FTP_USER_PASS: cassa123
      FTP_USER_HOME: /home/cassa
    restart: always

set docker-compose inner PUBLICHOST with host ip;

NAT Configuration in firewalld device (confirmed NAT configuration is correct)
104.243.xx.xx:221------->172.16.200.128:21

inner private network , you can access ftp with 172.16.200.128 21,
you can't access 104.243.xx.xx:221;
i mean PUBLICHOST, is rigth to set 0.0.0.0 in Dockerfile or somewhere?

Hi @Auggie321
Does the external access work ok when changing the publichost to the external ip?

@stilliard i deploy it in company with external ip 172.16.200.128, then just access work in company.

if i wanna access it from public network, i need configuration firewalld with NAT destination.

check some doc , found that can't access docker ftp without pasv_address configuration.

maybe need expose some ENV 'pasv_address'.

now , testing it with yum/apt deployment. If work normal, i will let you know ASAP.

Ah interesting, thanks for debugging it 👍

@stilliard

tested it in company and home, then i find this issues;
I am very sorry, it was a poblem with my juniper firewalld, routing back to the source that caused this problem.

Hey @Auggie321
No worries at all, glad you found the issue!

solved