8.4 使用.dockerignore文件

可以通过.dockerignore文件(每一行添加一条匹配模式)来让Docker忽略匹配模式路径下的目录和文件。例如:


  1. # comment
  2. */temp*
  3. */*/temp*
  4. tmp?
  5. ~*