fauria / docker-vsftpd

🐳 vsftpd Docker image based on Centos 7. Supports passive mode and virtual users.
https://hub.docker.com/r/fauria/vsftpd/
Apache License 2.0
414 stars 341 forks source link

Unable to access using FileZilla #71

Closed DiponRoy closed 2 years ago

DiponRoy commented 2 years ago

Here is my docker compose

version: "3.7"

services:
  ftp:
    image: fauria/vsftpd:latest
    container_name: Ftp
    restart: always
    environment:
      - FTP_USER=adminuser
      - FTP_PASS=adminpass
      - PASV_ADDRESS=127.0.0.1
      - PASV_MIN_PORT=21100
      - PASV_MAX_PORT=21110
    volumes:
      - ftp-data:/home/vsftpd
      - ftp-log-data:/var/log/vsftpd
    ports:
      - 20:20
      - 21:21
      - 21100-21110:21100-21110

volumes:
  ftp-data:
  ftp-log-data:

while trying to access using FileZilla its saying

Error:  Could not connect to server
Status: Waiting to retry...
Status: Connecting to 127.0.0.1:21...
Status: Connection attempt failed with "ECONNREFUSED - Connection refused by server".

also tried with PASV_ADDR_RESOLVE=YES

I am running docker in Windows

DiponRoy commented 2 years ago

it worked after using

    ports:
      - 0.0.0.0:20:20
      - 0.0.0.0:21:21
      - "21100-21110:21100-21110"
bora89 commented 2 years ago

Author

yes, you should use qoutes for ports specifications