i'm trying to setup a simple container i docker with pure-ftpd running.
But on running service pure-ftpd start
i get this error:
Starting ftp server: Running: /usr/sbin/pure-ftpd -l pam -E -8 UTF-8 -O clf:/var/log/pure-ftpd/transfer.log -u 1000 -B
421 Unable to switch capabilities : Operation not permitted
Here's the Dockerfile for testing this:
FROM debian:wheezy
ENV DEBIAN_FRONTEND noninteractive
RUN apt-get -y update
RUN apt-get install -y pure-ftpd-common pure-ftpd
CMD service pure-ftpd start && \
/bin/bash
EXPOSE 21/tcp
In this test i'm using debian wheezy, but i've tried with ubuntu too and i get exact the same error.
[ Edit ]
Working version with this fix is now available here: https://index.docker.io/u/stilliard/pure-ftpd/
It seems your host machine does not allow capability switching.
You could modify the optflags
in the source package for pure-ftpd
by adding --without-capabilities
Steps to add in your Docker file
rules
file, append with sed the --without-capabilities
optionsdpkg-buildpackage -b -uc
to build the package and install it with dpkg -i
This should do the trick.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With