The Dockerfile has an error, when filling in the sudoers file during build, it performs path expansion, replacing * with a list of file system directories. The file then contains nonsense:
prometheus-wireguard-exporter ALL=(root) NOPASSWD:/usr/bin/wg show bin dev etc home lib media mnt opt proc root run sbin srv sys tmp usr var dump
As a result, the wg dump command doesn't work in the container at all.
It should be properly escaped, or rather, put in quotes to avoid path expansion.
The Dockerfile has an error, when filling in the sudoers file during build, it performs path expansion, replacing * with a list of file system directories. The file then contains nonsense:
As a result, the wg dump command doesn't work in the container at all.
It should be properly escaped, or rather, put in quotes to avoid path expansion.