full-dress-10026
11/30/2018, 3:07 AMDockerBuild.cacheFrom
docs say this:
/**
* An optional CacheFrom object with information about the build stages to use for the Docker
* build cache. This parameter maps to the --cache-from argument to the Docker CLI. If this
* parameter is `true`, only the final image will be pulled and passed to --cache-from; if it is
* a CacheFrom object, the stages named therein will also be pulled and passed to --cache-from.
*/
What does this mean "If this parameter is true
, only the final image will be pulled and passed to --cache-from"?white-balloon-205
—cache-from
in docker is to only cache the final stage (if you are using multi-stage builds). So if you pass true
here you get that behavior. But if you also want to cache other stages (which in general you do if you are sensitive to build caching performance), then you can specify stage names to cache in the CacheFrom object.full-dress-10026
11/30/2018, 4:18 AMlemon-spoon-91807
11/30/2018, 7:16 PMfull-dress-10026
11/30/2018, 7:19 PMthe FS stays the sameDoes this take into account the last modified timestamps of files? Or simply the contents of the files?
lemon-spoon-91807
11/30/2018, 8:04 PMfull-dress-10026
11/30/2018, 8:04 PMlemon-spoon-91807
11/30/2018, 8:05 PMfull-dress-10026
12/05/2018, 4:37 PMpulumi up
with no changes takes 35s, mostly due to the Docker builds. If you could detect no FS changes and skip the Docker build, I bet that number would be closer to 10s.