Skip to content

Files

Latest commit

 

History

History
25 lines (16 loc) · 603 Bytes

DL3038.md

File metadata and controls

25 lines (16 loc) · 603 Bytes

Pattern: Missing -y for dnf install -y <package>

Issue: -

Description

Omitting the non-interactive switch causes the command to fail during the build process, because dnf would expect manual input. Use the -y or the equivalent --assumeyes flag to avoid this.

Example of incorrect code:

FROM fedora:32
RUN dnf install httpd-2.4.46 && dnf clean all

Example of correct code:

FROM fedora:32
RUN dnf install -y httpd-2.4.46 && dnf clean all

Further Reading