From 5fd38ca5f0ed29ee89de38b95caacccbc005dd62 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Szymon=20Karpi=C5=84ski?= Date: Sat, 1 Feb 2020 13:14:43 +0100 Subject: [PATCH] Basic TFTP server container --- tftp/Dockerfile | 6 ++++++ tftp/tftp.xinetd.conf | 13 +++++++++++++ 2 files changed, 19 insertions(+) create mode 100644 tftp/Dockerfile create mode 100644 tftp/tftp.xinetd.conf diff --git a/tftp/Dockerfile b/tftp/Dockerfile new file mode 100644 index 0000000..7d0580f --- /dev/null +++ b/tftp/Dockerfile @@ -0,0 +1,6 @@ +FROM debian:buster +RUN apt update && apt install -y xinetd tftpd-hpa +RUN mkdir -p /tftpboot && chmod -R 777 /tftpboot && chown -R nobody /tftpboot +COPY tftp.xinetd.conf /etc/xinetd.d/tftp +COPY Dockerfile /tftpboot/test +CMD ["script", "-c", "/usr/sbin/xinetd -d"] diff --git a/tftp/tftp.xinetd.conf b/tftp/tftp.xinetd.conf new file mode 100644 index 0000000..3443686 --- /dev/null +++ b/tftp/tftp.xinetd.conf @@ -0,0 +1,13 @@ +service tftp +{ + socket_type = dgram + protocol = udp + wait = yes + user = root + server = /usr/sbin/in.tftpd + server_args = -s /tftpboot + disable = no + per_source = 11 + cps = 100 2 + flags = IPv4 +}