---
type: resource-type
title: Dockerfile
description: A Dockerfile definition with ordered build instructions
name: Dockerfile
lexicon: docker
resource_type: Docker::Dockerfile
---
A Dockerfile definition with ordered build instructions

## Properties

- `from`: Base image (required first instruction)
- `arg`: Build-time argument
- `env`: Environment variable
- `run`: Run a command during build
- `copy`: Copy files from build context
- `add`: Add files (supports URLs and archives)
- `workdir`: Set working directory
- `user`: Set user for subsequent instructions
- `expose`: Document exposed ports
- `volume`: Create mount points
- `label`: Add metadata labels
- `entrypoint`: Set the entrypoint executable
- `cmd`: Default command arguments
- `healthcheck`: Health check instruction

## Governed by

- [DKRD012](/rules/DKRD012.md): Dockerfile has no USER instruction — container runs as root
