1. 06 Nov, 2018 1 commit
  2. 05 Nov, 2018 6 commits
    • Luke Patterson's avatar
      Update README.md · ddc287ce
      Luke Patterson authored
      ddc287ce
    • Luke Patterson's avatar
      Update README.md · 663d5811
      Luke Patterson authored
      663d5811
    • Luke Patterson's avatar
      add readme · ee3dafda
      Luke Patterson authored
      ee3dafda
    • Luke Patterson's avatar
      $ docker build --tag layers-blog:step-3-change-app-layer . · cc477c20
      Luke Patterson authored
      ...
      Step 9/24 : WORKDIR ./layers-blog-snapshot-dependency/
       ---> Using cache
       ---> 2a285b6ceb7c
      Step 10/24 : COPY ./layers-blog-snapshot-dependency/ ./
       ---> Using cache
       ---> 54757dae4545
      Step 11/24 : RUN mvn install --quiet --update-snapshots --strict-checksums --batch-mode
       ---> Using cache
       ---> 2743ddf8ee9b
      Step 12/24 : WORKDIR ../layers-blog-app/
       ---> Using cache
       ---> 5c31fb7b9ddd
      Step 13/24 : COPY layers-blog-app ./
       ---> 890b7b0c87c4
      Step 14/24 : RUN mvn package --quiet --update-snapshots --strict-checksums --batch-mode
       ---> a7930160b75a
      Step 15/24 : WORKDIR ./target/
       ---> 2fc82e121578
      Step 16/24 : RUN unzip -q *.jar -d ./unzipped/     && tree ./unzipped/     && mkdir --parents /layers/3-app/BOOT-INF/     && mv ./unzipped/BOOT-INF/classes/ /layers/3-app/BOOT-INF/     && mv ./unzipped/META-INF/ /layers/3-app/     && mkdir --parents /layers/2-dependencies-snapshot/BOOT-INF/lib/     && find ./unzipped/BOOT-INF/lib/ -type f -name '*-SNAPSHOT.jar' -exec mv {} /layers/2-dependencies-snapshot/BOOT-INF/lib/ ';'     && mv ./unzipped/ /layers/1-dependencies-release/     && tree /layers/
      ./unzipped/
      ├── BOOT-INF
      │   ├── classes
      │   │   ├── application.properties
      │   │   └── org
      │   │       └── lukewpatterson
      │   │           └── layers
      │   │               └── blog
      │   │                   └── app
      │   │                       └── OurSpringBootApplication.class
      │   └── lib
      │       ├── classmate-1.3.4.jar
      │       ├── gson-2.8.5.jar
      │       ├── hibernate-validator-6.0.12.Final.jar
      │       ├── jackson-annotations-2.9.0.jar
      │       ├── jackson-core-2.9.6.jar
      │       ├── jackson-databind-2.9.6.jar
      │       ├── jackson-datatype-jdk8-2.9.6.jar
      │       ├── jackson-datatype-jsr310-2.9.6.jar
      │       ├── jackson-module-parameter-names-2.9.6.jar
      │       ├── javax.annotation-api-1.3.2.jar
      │       ├── jboss-logging-3.3.2.Final.jar
      │       ├── jul-to-slf4j-1.7.25.jar
      │       ├── layers-blog-snapshot-dependency-1-SNAPSHOT.jar
      │       ├── log4j-api-2.10.0.jar
      │       ├── log4j-to-slf4j-2.10.0.jar
      │       ├── logback-classic-1.2.3.jar
      │       ├── logback-core-1.2.3.jar
      │       ├── slf4j-api-1.7.25.jar
      │       ├── snakeyaml-1.19.jar
      │       ├── spring-aop-5.0.9.RELEASE.jar
      │       ├── spring-beans-5.0.9.RELEASE.jar
      │       ├── spring-boot-2.0.5.RELEASE.jar
      │       ├── spring-boot-autoconfigure-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-json-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-logging-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-tomcat-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-web-2.0.5.RELEASE.jar
      │       ├── spring-context-5.0.9.RELEASE.jar
      │       ├── spring-core-5.0.9.RELEASE.jar
      │       ├── spring-expression-5.0.9.RELEASE.jar
      │       ├── spring-jcl-5.0.9.RELEASE.jar
      │       ├── spring-web-5.0.9.RELEASE.jar
      │       ├── spring-webmvc-5.0.9.RELEASE.jar
      │       ├── tomcat-embed-core-8.5.34.jar
      │       ├── tomcat-embed-el-8.5.34.jar
      │       ├── tomcat-embed-websocket-8.5.34.jar
      │       └── validation-api-2.0.1.Final.jar
      ├── META-INF
      │   ├── MANIFEST.MF
      │   └── maven
      │       └── org.lukewpatterson
      │           └── layers-blog-app
      │               ├── pom.properties
      │               └── pom.xml
      └── org
          └── springframework
              └── boot
                  └── loader
                      ├── ExecutableArchiveLauncher.class
                      ├── JarLauncher.class
                      ├── LaunchedURLClassLoader$UseFastConnectionExceptionsEnumeration.class
                      ├── LaunchedURLClassLoader.class
                      ├── Launcher.class
                      ├── MainMethodRunner.class
                      ├── PropertiesLauncher$1.class
                      ├── PropertiesLauncher$ArchiveEntryFilter.class
                      ├── PropertiesLauncher$PrefixMatchingArchiveFilter.class
                      ├── PropertiesLauncher.class
                      ├── WarLauncher.class
                      ├── archive
                      │   ├── Archive$Entry.class
                      │   ├── Archive$EntryFilter.class
                      │   ├── Archive.class
                      │   ├── ExplodedArchive$1.class
                      │   ├── ExplodedArchive$FileEntry.class
                      │   ├── ExplodedArchive$FileEntryIterator$EntryComparator.class
                      │   ├── ExplodedArchive$FileEntryIterator.class
                      │   ├── ExplodedArchive.class
                      │   ├── JarFileArchive$EntryIterator.class
                      │   ├── JarFileArchive$JarFileEntry.class
                      │   └── JarFileArchive.class
                      ├── data
                      │   ├── RandomAccessData.class
                      │   ├── RandomAccessDataFile$1.class
                      │   ├── RandomAccessDataFile$DataInputStream.class
                      │   ├── RandomAccessDataFile$FileAccess.class
                      │   └── RandomAccessDataFile.class
                      ├── jar
                      │   ├── AsciiBytes.class
                      │   ├── Bytes.class
                      │   ├── CentralDirectoryEndRecord.class
                      │   ├── CentralDirectoryFileHeader.class
                      │   ├── CentralDirectoryParser.class
                      │   ├── CentralDirectoryVisitor.class
                      │   ├── FileHeader.class
                      │   ├── Handler.class
                      │   ├── JarEntry.class
                      │   ├── JarEntryFilter.class
                      │   ├── JarFile$1.class
                      │   ├── JarFile$2.class
                      │   ├── JarFile$JarFileType.class
                      │   ├── JarFile.class
                      │   ├── JarFileEntries$1.class
                      │   ├── JarFileEntries$EntryIterator.class
                      │   ├── JarFileEntries.class
                      │   ├── JarURLConnection$1.class
                      │   ├── JarURLConnection$JarEntryName.class
                      │   ├── JarURLConnection.class
                      │   ├── StringSequence.class
                      │   └── ZipInflaterInputStream.class
                      └── util
                          └── SystemPropertyUtils.class
      
      20 directories, 93 files
      /layers/
      ├── 1-dependencies-release
      │   ├── BOOT-INF
      │   │   └── lib
      │   │       ├── classmate-1.3.4.jar
      │   │       ├── gson-2.8.5.jar
      │   │       ├── hibernate-validator-6.0.12.Final.jar
      │   │       ├── jackson-annotations-2.9.0.jar
      │   │       ├── jackson-core-2.9.6.jar
      │   │       ├── jackson-databind-2.9.6.jar
      │   │       ├── jackson-datatype-jdk8-2.9.6.jar
      │   │       ├── jackson-datatype-jsr310-2.9.6.jar
      │   │       ├── jackson-module-parameter-names-2.9.6.jar
      │   │       ├── javax.annotation-api-1.3.2.jar
      │   │       ├── jboss-logging-3.3.2.Final.jar
      │   │       ├── jul-to-slf4j-1.7.25.jar
      │   │       ├── log4j-api-2.10.0.jar
      │   │       ├── log4j-to-slf4j-2.10.0.jar
      │   │       ├── logback-classic-1.2.3.jar
      │   │       ├── logback-core-1.2.3.jar
      │   │       ├── slf4j-api-1.7.25.jar
      │   │       ├── snakeyaml-1.19.jar
      │   │       ├── spring-aop-5.0.9.RELEASE.jar
      │   │       ├── spring-beans-5.0.9.RELEASE.jar
      │   │       ├── spring-boot-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-autoconfigure-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-json-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-logging-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-tomcat-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-web-2.0.5.RELEASE.jar
      │   │       ├── spring-context-5.0.9.RELEASE.jar
      │   │       ├── spring-core-5.0.9.RELEASE.jar
      │   │       ├── spring-expression-5.0.9.RELEASE.jar
      │   │       ├── spring-jcl-5.0.9.RELEASE.jar
      │   │       ├── spring-web-5.0.9.RELEASE.jar
      │   │       ├── spring-webmvc-5.0.9.RELEASE.jar
      │   │       ├── tomcat-embed-core-8.5.34.jar
      │   │       ├── tomcat-embed-el-8.5.34.jar
      │   │       ├── tomcat-embed-websocket-8.5.34.jar
      │   │       └── validation-api-2.0.1.Final.jar
      │   └── org
      │       └── springframework
      │           └── boot
      │               └── loader
      │                   ├── ExecutableArchiveLauncher.class
      │                   ├── JarLauncher.class
      │                   ├── LaunchedURLClassLoader$UseFastConnectionExceptionsEnumeration.class
      │                   ├── LaunchedURLClassLoader.class
      │                   ├── Launcher.class
      │                   ├── MainMethodRunner.class
      │                   ├── PropertiesLauncher$1.class
      │                   ├── PropertiesLauncher$ArchiveEntryFilter.class
      │                   ├── PropertiesLauncher$PrefixMatchingArchiveFilter.class
      │                   ├── PropertiesLauncher.class
      │                   ├── WarLauncher.class
      │                   ├── archive
      │                   │   ├── Archive$Entry.class
      │                   │   ├── Archive$EntryFilter.class
      │                   │   ├── Archive.class
      │                   │   ├── ExplodedArchive$1.class
      │                   │   ├── ExplodedArchive$FileEntry.class
      │                   │   ├── ExplodedArchive$FileEntryIterator$EntryComparator.class
      │                   │   ├── ExplodedArchive$FileEntryIterator.class
      │                   │   ├── ExplodedArchive.class
      │                   │   ├── JarFileArchive$EntryIterator.class
      │                   │   ├── JarFileArchive$JarFileEntry.class
      │                   │   └── JarFileArchive.class
      │                   ├── data
      │                   │��  ├── RandomAccessData.class
      │                   │   ├── RandomAccessDataFile$1.class
      │                   │   ├── RandomAccessDataFile$DataInputStream.class
      │                   │   ├── RandomAccessDataFile$FileAccess.class
      │                   │   └── RandomAccessDataFile.class
      │                   ├── jar
      │                   │   ├── AsciiBytes.class
      │                   │   ├── Bytes.class
      │                   │   ├── CentralDirectoryEndRecord.class
      │                   │   ├── CentralDirectoryFileHeader.class
      │                   │   ├── CentralDirectoryParser.class
      │                   │   ├── CentralDirectoryVisitor.class
      │                   │   ├── FileHeader.class
      │                   │   ├── Handler.class
      │                   │   ├── JarEntry.class
      │                   │   ├── JarEntryFilter.class
      │                   │   ├── JarFile$1.class
      │                   │   ├── JarFile$2.class
      │                   │   ├── JarFile$JarFileType.class
      │                   │   ├── JarFile.class
      │                   │   ├── JarFileEntries$1.class
      │                   │   ├── JarFileEntries$EntryIterator.class
      │                   │   ├── JarFileEntries.class
      │                   │   ├── JarURLConnection$1.class
      │                   │   ├── JarURLConnection$JarEntryName.class
      │                   │   ├── JarURLConnection.class
      │                   │   ├── StringSequence.class
      │                   │   └── ZipInflaterInputStream.class
      │                   └── util
      │                       └── SystemPropertyUtils.class
      ├── 2-dependencies-snapshot
      │   └── BOOT-INF
      │       └── lib
      │           └── layers-blog-snapshot-dependency-1-SNAPSHOT.jar
      └── 3-app
          ├── BOOT-INF
          │   └── classes
          │       ├── application.properties
          │       └── org
          │           └── lukewpatterson
          │               └── layers
          │                   └── blog
          │                       └── app
          │                           └── OurSpringBootApplication.class
          └── META-INF
              ├── MANIFEST.MF
              └── maven
                  └── org.lukewpatterson
                      └── layers-blog-app
                          ├── pom.properties
                          └── pom.xml
      
      26 directories, 93 files
      
      ...
      Step 19/24 : WORKDIR /app/
       ---> Using cache
       ---> e83ac4cda8f7
      Step 20/24 : COPY --from=build /layers/1-dependencies-release/ ./
       ---> Using cache
       ---> a5f34ee04615
      Step 21/24 : COPY --from=build /layers/2-dependencies-snapshot/ ./
       ---> Using cache
       ---> 7446b0325602
      Step 22/24 : COPY --from=build /layers/3-app/ ./
       ---> 70d1d9f84c14
      Step 23/24 : RUN tree
      .
      ├── BOOT-INF
      │   ├── classes
      │   │   ├── application.properties
      │   │   └── org
      │   │       └── lukewpatterson
      │   │           └── layers
      │   │               └── blog
      │   │                   └── app
      │   │                       └── OurSpringBootApplication.class
      │   └── lib
      │       ├── classmate-1.3.4.jar
      │       ├── gson-2.8.5.jar
      │       ├── hibernate-validator-6.0.12.Final.jar
      │       ├── jackson-annotations-2.9.0.jar
      │       ├── jackson-core-2.9.6.jar
      │       ├── jackson-databind-2.9.6.jar
      │       ├── jackson-datatype-jdk8-2.9.6.jar
      │       ├── jackson-datatype-jsr310-2.9.6.jar
      │       ├── jackson-module-parameter-names-2.9.6.jar
      │       ├── javax.annotation-api-1.3.2.jar
      │       ├── jboss-logging-3.3.2.Final.jar
      │       ├── jul-to-slf4j-1.7.25.jar
      │       ├── layers-blog-snapshot-dependency-1-SNAPSHOT.jar
      │       ├── log4j-api-2.10.0.jar
      │       ├── log4j-to-slf4j-2.10.0.jar
      │       ├── logback-classic-1.2.3.jar
      │       ├── logback-core-1.2.3.jar
      │       ├── slf4j-api-1.7.25.jar
      │       ├── snakeyaml-1.19.jar
      │       ├── spring-aop-5.0.9.RELEASE.jar
      │       ├── spring-beans-5.0.9.RELEASE.jar
      │       ├── spring-boot-2.0.5.RELEASE.jar
      │       ├── spring-boot-autoconfigure-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-json-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-logging-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-tomcat-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-web-2.0.5.RELEASE.jar
      │       ├── spring-context-5.0.9.RELEASE.jar
      │       ├── spring-core-5.0.9.RELEASE.jar
      │       ├── spring-expression-5.0.9.RELEASE.jar
      │       ├── spring-jcl-5.0.9.RELEASE.jar
      │       ├── spring-web-5.0.9.RELEASE.jar
      │       ├── spring-webmvc-5.0.9.RELEASE.jar
      │       ├── tomcat-embed-core-8.5.34.jar
      │       ├── tomcat-embed-el-8.5.34.jar
      │       ├── tomcat-embed-websocket-8.5.34.jar
      │       └── validation-api-2.0.1.Final.jar
      ├── META-INF
      │   ├── MANIFEST.MF
      │   └── maven
      │       └── org.lukewpatterson
      │           └── layers-blog-app
      │               ├── pom.properties
      │               └── pom.xml
      └── org
          └── springframework
              └── boot
                  └── loader
                      ├── ExecutableArchiveLauncher.class
                      ├── JarLauncher.class
                      ├── LaunchedURLClassLoader$UseFastConnectionExceptionsEnumeration.class
                      ├── LaunchedURLClassLoader.class
                      ├── Launcher.class
                      ├── MainMethodRunner.class
                      ├── PropertiesLauncher$1.class
                      ├── PropertiesLauncher$ArchiveEntryFilter.class
                      ├── PropertiesLauncher$PrefixMatchingArchiveFilter.class
                      ├── PropertiesLauncher.class
                      ├── WarLauncher.class
                      ├── archive
                      │   ├── Archive$Entry.class
                      │   ├── Archive$EntryFilter.class
                      │   ├── Archive.class
                      │   ├── ExplodedArchive$1.class
                      │   ├── ExplodedArchive$FileEntry.class
                      │   ├── ExplodedArchive$FileEntryIterator$EntryComparator.class
                      │   ├── ExplodedArchive$FileEntryIterator.class
                      │   ├── ExplodedArchive.class
                      │   ├── JarFileArchive$EntryIterator.class
                      │   ├── JarFileArchive$JarFileEntry.class
                      │   └── JarFileArchive.class
                      ├── data
                      │   ├── RandomAccessData.class
                      │   ├── RandomAccessDataFile$1.class
                      │   ├── RandomAccessDataFile$DataInputStream.class
                      │   ├── RandomAccessDataFile$FileAccess.class
                      │   └── RandomAccessDataFile.class
                      ├── jar
                      │   ├── AsciiBytes.class
                      │   ├── Bytes.class
                      │   ├── CentralDirectoryEndRecord.class
                      │   ├── CentralDirectoryFileHeader.class
                      │   ├── CentralDirectoryParser.class
                      │   ├── CentralDirectoryVisitor.class
                      │   ├── FileHeader.class
                      │   ├── Handler.class
                      │   ├── JarEntry.class
                      │   ├── JarEntryFilter.class
                      │   ├── JarFile$1.class
                      │   ├── JarFile$2.class
                      │   ├── JarFile$JarFileType.class
                      │   ├── JarFile.class
                      │   ├── JarFileEntries$1.class
                      │   ├── JarFileEntries$EntryIterator.class
                      │   ├── JarFileEntries.class
                      │   ├── JarURLConnection$1.class
                      │   ├── JarURLConnection$JarEntryName.class
                      │   ├── JarURLConnection.class
                      │   ├── StringSequence.class
                      │   └── ZipInflaterInputStream.class
                      └── util
                          └── SystemPropertyUtils.class
      
      20 directories, 93 files
       ---> 37972d46e4a0
      Step 24/24 : CMD ["java", "org.springframework.boot.loader.JarLauncher"]
       ---> fbec5480507f
      Successfully built fbec5480507f
      Successfully tagged layers-blog:step-3-change-app-layer
      --------------------------------------------------------------------------------------------------------------
      $ container-diff diff daemon://layers-blog:step-2-change-dependencies-snapshot-layer daemon://layers-blog:step-3-change-app-layer --type=size --type=file
      
      -----File-----
      
      These entries have been added to layers-blog:step-2-change-dependencies-snapshot-layer: None
      
      These entries have been deleted from layers-blog:step-2-change-dependencies-snapshot-layer: None
      
      These entries have been changed between layers-blog:step-2-change-dependencies-snapshot-layer and layers-blog:step-3-change-app-layer:
      FILE                                                                                           SIZE1        SIZE2
      /app/BOOT-INF/classes/org/lukewpatterson/layers/blog/app/OurSpringBootApplication.class        1.3K         1.3K
      
      -----Size-----
      
      Image size difference between layers-blog:step-2-change-dependencies-snapshot-layer and layers-blog:step-3-change-app-layer: None
      cc477c20
    • Luke Patterson's avatar
      $ docker build --tag layers-blog:step-2-change-dependencies-snapshot-layer . · c3e137b7
      Luke Patterson authored
      ...
      Step 9/24 : WORKDIR ./layers-blog-snapshot-dependency/
       ---> Using cache
       ---> 2a285b6ceb7c
      Step 10/24 : COPY ./layers-blog-snapshot-dependency/ ./
       ---> 54757dae4545
      Step 11/24 : RUN mvn install --quiet --update-snapshots --strict-checksums --batch-mode
       ---> 2743ddf8ee9b
      Step 12/24 : WORKDIR ../layers-blog-app/
       ---> 5c31fb7b9ddd
      Step 13/24 : COPY layers-blog-app ./
       ---> 4facffd4d96f
      Step 14/24 : RUN mvn package --quiet --update-snapshots --strict-checksums --batch-mode
       ---> c090d20a7b9e
      Step 15/24 : WORKDIR ./target/
       ---> 8017d67e823c
      Step 16/24 : RUN unzip -q *.jar -d ./unzipped/     && tree ./unzipped/     && mkdir --parents /layers/3-app/BOOT-INF/     && mv ./unzipped/BOOT-INF/classes/ /layers/3-app/BOOT-INF/     && mv ./unzipped/META-INF/ /layers/3-app/     && mkdir --parents /layers/2-dependencies-snapshot/BOOT-INF/lib/     && find ./unzipped/BOOT-INF/lib/ -type f -name '*-SNAPSHOT.jar' -exec mv {} /layers/2-dependencies-snapshot/BOOT-INF/lib/ ';'     && mv ./unzipped/ /layers/1-dependencies-release/     && tree /layers/
      ./unzipped/
      ├── BOOT-INF
      │   ├── classes
      │   │   ├── application.properties
      │   │   └── org
      │   │       └── lukewpatterson
      │   │           └── layers
      │   │               └── blog
      │   │                   └── app
      │   │                       └── OurSpringBootApplication.class
      │   └── lib
      │       ├── classmate-1.3.4.jar
      │       ├── gson-2.8.5.jar
      │       ├── hibernate-validator-6.0.12.Final.jar
      │       ├── jackson-annotations-2.9.0.jar
      │       ├── jackson-core-2.9.6.jar
      │       ├── jackson-databind-2.9.6.jar
      │       ├── jackson-datatype-jdk8-2.9.6.jar
      │       ├── jackson-datatype-jsr310-2.9.6.jar
      │       ├── jackson-module-parameter-names-2.9.6.jar
      │       ├── javax.annotation-api-1.3.2.jar
      │       ├── jboss-logging-3.3.2.Final.jar
      │       ├── jul-to-slf4j-1.7.25.jar
      │       ├── layers-blog-snapshot-dependency-1-SNAPSHOT.jar
      │       ├── log4j-api-2.10.0.jar
      │       ├── log4j-to-slf4j-2.10.0.jar
      │       ├── logback-classic-1.2.3.jar
      │       ├── logback-core-1.2.3.jar
      │       ├── slf4j-api-1.7.25.jar
      │       ├── snakeyaml-1.19.jar
      │       ├── spring-aop-5.0.9.RELEASE.jar
      │       ├── spring-beans-5.0.9.RELEASE.jar
      │       ├── spring-boot-2.0.5.RELEASE.jar
      │       ├── spring-boot-autoconfigure-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-json-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-logging-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-tomcat-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-web-2.0.5.RELEASE.jar
      │       ├── spring-context-5.0.9.RELEASE.jar
      │       ├── spring-core-5.0.9.RELEASE.jar
      │       ├── spring-expression-5.0.9.RELEASE.jar
      │       ├── spring-jcl-5.0.9.RELEASE.jar
      │       ├── spring-web-5.0.9.RELEASE.jar
      │       ├── spring-webmvc-5.0.9.RELEASE.jar
      │       ├── tomcat-embed-core-8.5.34.jar
      │       ├── tomcat-embed-el-8.5.34.jar
      │       ├── tomcat-embed-websocket-8.5.34.jar
      │       └── validation-api-2.0.1.Final.jar
      ├── META-INF
      │   ├── MANIFEST.MF
      │   └── maven
      │       └── org.lukewpatterson
      │           └── layers-blog-app
      │               ├── pom.properties
      │               └── pom.xml
      └── org
          └── springframework
              └── boot
                  └── loader
                      ├── ExecutableArchiveLauncher.class
                      ├── JarLauncher.class
                      ├── LaunchedURLClassLoader$UseFastConnectionExceptionsEnumeration.class
                      ├── LaunchedURLClassLoader.class
                      ├── Launcher.class
                      ├── MainMethodRunner.class
                      ├── PropertiesLauncher$1.class
                      ├── PropertiesLauncher$ArchiveEntryFilter.class
                      ├── PropertiesLauncher$PrefixMatchingArchiveFilter.class
                      ├── PropertiesLauncher.class
                      ├── WarLauncher.class
                      ├── archive
                      │   ├── Archive$Entry.class
                      │   ├── Archive$EntryFilter.class
                      │   ├── Archive.class
                      │   ├── ExplodedArchive$1.class
                      │   ├── ExplodedArchive$FileEntry.class
                      │   ├── ExplodedArchive$FileEntryIterator$EntryComparator.class
                      │   ├── ExplodedArchive$FileEntryIterator.class
                      │   ├── ExplodedArchive.class
                      │   ├── JarFileArchive$EntryIterator.class
                      │   ├── JarFileArchive$JarFileEntry.class
                      │   └── JarFileArchive.class
                      ├── data
                      │   ├── RandomAccessData.class
                      │   ├── RandomAccessDataFile$1.class
                      │   ├── RandomAccessDataFile$DataInputStream.class
                      │   ├── RandomAccessDataFile$FileAccess.class
                      │   └── RandomAccessDataFile.class
                      ├── jar
                      │   ├── AsciiBytes.class
                      │   ├── Bytes.class
                      │   ├── CentralDirectoryEndRecord.class
                      │   ├── CentralDirectoryFileHeader.class
                      │   ├── CentralDirectoryParser.class
                      │   ├── CentralDirectoryVisitor.class
                      │   ├── FileHeader.class
                      │   ├── Handler.class
                      │   ├── JarEntry.class
                      │   ├── JarEntryFilter.class
                      │   ├── JarFile$1.class
                      │   ├── JarFile$2.class
                      │   ├── JarFile$JarFileType.class
                      │   ├── JarFile.class
                      │   ├── JarFileEntries$1.class
                      │   ├── JarFileEntries$EntryIterator.class
                      │   ├── JarFileEntries.class
                      │   ├── JarURLConnection$1.class
                      │   ├── JarURLConnection$JarEntryName.class
                      │   ├── JarURLConnection.class
                      │   ├── StringSequence.class
                      │   └── ZipInflaterInputStream.class
                      └── util
                          └── SystemPropertyUtils.class
      
      20 directories, 93 files
      /layers/
      ├── 1-dependencies-release
      │   ├── BOOT-INF
      │   │   └── lib
      │   │       ├── classmate-1.3.4.jar
      │   │       ├── gson-2.8.5.jar
      │   │       ├── hibernate-validator-6.0.12.Final.jar
      │   │       ├── jackson-annotations-2.9.0.jar
      │   │       ├── jackson-core-2.9.6.jar
      │   │       ├── jackson-databind-2.9.6.jar
      │   │       ├── jackson-datatype-jdk8-2.9.6.jar
      │   │       ├── jackson-datatype-jsr310-2.9.6.jar
      │   │       ├── jackson-module-parameter-names-2.9.6.jar
      │   │       ├── javax.annotation-api-1.3.2.jar
      │   │       ├── jboss-logging-3.3.2.Final.jar
      │   │       ├── jul-to-slf4j-1.7.25.jar
      │   │       ├── log4j-api-2.10.0.jar
      │   │       ├── log4j-to-slf4j-2.10.0.jar
      │   │       ├── logback-classic-1.2.3.jar
      │   │       ├── logback-core-1.2.3.jar
      │   │       ├── slf4j-api-1.7.25.jar
      │   │       ├── snakeyaml-1.19.jar
      │   │       ├── spring-aop-5.0.9.RELEASE.jar
      │   │       ├── spring-beans-5.0.9.RELEASE.jar
      │   │       ├── spring-boot-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-autoconfigure-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-json-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-logging-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-tomcat-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-web-2.0.5.RELEASE.jar
      │   │       ├── spring-context-5.0.9.RELEASE.jar
      │   │       ├── spring-core-5.0.9.RELEASE.jar
      │   │       ├── spring-expression-5.0.9.RELEASE.jar
      │   │       ├── spring-jcl-5.0.9.RELEASE.jar
      │   │       ├── spring-web-5.0.9.RELEASE.jar
      │   │       ├── spring-webmvc-5.0.9.RELEASE.jar
      │   │       ├── tomcat-embed-core-8.5.34.jar
      │   │       ├── tomcat-embed-el-8.5.34.jar
      │   │       ├── tomcat-embed-websocket-8.5.34.jar
      │   │       └── validation-api-2.0.1.Final.jar
      │   └── org
      │       └── springframework
      │           └── boot
      │               └── loader
      │                   ├── ExecutableArchiveLauncher.class
      │                   ├── JarLauncher.class
      │                   ├── LaunchedURLClassLoader$UseFastConnectionExceptionsEnumeration.class
      │                   ├── LaunchedURLClassLoader.class
      │                   ├── Launcher.class
      │                   ├── MainMethodRunner.class
      │                   ├── PropertiesLauncher$1.class
      │                   ├── PropertiesLauncher$ArchiveEntryFilter.class
      │                   ├── PropertiesLauncher$PrefixMatchingArchiveFilter.class
      │                   ├── PropertiesLauncher.class
      │                   ├── WarLauncher.class
      │                   ├── archive
      │                   │   ├── Archive$Entry.class
      │                   │   ├── Archive$EntryFilter.class
      │                   │   ├── Archive.class
      │                   │   ├── ExplodedArchive$1.class
      │                   │   ├── ExplodedArchive$FileEntry.class
      │                   │   ├── ExplodedArchive$FileEntryIterator$EntryComparator.class
      │                   │   ├── ExplodedArchive$FileEntryIterator.class
      │                   │   ├── ExplodedArchive.class
      │                   │   ├── JarFileArchive$EntryIterator.class
      │                   │   ├── JarFileArchive$JarFileEntry.class
      │                   │   └── JarFileArchive.class
      │                   ├── data
      │                   │��  ├── RandomAccessData.class
      │                   │   ├── RandomAccessDataFile$1.class
      │                   │   ├── RandomAccessDataFile$DataInputStream.class
      │                   │   ├── RandomAccessDataFile$FileAccess.class
      │                   │   └── RandomAccessDataFile.class
      │                   ├── jar
      │                   │   ├── AsciiBytes.class
      │                   │   ├── Bytes.class
      │                   │   ├── CentralDirectoryEndRecord.class
      │                   │   ├── CentralDirectoryFileHeader.class
      │                   │   ├── CentralDirectoryParser.class
      │                   │   ├── CentralDirectoryVisitor.class
      │                   │   ├── FileHeader.class
      │                   │   ├── Handler.class
      │                   │   ├── JarEntry.class
      │                   │   ├── JarEntryFilter.class
      │                   │   ├── JarFile$1.class
      │                   │   ├── JarFile$2.class
      │                   │   ├── JarFile$JarFileType.class
      │                   │   ├── JarFile.class
      │                   │   ├── JarFileEntries$1.class
      │                   │   ├── JarFileEntries$EntryIterator.class
      │                   │   ├── JarFileEntries.class
      │                   │   ├── JarURLConnection$1.class
      │                   │   ├── JarURLConnection$JarEntryName.class
      │                   │   ├── JarURLConnection.class
      │                   │   ├── StringSequence.class
      │                   │   └── ZipInflaterInputStream.class
      │                   └── util
      │                       └── SystemPropertyUtils.class
      ├── 2-dependencies-snapshot
      │   └── BOOT-INF
      │       └── lib
      │           └── layers-blog-snapshot-dependency-1-SNAPSHOT.jar
      └── 3-app
          ├── BOOT-INF
          │   └── classes
          │       ├── application.properties
          │       └── org
          │           └── lukewpatterson
          │               └── layers
          │                   └── blog
          │                       └── app
          │                           └── OurSpringBootApplication.class
          └── META-INF
              ├── MANIFEST.MF
              └── maven
                  └── org.lukewpatterson
                      └── layers-blog-app
                          ├── pom.properties
                          └── pom.xml
      
      26 directories, 93 files
      
      ...
      Step 19/24 : WORKDIR /app/
       ---> Using cache
       ---> e83ac4cda8f7
      Step 20/24 : COPY --from=build /layers/1-dependencies-release/ ./
       ---> Using cache
       ---> a5f34ee04615
      Step 21/24 : COPY --from=build /layers/2-dependencies-snapshot/ ./
       ---> 7446b0325602
      Step 22/24 : COPY --from=build /layers/3-app/ ./
       ---> 6b0cd535260f
      Step 23/24 : RUN tree
      .
      ├── BOOT-INF
      │   ├── classes
      │   │   ├── application.properties
      │   │   └── org
      │   │       └── lukewpatterson
      │   │           └── layers
      │   │               └── blog
      │   │                   └── app
      │   │                       └── OurSpringBootApplication.class
      │   └── lib
      │       ├── classmate-1.3.4.jar
      │       ├── gson-2.8.5.jar
      │       ├── hibernate-validator-6.0.12.Final.jar
      │       ├── jackson-annotations-2.9.0.jar
      │       ├── jackson-core-2.9.6.jar
      │       ├── jackson-databind-2.9.6.jar
      │       ├── jackson-datatype-jdk8-2.9.6.jar
      │       ├── jackson-datatype-jsr310-2.9.6.jar
      │       ├── jackson-module-parameter-names-2.9.6.jar
      │       ├── javax.annotation-api-1.3.2.jar
      │       ├── jboss-logging-3.3.2.Final.jar
      │       ├── jul-to-slf4j-1.7.25.jar
      │       ├── layers-blog-snapshot-dependency-1-SNAPSHOT.jar
      │       ├── log4j-api-2.10.0.jar
      │       ├── log4j-to-slf4j-2.10.0.jar
      │       ├── logback-classic-1.2.3.jar
      │       ├── logback-core-1.2.3.jar
      │       ├── slf4j-api-1.7.25.jar
      │       ├── snakeyaml-1.19.jar
      │       ├── spring-aop-5.0.9.RELEASE.jar
      │       ├── spring-beans-5.0.9.RELEASE.jar
      │       ├── spring-boot-2.0.5.RELEASE.jar
      │       ├── spring-boot-autoconfigure-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-json-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-logging-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-tomcat-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-web-2.0.5.RELEASE.jar
      │       ├── spring-context-5.0.9.RELEASE.jar
      │       ├── spring-core-5.0.9.RELEASE.jar
      │       ├── spring-expression-5.0.9.RELEASE.jar
      │       ├── spring-jcl-5.0.9.RELEASE.jar
      │       ├── spring-web-5.0.9.RELEASE.jar
      │       ├── spring-webmvc-5.0.9.RELEASE.jar
      │       ├── tomcat-embed-core-8.5.34.jar
      │       ├── tomcat-embed-el-8.5.34.jar
      │       ├── tomcat-embed-websocket-8.5.34.jar
      │       └── validation-api-2.0.1.Final.jar
      ├── META-INF
      │   ├── MANIFEST.MF
      │   └── maven
      │       └── org.lukewpatterson
      │           └── layers-blog-app
      │               ├── pom.properties
      │               └── pom.xml
      └── org
          └── springframework
              └── boot
                  └── loader
                      ├── ExecutableArchiveLauncher.class
                      ├── JarLauncher.class
                      ├── LaunchedURLClassLoader$UseFastConnectionExceptionsEnumeration.class
                      ├── LaunchedURLClassLoader.class
                      ├── Launcher.class
                      ├── MainMethodRunner.class
                      ├── PropertiesLauncher$1.class
                      ├── PropertiesLauncher$ArchiveEntryFilter.class
                      ├── PropertiesLauncher$PrefixMatchingArchiveFilter.class
                      ├── PropertiesLauncher.class
                      ├── WarLauncher.class
                      ├── archive
                      │   ├── Archive$Entry.class
                      │   ├── Archive$EntryFilter.class
                      │   ├── Archive.class
                      │   ├── ExplodedArchive$1.class
                      │   ├── ExplodedArchive$FileEntry.class
                      │   ├── ExplodedArchive$FileEntryIterator$EntryComparator.class
                      │   ├── ExplodedArchive$FileEntryIterator.class
                      │   ├── ExplodedArchive.class
                      │   ├── JarFileArchive$EntryIterator.class
                      │   ├── JarFileArchive$JarFileEntry.class
                      │   └── JarFileArchive.class
                      ├── data
                      │   ├── RandomAccessData.class
                      │   ├── RandomAccessDataFile$1.class
                      │   ├── RandomAccessDataFile$DataInputStream.class
                      │   ├── RandomAccessDataFile$FileAccess.class
                      │   └── RandomAccessDataFile.class
                      ├── jar
                      │   ├── AsciiBytes.class
                      │   ├── Bytes.class
                      │   ├── CentralDirectoryEndRecord.class
                      │   ├── CentralDirectoryFileHeader.class
                      │   ├── CentralDirectoryParser.class
                      │   ├── CentralDirectoryVisitor.class
                      │   ├── FileHeader.class
                      │   ├── Handler.class
                      │   ├── JarEntry.class
                      │   ├── JarEntryFilter.class
                      │   ├── JarFile$1.class
                      │   ├── JarFile$2.class
                      │   ├── JarFile$JarFileType.class
                      │   ├── JarFile.class
                      │   ├── JarFileEntries$1.class
                      │   ├── JarFileEntries$EntryIterator.class
                      │   ├── JarFileEntries.class
                      │   ├── JarURLConnection$1.class
                      │   ├── JarURLConnection$JarEntryName.class
                      │   ├── JarURLConnection.class
                      │   ├── StringSequence.class
                      │   └── ZipInflaterInputStream.class
                      └── util
                          └── SystemPropertyUtils.class
      
      20 directories, 93 files
      Removing intermediate container 4f1daefbd4fb
       ---> aeae90ebed6f
      Step 24/24 : CMD ["java", "org.springframework.boot.loader.JarLauncher"]
       ---> 1fa3d13f15a9
      Successfully built 1fa3d13f15a9
      Successfully tagged layers-blog:step-2-change-dependencies-snapshot-layer
      
      --------------------------------------------------------------------------------------------------------------
      $ container-diff diff daemon://layers-blog:step-1-change-dependencies-release-layer daemon://layers-blog:step-2-change-dependencies-snapshot-layer --type=size --type=file
      
      -----File-----
      
      These entries have been added to layers-blog:step-1-change-dependencies-release-layer: None
      
      These entries have been deleted from layers-blog:step-1-change-dependencies-release-layer: None
      
      These entries have been changed between layers-blog:step-1-change-dependencies-release-layer and layers-blog:step-2-change-dependencies-snapshot-layer:
      FILE                                                                    SIZE1        SIZE2
      /app/BOOT-INF/lib/layers-blog-snapshot-dependency-1-SNAPSHOT.jar        2.8K         2.8K
      
      -----Size-----
      
      Image size difference between layers-blog:step-1-change-dependencies-release-layer and layers-blog:step-2-change-dependencies-snapshot-layer:
      SIZE1        SIZE2
      115M         115M
      c3e137b7
    • Luke Patterson's avatar
      $ docker build --tag layers-blog:step-1-change-dependencies-release-layer . · 9b0758c2
      Luke Patterson authored
      ...
      Step 9/24 : WORKDIR ./layers-blog-snapshot-dependency/
       ---> 2a285b6ceb7c
      Step 10/24 : COPY ./layers-blog-snapshot-dependency/ ./
       ---> 9c1c6813df36
      Step 11/24 : RUN mvn install --quiet --update-snapshots --strict-checksums --batch-mode
       ---> e320be9dd7bb
      Step 12/24 : WORKDIR ../layers-blog-app/
       ---> 720d9b384816
      Step 13/24 : COPY layers-blog-app ./
       ---> ab4948f33415
      Step 14/24 : RUN mvn package --quiet --update-snapshots --strict-checksums --batch-mode
       ---> fb7cdb80ff04
      Step 15/24 : WORKDIR ./target/
       ---> fbc83f1d0bad
      Step 16/24 : RUN unzip -q *.jar -d ./unzipped/     && tree ./unzipped/     && mkdir --parents /layers/3-app/BOOT-INF/     && mv ./unzipped/BOOT-INF/classes/ /layers/3-app/BOOT-INF/     && mv ./unzipped/META-INF/ /layers/3-app/     && mkdir --parents /layers/2-dependencies-snapshot/BOOT-INF/lib/     && find ./unzipped/BOOT-INF/lib/ -type f -name '*-SNAPSHOT.jar' -exec mv {} /layers/2-dependencies-snapshot/BOOT-INF/lib/ ';'     && mv ./unzipped/ /layers/1-dependencies-release/     && tree /layers/
      ./unzipped/
      ├── BOOT-INF
      │   ├── classes
      │   │   ├── application.properties
      │   │   └── org
      │   │       └── lukewpatterson
      │   │           └── layers
      │   │               └── blog
      │   │                   └── app
      │   │                       └── OurSpringBootApplication.class
      │   └── lib
      │       ├── classmate-1.3.4.jar
      │       ├── gson-2.8.5.jar
      │       ├── hibernate-validator-6.0.12.Final.jar
      │       ├── jackson-annotations-2.9.0.jar
      │       ├── jackson-core-2.9.6.jar
      │       ├── jackson-databind-2.9.6.jar
      │       ├── jackson-datatype-jdk8-2.9.6.jar
      │       ├── jackson-datatype-jsr310-2.9.6.jar
      │       ├── jackson-module-parameter-names-2.9.6.jar
      │       ├── javax.annotation-api-1.3.2.jar
      │       ├── jboss-logging-3.3.2.Final.jar
      │       ├── jul-to-slf4j-1.7.25.jar
      │       ├── layers-blog-snapshot-dependency-1-SNAPSHOT.jar
      │       ├── log4j-api-2.10.0.jar
      │       ├── log4j-to-slf4j-2.10.0.jar
      │       ├── logback-classic-1.2.3.jar
      │       ├── logback-core-1.2.3.jar
      │       ├── slf4j-api-1.7.25.jar
      │       ├── snakeyaml-1.19.jar
      │       ├── spring-aop-5.0.9.RELEASE.jar
      │       ├── spring-beans-5.0.9.RELEASE.jar
      │       ├── spring-boot-2.0.5.RELEASE.jar
      │       ├── spring-boot-autoconfigure-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-json-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-logging-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-tomcat-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-web-2.0.5.RELEASE.jar
      │       ├── spring-context-5.0.9.RELEASE.jar
      │       ├── spring-core-5.0.9.RELEASE.jar
      │       ├── spring-expression-5.0.9.RELEASE.jar
      │       ├── spring-jcl-5.0.9.RELEASE.jar
      │       ├── spring-web-5.0.9.RELEASE.jar
      │       ├── spring-webmvc-5.0.9.RELEASE.jar
      │       ├── tomcat-embed-core-8.5.34.jar
      │       ├── tomcat-embed-el-8.5.34.jar
      │       ├── tomcat-embed-websocket-8.5.34.jar
      │       └── validation-api-2.0.1.Final.jar
      ├── META-INF
      │   ├── MANIFEST.MF
      │   └── maven
      │       └── org.lukewpatterson
      │           └── layers-blog-app
      │               ├── pom.properties
      │               └── pom.xml
      └── org
          └── springframework
              └── boot
                  └── loader
                      ├── ExecutableArchiveLauncher.class
                      ├── JarLauncher.class
                      ├── LaunchedURLClassLoader$UseFastConnectionExceptionsEnumeration.class
                      ├── LaunchedURLClassLoader.class
                      ├── Launcher.class
                      ├── MainMethodRunner.class
                      ├── PropertiesLauncher$1.class
                      ├── PropertiesLauncher$ArchiveEntryFilter.class
                      ├── PropertiesLauncher$PrefixMatchingArchiveFilter.class
                      ├── PropertiesLauncher.class
                      ├── WarLauncher.class
                      ├── archive
                      │   ├── Archive$Entry.class
                      │   ├── Archive$EntryFilter.class
                      │   ├── Archive.class
                      │   ├── ExplodedArchive$1.class
                      │   ├── ExplodedArchive$FileEntry.class
                      │   ├── ExplodedArchive$FileEntryIterator$EntryComparator.class
                      │   ├── ExplodedArchive$FileEntryIterator.class
                      │   ├── ExplodedArchive.class
                      │   ├── JarFileArchive$EntryIterator.class
                      │   ├── JarFileArchive$JarFileEntry.class
                      │   └── JarFileArchive.class
                      ├── data
                      │   ├── RandomAccessData.class
                      │   ├── RandomAccessDataFile$1.class
                      │   ├── RandomAccessDataFile$DataInputStream.class
                      │   ├── RandomAccessDataFile$FileAccess.class
                      │   └── RandomAccessDataFile.class
                      ├── jar
                      │   ├── AsciiBytes.class
                      │   ├── Bytes.class
                      │   ├── CentralDirectoryEndRecord.class
                      │   ├── CentralDirectoryFileHeader.class
                      │   ├── CentralDirectoryParser.class
                      │   ├── CentralDirectoryVisitor.class
                      │   ├── FileHeader.class
                      │   ├── Handler.class
                      │   ├── JarEntry.class
                      │   ├── JarEntryFilter.class
                      │   ├── JarFile$1.class
                      │   ├── JarFile$2.class
                      │   ├── JarFile$JarFileType.class
                      │   ├── JarFile.class
                      │   ├── JarFileEntries$1.class
                      │   ├── JarFileEntries$EntryIterator.class
                      │   ├── JarFileEntries.class
                      │   ├── JarURLConnection$1.class
                      │   ├── JarURLConnection$JarEntryName.class
                      │   ├── JarURLConnection.class
                      │   ├── StringSequence.class
                      │   └── ZipInflaterInputStream.class
                      └── util
                          └── SystemPropertyUtils.class
      
      20 directories, 93 files
      /layers/
      ├── 1-dependencies-release
      │   ├── BOOT-INF
      │   │   └── lib
      │   │       ├── classmate-1.3.4.jar
      │   │       ├── gson-2.8.5.jar
      │   │       ├── hibernate-validator-6.0.12.Final.jar
      │   │       ├── jackson-annotations-2.9.0.jar
      │   │       ├── jackson-core-2.9.6.jar
      │   │       ├── jackson-databind-2.9.6.jar
      │   │       ├── jackson-datatype-jdk8-2.9.6.jar
      │   │       ├── jackson-datatype-jsr310-2.9.6.jar
      │   │       ├── jackson-module-parameter-names-2.9.6.jar
      │   │       ├── javax.annotation-api-1.3.2.jar
      │   │       ├── jboss-logging-3.3.2.Final.jar
      │   │       ├── jul-to-slf4j-1.7.25.jar
      │   │       ├── log4j-api-2.10.0.jar
      │   │       ├── log4j-to-slf4j-2.10.0.jar
      │   │       ├── logback-classic-1.2.3.jar
      │   │       ├── logback-core-1.2.3.jar
      │   │       ├── slf4j-api-1.7.25.jar
      │   │       ├── snakeyaml-1.19.jar
      │   │       ├── spring-aop-5.0.9.RELEASE.jar
      │   │       ├── spring-beans-5.0.9.RELEASE.jar
      │   │       ├── spring-boot-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-autoconfigure-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-json-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-logging-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-tomcat-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-web-2.0.5.RELEASE.jar
      │   │       ├── spring-context-5.0.9.RELEASE.jar
      │   │       ├── spring-core-5.0.9.RELEASE.jar
      │   │       ├── spring-expression-5.0.9.RELEASE.jar
      │   │       ├── spring-jcl-5.0.9.RELEASE.jar
      │   │       ├── spring-web-5.0.9.RELEASE.jar
      │   │       ├── spring-webmvc-5.0.9.RELEASE.jar
      │   │       ├── tomcat-embed-core-8.5.34.jar
      │   │       ├── tomcat-embed-el-8.5.34.jar
      │   │       ├── tomcat-embed-websocket-8.5.34.jar
      │   │       └── validation-api-2.0.1.Final.jar
      │   └── org
      │       └── springframework
      │           └── boot
      │               └── loader
      │                   ├── ExecutableArchiveLauncher.class
      │                   ├── JarLauncher.class
      │                   ├── LaunchedURLClassLoader$UseFastConnectionExceptionsEnumeration.class
      │                   ├── LaunchedURLClassLoader.class
      │                   ├── Launcher.class
      │                   ├── MainMethodRunner.class
      │                   ├── PropertiesLauncher$1.class
      │                   ├── PropertiesLauncher$ArchiveEntryFilter.class
      │                   ├── PropertiesLauncher$PrefixMatchingArchiveFilter.class
      │                   ├── PropertiesLauncher.class
      │                   ├── WarLauncher.class
      │                   ├── archive
      │                   │   ├── Archive$Entry.class
      │                   │   ├── Archive$EntryFilter.class
      │                   │   ├── Archive.class
      │                   │   ├── ExplodedArchive$1.class
      │                   │   ├── ExplodedArchive$FileEntry.class
      │                   │   ├── ExplodedArchive$FileEntryIterator$EntryComparator.class
      │                   │   ├── ExplodedArchive$FileEntryIterator.class
      │                   │   ├── ExplodedArchive.class
      │                   │   ├── JarFileArchive$EntryIterator.class
      │                   │   ├── JarFileArchive$JarFileEntry.class
      │                   │   └── JarFileArchive.class
      │                   ├── data
      │                   │��  ├── RandomAccessData.class
      │                   │   ├── RandomAccessDataFile$1.class
      │                   │   ├── RandomAccessDataFile$DataInputStream.class
      │                   │   ├── RandomAccessDataFile$FileAccess.class
      │                   │   └── RandomAccessDataFile.class
      │                   ├── jar
      │                   │   ├── AsciiBytes.class
      │                   │   ├── Bytes.class
      │                   │   ├── CentralDirectoryEndRecord.class
      │                   │   ├── CentralDirectoryFileHeader.class
      │                   │   ├── CentralDirectoryParser.class
      │                   │   ├── CentralDirectoryVisitor.class
      │                   │   ├── FileHeader.class
      │                   │   ├── Handler.class
      │                   │   ├── JarEntry.class
      │                   │   ├── JarEntryFilter.class
      │                   │   ├── JarFile$1.class
      │                   │   ├── JarFile$2.class
      │                   │   ├── JarFile$JarFileType.class
      │                   │   ├── JarFile.class
      │                   │   ├── JarFileEntries$1.class
      │                   │   ├── JarFileEntries$EntryIterator.class
      │                   │   ├── JarFileEntries.class
      │                   │   ├── JarURLConnection$1.class
      │                   │   ├── JarURLConnection$JarEntryName.class
      │                   │   ├── JarURLConnection.class
      │                   │   ├── StringSequence.class
      │                   │   └── ZipInflaterInputStream.class
      │                   └── util
      │                       └── SystemPropertyUtils.class
      ├── 2-dependencies-snapshot
      │   └── BOOT-INF
      │       └── lib
      │           └── layers-blog-snapshot-dependency-1-SNAPSHOT.jar
      └── 3-app
          ├── BOOT-INF
          │   └── classes
          │       ├── application.properties
          │       └── org
          │           └── lukewpatterson
          │               └── layers
          │                   └── blog
          │                       └── app
          │                           └── OurSpringBootApplication.class
          └── META-INF
              ├── MANIFEST.MF
              └── maven
                  └── org.lukewpatterson
                      └── layers-blog-app
                          ├── pom.properties
                          └── pom.xml
      
      26 directories, 93 files
      
      ...
      Step 19/24 : WORKDIR /app/
       ---> Using cache
       ---> e83ac4cda8f7
      Step 20/24 : COPY --from=build /layers/1-dependencies-release/ ./
       ---> a5f34ee04615
      Step 21/24 : COPY --from=build /layers/2-dependencies-snapshot/ ./
       ---> cd906d9b4640
      Step 22/24 : COPY --from=build /layers/3-app/ ./
       ---> 001ca1ae72d4
      Step 23/24 : RUN tree
      .
      ├── BOOT-INF
      │   ├── classes
      │   │   ├── application.properties
      │   │   └── org
      │   │       └── lukewpatterson
      │   │           └── layers
      │   │               └── blog
      │   │                   └── app
      │   │                       └── OurSpringBootApplication.class
      │   └── lib
      │       ├── classmate-1.3.4.jar
      │       ├── gson-2.8.5.jar
      │       ├── hibernate-validator-6.0.12.Final.jar
      │       ├── jackson-annotations-2.9.0.jar
      │       ├── jackson-core-2.9.6.jar
      │       ├── jackson-databind-2.9.6.jar
      │       ├── jackson-datatype-jdk8-2.9.6.jar
      │       ├── jackson-datatype-jsr310-2.9.6.jar
      │       ├── jackson-module-parameter-names-2.9.6.jar
      │       ├── javax.annotation-api-1.3.2.jar
      │       ├── jboss-logging-3.3.2.Final.jar
      │       ├── jul-to-slf4j-1.7.25.jar
      │       ├── layers-blog-snapshot-dependency-1-SNAPSHOT.jar
      │       ├── log4j-api-2.10.0.jar
      │       ├── log4j-to-slf4j-2.10.0.jar
      │       ├── logback-classic-1.2.3.jar
      │       ├── logback-core-1.2.3.jar
      │       ├── slf4j-api-1.7.25.jar
      │       ├── snakeyaml-1.19.jar
      │       ├── spring-aop-5.0.9.RELEASE.jar
      │       ├── spring-beans-5.0.9.RELEASE.jar
      │       ├── spring-boot-2.0.5.RELEASE.jar
      │       ├── spring-boot-autoconfigure-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-json-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-logging-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-tomcat-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-web-2.0.5.RELEASE.jar
      │       ├── spring-context-5.0.9.RELEASE.jar
      │       ├── spring-core-5.0.9.RELEASE.jar
      │       ├── spring-expression-5.0.9.RELEASE.jar
      │       ├── spring-jcl-5.0.9.RELEASE.jar
      │       ├── spring-web-5.0.9.RELEASE.jar
      │       ├── spring-webmvc-5.0.9.RELEASE.jar
      │       ├── tomcat-embed-core-8.5.34.jar
      │       ├── tomcat-embed-el-8.5.34.jar
      │       ├── tomcat-embed-websocket-8.5.34.jar
      │       └── validation-api-2.0.1.Final.jar
      ├── META-INF
      │   ├── MANIFEST.MF
      │   └── maven
      │       └── org.lukewpatterson
      │           └── layers-blog-app
      │               ├── pom.properties
      │               └── pom.xml
      └── org
          └── springframework
              └── boot
                  └── loader
                      ├── ExecutableArchiveLauncher.class
                      ├── JarLauncher.class
                      ├── LaunchedURLClassLoader$UseFastConnectionExceptionsEnumeration.class
                      ├── LaunchedURLClassLoader.class
                      ├── Launcher.class
                      ├── MainMethodRunner.class
                      ├── PropertiesLauncher$1.class
                      ├── PropertiesLauncher$ArchiveEntryFilter.class
                      ├── PropertiesLauncher$PrefixMatchingArchiveFilter.class
                      ├── PropertiesLauncher.class
                      ├── WarLauncher.class
                      ├── archive
                      │   ├── Archive$Entry.class
                      │   ├── Archive$EntryFilter.class
                      │   ├── Archive.class
                      │   ├── ExplodedArchive$1.class
                      │   ├── ExplodedArchive$FileEntry.class
                      │   ├── ExplodedArchive$FileEntryIterator$EntryComparator.class
                      │   ├── ExplodedArchive$FileEntryIterator.class
                      │   ├── ExplodedArchive.class
                      │   ├── JarFileArchive$EntryIterator.class
                      │   ├── JarFileArchive$JarFileEntry.class
                      │   └── JarFileArchive.class
                      ├── data
                      │   ├── RandomAccessData.class
                      │   ├── RandomAccessDataFile$1.class
                      │   ├── RandomAccessDataFile$DataInputStream.class
                      │   ├── RandomAccessDataFile$FileAccess.class
                      │   └── RandomAccessDataFile.class
                      ├── jar
                      │   ├── AsciiBytes.class
                      │   ├── Bytes.class
                      │   ├── CentralDirectoryEndRecord.class
                      │   ├── CentralDirectoryFileHeader.class
                      │   ├── CentralDirectoryParser.class
                      │   ├── CentralDirectoryVisitor.class
                      │   ├── FileHeader.class
                      │   ├── Handler.class
                      │   ├── JarEntry.class
                      │   ├── JarEntryFilter.class
                      │   ├── JarFile$1.class
                      │   ├── JarFile$2.class
                      │   ├── JarFile$JarFileType.class
                      │   ├── JarFile.class
                      │   ├── JarFileEntries$1.class
                      │   ├── JarFileEntries$EntryIterator.class
                      │   ├── JarFileEntries.class
                      │   ├── JarURLConnection$1.class
                      │   ├── JarURLConnection$JarEntryName.class
                      │   ├── JarURLConnection.class
                      │   ├── StringSequence.class
                      │   └── ZipInflaterInputStream.class
                      └── util
                          └── SystemPropertyUtils.class
      
      20 directories, 93 files
       ---> 14940d217b00
      Step 24/24 : CMD ["java", "org.springframework.boot.loader.JarLauncher"]
       ---> dfd4920a5fe7
      Successfully built dfd4920a5fe7
      Successfully tagged layers-blog:step-1-change-dependencies-release-layer
      
      --------------------------------------------------------------------------------------------------------------
      $ container-diff diff daemon://layers-blog:step-0-initial-build daemon://layers-blog:step-1-change-dependencies-release-layer --type=size --type=file
      
      -----File-----
      
      These entries have been added to layers-blog:step-0-initial-build:
      FILE                                    SIZE
      /app/BOOT-INF/lib/gson-2.8.5.jar        236K
      
      These entries have been deleted from layers-blog:step-0-initial-build: None
      
      These entries have been changed between layers-blog:step-0-initial-build and layers-blog:step-1-change-dependencies-release-layer:
      FILE                                                                  SIZE1        SIZE2
      /app/META-INF/maven/org.lukewpatterson/layers-blog-app/pom.xml        1.3K         1.4K
      
      -----Size-----
      
      Image size difference between layers-blog:step-0-initial-build and layers-blog:step-1-change-dependencies-release-layer:
      SIZE1         SIZE2
      114.7M        115M
      9b0758c2
  3. 04 Nov, 2018 2 commits
    • Luke Patterson's avatar
      $ docker build --tag layers-blog:step-0-initial-build . · b663ee20
      Luke Patterson authored
      ...
      Step 9/24 : WORKDIR ./layers-blog-snapshot-dependency/
       ---> 88b225936bee
      Step 10/24 : COPY ./layers-blog-snapshot-dependency/ ./
       ---> 96178605fb19
      Step 11/24 : RUN mvn install --quiet --update-snapshots --strict-checksums --batch-mode
       ---> e2d1d22c9519
      Step 12/24 : WORKDIR ../layers-blog-app/
       ---> e7bb8e108b94
      Step 13/24 : COPY layers-blog-app ./
       ---> 01cb36659cb6
      Step 14/24 : RUN mvn package --quiet --update-snapshots --strict-checksums --batch-mode
       ---> cd6abb394e3e
      Step 15/24 : WORKDIR ./target/
       ---> 2c6272c90ef4
      Step 16/24 : RUN unzip -q *.jar -d ./unzipped/     && tree ./unzipped/     && mkdir --parents /layers/3-app/BOOT-INF/     && mv ./unzipped/BOOT-INF/classes/ /layers/3-app/BOOT-INF/     && mv ./unzipped/META-INF/ /layers/3-app/     && mkdir --parents /layers/2-dependencies-snapshot/BOOT-INF/lib/     && find ./unzipped/BOOT-INF/lib/ -type f -name '*-SNAPSHOT.jar' -exec mv {} /layers/2-dependencies-snapshot/BOOT-INF/lib/ ';'     && mv ./unzipped/ /layers/1-dependencies-release/     && tree /layers/
       /unzipped/
      ├── BOOT-INF
      │   ├── classes
      │   │   ├── application.properties
      │   │   └── org
      │   │       └── lukewpatterson
      │   │           └── layers
      │   │               └── blog
      │   │                   └── app
      │   │                       └── OurSpringBootApplication.class
      │   └── lib
      │       ├── classmate-1.3.4.jar
      │       ├── hibernate-validator-6.0.12.Final.jar
      │       ├── jackson-annotations-2.9.0.jar
      │       ├── jackson-core-2.9.6.jar
      │       ├── jackson-databind-2.9.6.jar
      │       ├── jackson-datatype-jdk8-2.9.6.jar
      │       ├── jackson-datatype-jsr310-2.9.6.jar
      │       ├── jackson-module-parameter-names-2.9.6.jar
      │       ├── javax.annotation-api-1.3.2.jar
      │       ├── jboss-logging-3.3.2.Final.jar
      │       ├── jul-to-slf4j-1.7.25.jar
      │       ├── layers-blog-snapshot-dependency-1-SNAPSHOT.jar
      │       ├── log4j-api-2.10.0.jar
      │       ├── log4j-to-slf4j-2.10.0.jar
      │       ├── logback-classic-1.2.3.jar
      │       ├── logback-core-1.2.3.jar
      │       ├── slf4j-api-1.7.25.jar
      │       ├── snakeyaml-1.19.jar
      │       ├── spring-aop-5.0.9.RELEASE.jar
      │       ├── spring-beans-5.0.9.RELEASE.jar
      │       ├── spring-boot-2.0.5.RELEASE.jar
      │       ├── spring-boot-autoconfigure-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-json-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-logging-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-tomcat-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-web-2.0.5.RELEASE.jar
      │       ├── spring-context-5.0.9.RELEASE.jar
      │       ├── spring-core-5.0.9.RELEASE.jar
      │       ├── spring-expression-5.0.9.RELEASE.jar
      │       ├── spring-jcl-5.0.9.RELEASE.jar
      │       ├── spring-web-5.0.9.RELEASE.jar
      │       ├── spring-webmvc-5.0.9.RELEASE.jar
      │       ├── tomcat-embed-core-8.5.34.jar
      │       ├── tomcat-embed-el-8.5.34.jar
      │       ├── tomcat-embed-websocket-8.5.34.jar
      │       └── validation-api-2.0.1.Final.jar
      ├── META-INF
      │   ├── MANIFEST.MF
      │   └── maven
      │       └── org.lukewpatterson
      │           └── layers-blog-app
      │               ├── pom.properties
      │               └── pom.xml
      └── org
          └── springframework
              └── boot
                  └── loader
                      ├── ExecutableArchiveLauncher.class
                      ├── JarLauncher.class
                      ├── LaunchedURLClassLoader$UseFastConnectionExceptionsEnumeration.class
                      ├── LaunchedURLClassLoader.class
                      ├── Launcher.class
                      ├── MainMethodRunner.class
                      ├── PropertiesLauncher$1.class
                      ├── PropertiesLauncher$ArchiveEntryFilter.class
                      ├── PropertiesLauncher$PrefixMatchingArchiveFilter.class
                      ├── PropertiesLauncher.class
                      ├── WarLauncher.class
                      ├── archive
                      │   ├── Archive$Entry.class
                      │   ├── Archive$EntryFilter.class
                      │   ├── Archive.class
                      │   ├── ExplodedArchive$1.class
                      │   ├── ExplodedArchive$FileEntry.class
                      │   ├── ExplodedArchive$FileEntryIterator$EntryComparator.class
                      │   ├── ExplodedArchive$FileEntryIterator.class
                      │   ├── ExplodedArchive.class
                      │   ├── JarFileArchive$EntryIterator.class
                      │   ├── JarFileArchive$JarFileEntry.class
                      │   └── JarFileArchive.class
                      ├── data
                      │   ├── RandomAccessData.class
                      │   ├── RandomAccessDataFile$1.class
                      │   ├── RandomAccessDataFile$DataInputStream.class
                      │   ├── RandomAccessDataFile$FileAccess.class
                      │   └── RandomAccessDataFile.class
                      ├── jar
                      │   ├── AsciiBytes.class
                      │   ├── Bytes.class
                      │   ├── CentralDirectoryEndRecord.class
                      │   ├── CentralDirectoryFileHeader.class
                      │   ├── CentralDirectoryParser.class
                      │   ├── CentralDirectoryVisitor.class
                      │   ├── FileHeader.class
                      │   ├── Handler.class
                      │   ├── JarEntry.class
                      │   ├── JarEntryFilter.class
                      │   ├── JarFile$1.class
                      │   ├── JarFile$2.class
                      │   ├── JarFile$JarFileType.class
                      │   ├── JarFile.class
                      │   ├── JarFileEntries$1.class
                      │   ├── JarFileEntries$EntryIterator.class
                      │   ├── JarFileEntries.class
                      │   ├── JarURLConnection$1.class
                      │   ├── JarURLConnection$JarEntryName.class
                      │   ├── JarURLConnection.class
                      │   ├── StringSequence.class
                      │   └── ZipInflaterInputStream.class
                      └── util
                          └── SystemPropertyUtils.class
      
      20 directories, 92 files
      /layers/
      ├── 1-dependencies-release
      │   ├── BOOT-INF
      │   │   └── lib
      │   │       ├── classmate-1.3.4.jar
      │   │       ├── hibernate-validator-6.0.12.Final.jar
      │   │       ├── jackson-annotations-2.9.0.jar
      │   │       ├── jackson-core-2.9.6.jar
      │   │       ├── jackson-databind-2.9.6.jar
      │   │       ├── jackson-datatype-jdk8-2.9.6.jar
      │   │       ├── jackson-datatype-jsr310-2.9.6.jar
      │   │       ├── jackson-module-parameter-names-2.9.6.jar
      │   │       ├── javax.annotation-api-1.3.2.jar
      │   │       ├── jboss-logging-3.3.2.Final.jar
      │   │       ├── jul-to-slf4j-1.7.25.jar
      │   │       ├── log4j-api-2.10.0.jar
      │   │       ├── log4j-to-slf4j-2.10.0.jar
      │   │       ├── logback-classic-1.2.3.jar
      │   │       ├── logback-core-1.2.3.jar
      │   │       ├── slf4j-api-1.7.25.jar
      │   │       ├── snakeyaml-1.19.jar
      │   │       ├── spring-aop-5.0.9.RELEASE.jar
      │   │       ├── spring-beans-5.0.9.RELEASE.jar
      │   │       ├── spring-boot-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-autoconfigure-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-json-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-logging-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-tomcat-2.0.5.RELEASE.jar
      │   │       ├── spring-boot-starter-web-2.0.5.RELEASE.jar
      │   │       ├── spring-context-5.0.9.RELEASE.jar
      │   │       ├── spring-core-5.0.9.RELEASE.jar
      │   │       ├── spring-expression-5.0.9.RELEASE.jar
      │   │       ├── spring-jcl-5.0.9.RELEASE.jar
      │   │       ├── spring-web-5.0.9.RELEASE.jar
      │   │       ├── spring-webmvc-5.0.9.RELEASE.jar
      │   │       ├── tomcat-embed-core-8.5.34.jar
      │   │       ├── tomcat-embed-el-8.5.34.jar
      │   │       ├── tomcat-embed-websocket-8.5.34.jar
      │   │       └── validation-api-2.0.1.Final.jar
      │   └── org
      │       └── springframework
      │           └── boot
      │               └── loader
      │                   ├── ExecutableArchiveLauncher.class
      │                   ├── JarLauncher.class
      │                   ├── LaunchedURLClassLoader$UseFastConnectionExceptionsEnumeration.class
      │                   ├── LaunchedURLClassLoader.class
      │                   ├── Launcher.class
      │                   ├── MainMethodRunner.class
      │                   ├── PropertiesLauncher$1.class
      │                   ├── PropertiesLauncher$ArchiveEntryFilter.class
      │                   ├── PropertiesLauncher$PrefixMatchingArchiveFilter.class
      │                   ├── PropertiesLauncher.class
      │                   ├── WarLauncher.class
      │                   ├── archive
      │                   │   ├── Archive$Entry.class
      │                   │   ├── Archive$EntryFilter.class
      │                   │   ├── Archive.class
      │                   │   ├── ExplodedArchive$1.class
      │                   │   ├── ExplodedArchive$FileEntry.class
      │                   │   ├── ExplodedArchive$FileEntryIterator$EntryComparator.class
      │                   │   ├── ExplodedArchive$FileEntryIterator.class
      │                   │   ├── ExplodedArchive.class
      │                   │   ├── JarFileArchive$EntryIterator.class
      │                   │   ├── JarFileArchive$JarFileEntry.class
      │                   │   └── JarFileArchive.class
      │                   ├── data
      │                   │   ├── RandomAccessData.class
      │                   │   ├── RandomAccessDataFile$1.class
      │                   │   ├── RandomAccessDataFile$DataInputStream.class
      │                   │   ├── RandomAccessDataFile$FileAccess.class
      │                   │   └── RandomAccessDataFile.class
      │                   ├── jar
      │                   │   ├── AsciiBytes.class
      │                   │   ├── Bytes.class
      │                   │   ├── CentralDirectoryEndRecord.class
      │                   │   ├── CentralDirectoryFileHeader.class
      │                   │   ├── CentralDirectoryParser.class
      │                   │   ├── CentralDirectoryVisitor.class
      │                   │   ├── FileHeader.class
      │                   │   ├── Handler.class
      │                   │   ├── JarEntry.class
      │                   │   ├── JarEntryFilter.class
      │                   │   ├── JarFile$1.class
      │                   │   ├── JarFile$2.class
      │                   │   ├── JarFile$JarFileType.class
      │                   │   ├── JarFile.class
      │                   │   ├── JarFileEntries$1.class
      │                   │   ├── JarFileEntries$EntryIterator.class
      │                   │   ├── JarFileEntries.class
      │                   │   ├── JarURLConnection$1.class
      │                   │   ├── JarURLConnection$JarEntryName.class
      │                   │   ├── JarURLConnection.class
      │                   │   ├── StringSequence.class
      │                   │   └── ZipInflaterInputStream.class
      │                   └── util
      │                       └── SystemPropertyUtils.class
      ├── 2-dependencies-snapshot
      │   └── BOOT-INF
      │       └── lib
      │           └── layers-blog-snapshot-dependency-1-SNAPSHOT.jar
      └── 3-app
          ├── BOOT-INF
          │   └── classes
          │       ├── application.properties
          │       └── org
          │           └── lukewpatterson
          │               └── layers
          │                   └── blog
          │                       └── app
          │                           └── OurSpringBootApplication.class
          └── META-INF
              ├── MANIFEST.MF
              └── maven
                  └── org.lukewpatterson
                      └── layers-blog-app
                          ├── pom.properties
                          └── pom.xml
      
      26 directories, 92 files
      
      ...
      Step 19/24 : WORKDIR /app/
       ---> e83ac4cda8f7
      Step 20/24 : COPY --from=build /layers/1-dependencies-release/ ./
       ---> d158e97b92fe
      Step 21/24 : COPY --from=build /layers/2-dependencies-snapshot/ ./
       ---> bb5e6342aa80
      Step 22/24 : COPY --from=build /layers/3-app/ ./
       ---> e0395252c3b1
      Step 23/24 : RUN tree
      .
      ├── BOOT-INF
      │   ├── classes
      │   │   ├── application.properties
      │   │   └── org
      │   │       └── lukewpatterson
      │   │           └── layers
      │   │               └── blog
      │   │                   └── app
      │   │                       └── OurSpringBootApplication.class
      │   └── lib
      │       ├── classmate-1.3.4.jar
      │       ├── hibernate-validator-6.0.12.Final.jar
      │       ├── jackson-annotations-2.9.0.jar
      │       ├── jackson-core-2.9.6.jar
      │       ├── jackson-databind-2.9.6.jar
      │       ├── jackson-datatype-jdk8-2.9.6.jar
      │       ├── jackson-datatype-jsr310-2.9.6.jar
      │       ├── jackson-module-parameter-names-2.9.6.jar
      │       ├── javax.annotation-api-1.3.2.jar
      │       ├── jboss-logging-3.3.2.Final.jar
      │       ├── jul-to-slf4j-1.7.25.jar
      │       ├── layers-blog-snapshot-dependency-1-SNAPSHOT.jar
      │       ├── log4j-api-2.10.0.jar
      │       ├── log4j-to-slf4j-2.10.0.jar
      │       ├── logback-classic-1.2.3.jar
      │       ├── logback-core-1.2.3.jar
      │       ├── slf4j-api-1.7.25.jar
      │       ├── snakeyaml-1.19.jar
      │       ├── spring-aop-5.0.9.RELEASE.jar
      │       ├── spring-beans-5.0.9.RELEASE.jar
      │       ├── spring-boot-2.0.5.RELEASE.jar
      │       ├── spring-boot-autoconfigure-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-json-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-logging-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-tomcat-2.0.5.RELEASE.jar
      │       ├── spring-boot-starter-web-2.0.5.RELEASE.jar
      │       ├── spring-context-5.0.9.RELEASE.jar
      │       ├── spring-core-5.0.9.RELEASE.jar
      │       ├── spring-expression-5.0.9.RELEASE.jar
      │       ├── spring-jcl-5.0.9.RELEASE.jar
      │       ├── spring-web-5.0.9.RELEASE.jar
      │       ├── spring-webmvc-5.0.9.RELEASE.jar
      │       ├── tomcat-embed-core-8.5.34.jar
      │       ├── tomcat-embed-el-8.5.34.jar
      │       ├── tomcat-embed-websocket-8.5.34.jar
      │       └── validation-api-2.0.1.Final.jar
      ├── META-INF
      │   ├── MANIFEST.MF
      │   └── maven
      │       └── org.lukewpatterson
      │           └── layers-blog-app
      │               ├── pom.properties
      │               └── pom.xml
      └── org
          └── springframework
              └── boot
                  └── loader
                      ├── ExecutableArchiveLauncher.class
                      ├── JarLauncher.class
                      ├── LaunchedURLClassLoader$UseFastConnectionExceptionsEnumeration.class
                      ├── LaunchedURLClassLoader.class
                      ├── Launcher.class
                      ├── MainMethodRunner.class
                      ├── PropertiesLauncher$1.class
                      ├── PropertiesLauncher$ArchiveEntryFilter.class
                      ├── PropertiesLauncher$PrefixMatchingArchiveFilter.class
                      ├── PropertiesLauncher.class
                      ├── WarLauncher.class
                      ├── archive
                      │   ├── Archive$Entry.class
                      │   ├── Archive$EntryFilter.class
                      │   ├── Archive.class
                      │   ├── ExplodedArchive$1.class
                      │   ├── ExplodedArchive$FileEntry.class
                      │   ├── ExplodedArchive$FileEntryIterator$EntryComparator.class
                      │   ├── ExplodedArchive$FileEntryIterator.class
                      │   ├── ExplodedArchive.class
                      │   ├── JarFileArchive$EntryIterator.class
                      │   ├── JarFileArchive$JarFileEntry.class
                      │   └── JarFileArchive.class
                      ├── data
                      │   ├── RandomAccessData.class
                      │   ├── RandomAccessDataFile$1.class
                      │   ├── RandomAccessDataFile$DataInputStream.class
                      │   ├── RandomAccessDataFile$FileAccess.class
                      │   └── RandomAccessDataFile.class
                      ├── jar
                      │   ├── AsciiBytes.class
                      │   ├── Bytes.class
                      │   ├── CentralDirectoryEndRecord.class
                      │   ├── CentralDirectoryFileHeader.class
                      │   ├── CentralDirectoryParser.class
                      │   ├── CentralDirectoryVisitor.class
                      │   ├── FileHeader.class
                      │   ├── Handler.class
                      │   ├── JarEntry.class
                      │   ├── JarEntryFilter.class
                      │   ├── JarFile$1.class
                      │   ├── JarFile$2.class
                      │   ├── JarFile$JarFileType.class
                      │   ├── JarFile.class
                      │   ├── JarFileEntries$1.class
                      │   ├── JarFileEntries$EntryIterator.class
                      │   ├── JarFileEntries.class
                      │   ├── JarURLConnection$1.class
                      │   ├── JarURLConnection$JarEntryName.class
                      │   ├── JarURLConnection.class
                      │   ├── StringSequence.class
                      │   └── ZipInflaterInputStream.class
                      └── util
                          └── SystemPropertyUtils.class
      
      20 directories, 92 files
      Step 24/24 : CMD ["java", "org.springframework.boot.loader.JarLauncher"]
       ---> ffcb1a7c41eb
      Successfully built ffcb1a7c41eb
      Successfully tagged layers-blog:step-0-initial-build
      b663ee20
    • Luke Patterson's avatar
      ignore some stuff · 4dd98fe4
      Luke Patterson authored
      4dd98fe4