The rule stipulates that all Dockerfiles must specify a base image. This is important because without specifying a base image, you are building a container from scratch, and this is likely what is not intended.
To avoid violating this rule, always declare a base image at the start of your Dockerfile using the FROM keyword. For example, FROM ubuntu:18.04 sets the base image to Ubuntu 18.04.
Non-Compliant Code Examples
RUNecho"hello"
Compliant Code Examples
FROMimageasbase# fooFROMimage2
シームレスな統合。 Datadog Code Security をお試しください
Datadog Code Security
このルールを試し、Datadog Code Security でコードを解析する
このルールの使用方法
1
2
rulesets:- docker-best-practices # Rules to enforce Docker best practices.