instruction: Create a Dockerfile for Nginx with production best practices
output: ```dockerfile
  from Env or as a command argument.
  Since the Service name may change as namePrefix or nameSuffix is added in the kustomization.yaml file. It is
  not recommended to hard code the Service name in the command argument. For this usage, Kustomize can inject
  the Service name into containers through replacements.# Create a deployment.yaml file (quoting the here doc delimiter)
  cat <<'EOF' > deployment.yaml
  apiVersion: apps/v1
  kind: Deployment
  metadata:
   name: my-nginx
  spec:
   selector:
   matchLabels:
   run: my-nginx
   replicas: 2
   template:
   metadata:
   labels:
   run: my-nginx
   spec:
   containers:
   - name: my-nginx
   image: nginx
   command: ["start", "--host", "MY_SERVICE_NAME_PLACEHOLDER"]
  EOF
  
  # Create a service.yaml file
  cat <<EOF > service.yaml
  apiVersion: v1
  kind: Service
  metadata:
   name: my-nginx
   labels:
   run: my-nginx
  spec:
   ports:
   - port: 80
   protocol: TCP
   selector:
   run: my-nginx
  EOF
  
  cat <<EOF >./kustomization.yaml
  namePrefix: dev-
  nameSuffix: "-001"
  
  resources:
  - deployment.yaml
  - service.yaml
  
  replacements:
  - source:
   kind: Service
   name: my-nginx
   fieldPath: metadata.name
   targets:
   - select:
   kind: Deployment
   name: my-nginx
   fieldPaths:
   - spec.template.spec.containers.0.command.2
  EOF
  Run kubectl kustomize ./ to see that the Service name injected into containers is dev-my-nginx-001:apiVersion: apps/v1
  kind: Deployment
  metadata:
   name: dev-my-nginx-001
  spec:
   replicas: 2
   selector:
   matchLabels:
   run: my-nginx
   template:
   metadata:
   labels:
   run: my-nginx
   spec:
   containers:
   - command:
   - start
   - --host
   - dev-my-nginx-001
   image: nginx
   name: my-nginx
  Bases and OverlaysKustomize has the concepts of bases and overlays. A base is a directory with a kustomization.yaml, which contains a
  set of resources and associated customization. A base could be either a local directory or a directory
  ```