chainguard-dev / chainguard-dev/dfc
-D flag needed when converting between Dockerfile that uses useradd to one that uses adduser
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 103
- Forks
- 29
- PR merge metrics
- No merged PRs in 30d
Description
Starting with a Debian-based Dockerfile, I ran dfc to convert it and this line:
RUN useradd -m -s /bin/bash appuser
was changed to:
RUN adduser --shell /bin/bash appuser
However, without manually adding -D building the image will fail as follows:
RUN adduser --shell /bin/bash appuser:
0.131 passwd: password for appuser is unchanged
0.131 Changing password for appuser
0.131 New password:
whereupon the job does not complete successfully. The -D allows useradd to not assign a password and the build completes properly.
The request is for the dfc tool to insert the -D flag when converting to adduser syntax.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue does not name a file or test; locate the Dockerfile conversion rule that changes useradd to adduser and find its existing test coverage. Reproduce the Debian-based example, then verify the converted command includes -D and that the relevant conversion tests pass.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- dockerfile, go
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 50/100