Connect to an Amazon S3 bucket via FTP.
1.7K
An ftp/sftp server using s3fs to mount an external s3 bucket as ftp/sftp storage.
To run:
Replace env.list.example file with a real env.list file with correct variables filled in.
USERS environment variable. These should be listed in the form username:hashedpassword, each separated by a space.openssl passwd -crypt {your_password}. Substitute {your_password} with the one you want to hash.echo $u | chpasswd -e => echo $u | chpasswd in the users.sh file (line #24).FTP_BUCKET) and configs (CONFIG_BUCKET) will be stored.IAM_ROLE environment variable.AWS_ACCESS_KEY_ID and the AWS_SECRET_KEY_ID keys.If you have changed other files aside the env.list file, then you have to build the docker container using:
docker build --rm -t <docker/tag> path/to/dockerfile/folderThen after building the container (if necessary), run using:
docker run --rm -p 21:21 -p 30000-30100:30000-30100 --name <name> --cap-add SYS_ADMIN --device /dev/fuse --env-file env.list <docker/tag>docker run --restart=always -p 21:21 -p 30000-30100:30000-30100 --name <name> --cap-add SYS_ADMIN --device /dev/fuse --env-file env.list <docker/tag>env.list file is named differently change accordingly.docker run --restart=always -p 21:21 -p 30000-30100:30000-30100 --privileged --env-file env.list <docker/tag>USERS = List of users to add to the ftp/sftp server. Listed in the form username:hashedpassword, each separated by a space.FTP_BUCKET = S3 bucket where ftp/sftp users data will be stored.CONFIG_BUCKET = S3 bucket where the config data (env.list file) will be stored.IAM_ROLE = name of role account linked to EC2 instance the container is running in.PASV_ADDRESS =These two environment variables only need to be set if there is no linked IAM role to the EC2 instance.
AWS_ACCESS_KEY_ID = IAM user account access key.AWS_SECRET_ACCESS_KEY = IAM user account secret access key.Content type
Image
Digest
Size
179.8 MB
Last updated
almost 9 years ago
docker pull diogopms/ftp-proxy-s3