Commit Graph

7 Commits

Author SHA1 Message Date
Antony Messerli
ca7a3390c2
Implement rootless Docker container with enhanced security and preserved TFTP logging (#87)
* Implement rootless Docker container with preserved TFTP logging

- Convert all processes to run as non-root user (nbxyz) for enhanced security
- Add customizable PUID/PGID environment variables for volume permission management
- Implement privilege dropping using gosu for secure initialization
- Optimize Dockerfile with multi-stage build and better caching
- Create dnsmasq wrapper script to ensure TFTP logs appear in docker logs
- Configure supervisord to properly forward dnsmasq output to container stdout
- Maintain full TFTP/PXE boot debugging functionality for users

Security improvements:
- All application processes (nginx, webapp, dnsmasq) run as nbxyz user
- Only supervisord initialization runs as root, then drops privileges
- Proper permission management for all service directories
- Configurable user/group IDs via PUID/PGID environment variables

Performance optimizations:
- Multi-stage Docker build reduces final image size
- Better layer caching for faster rebuilds
- Optimized package installation and cleanup

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

* Update Dockerfile

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update root/init.sh

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-06-12 00:19:27 -05:00
dezeroku
fe00be36f4
Replace in.tftp with dnsmasq, to add support for single-port TFTP 2024-07-13 00:20:28 +02:00
Kelly Shutt
c4014a0a6e Make web app port configurable. 2024-02-02 08:10:30 -05:00
Antony Messerli
51e9e3df03 Revert adding user to tftpd
Error: cannot set groups for user nbxyz
2023-01-19 01:14:58 -06:00
Antony Messerli
a3fc61bdcc Update to Alpine 3.17
Removes deprecated npm option, sets user to nbxyz
for tftpd, adds script for testing build
2023-01-19 00:41:50 -06:00
Julien Nicoulaud
7e4f4d465a
add support for passing additional options to tftpd 2022-02-08 19:53:56 +01:00
Antony Messerli
027cd38089 first commit 2021-09-06 19:07:15 -05:00