This test verifies that a locally stored Docker image in the form of a tar archive created from a 'docker save' command can be unpacked and stored in the proper locations accessible to the Docker provisioner.
| 194 | // tar archive created from a 'docker save' command can be unpacked and |
| 195 | // stored in the proper locations accessible to the Docker provisioner. |
| 196 | TEST_F(ProvisionerDockerLocalStoreTest, LocalStoreTestWithTar) |
| 197 | { |
| 198 | slave::Flags flags; |
| 199 | flags.docker_registry = path::join(os::getcwd(), "images"); |
| 200 | flags.docker_store_dir = path::join(os::getcwd(), "store"); |
| 201 | flags.image_provisioner_backend = COPY_BACKEND; |
| 202 | |
| 203 | Try<Owned<slave::Store>> store = slave::docker::Store::create(flags); |
| 204 | ASSERT_SOME(store); |
| 205 | |
| 206 | Image mesosImage; |
| 207 | mesosImage.set_type(Image::DOCKER); |
| 208 | mesosImage.mutable_docker()->set_name("abc"); |
| 209 | |
| 210 | Future<slave::ImageInfo> imageInfo = |
| 211 | store.get()->get(mesosImage, COPY_BACKEND); |
| 212 | |
| 213 | AWAIT_READY(imageInfo); |
| 214 | |
| 215 | verifyLocalDockerImage(flags, imageInfo->layers); |
| 216 | } |
| 217 | |
| 218 | |
| 219 | // This tests the ability of the metadata manger to recover the images it has |
nothing calls this directly
no test coverage detected