Closed joshbautista closed 1 year ago
@joshbautista Thanks for the feature request, and sorry for not getting to you earlier. We'll look into it. Things that we need to take into account are:
(I'm not saying that any of the above needs to be a blocker for this, just that we need to look into it to get an understanding of what it would mean)
No problem, thanks for following up! I totally understand swapping to a non-root user is a non-trivial change and can cause havoc if done without care.
Feature Request
Modify the Dockerfile that builds the release image to utilize a non-root user.
Background
Use of pgadapter is being flagged by cloud security vulnerability scans due to the main process running as root. Running containers as a non-root user is also a generally accepted security practice.
Possible Solutions
With the existing image (eclipse-temurin), utilize standard patterns to create a non-root user and use that non-root user as the executor.
Convert to distroless images, similarly to how cloud-sql-proxy is built.