This rule encourages the use of the SHELL instruction to explicitly change the default shell in a Dockerfile rather than modifying it indirectly through commands like RUN ln -sfv /bin/bash /bin/sh. Using SHELL provides a clear and declarative way to specify which shell should be used for subsequent instructions, improving readability and maintainability.
To comply with this rule, replace any commands that attempt to change the default shell indirectly, such as RUN ln -sfv /bin/bash /bin/sh, with the SHELL instruction like SHELL ["/bin/bash", "-c"]. This approach keeps your Dockerfile clean and ensures consistent execution of shell commands.