5 ms·
I'm also occasionally using Docker t generate build artifacts (so +1 for that) - how do you pull the built blob out of the image? I've used `docker exec` plus `
by akx 7y ago
I'm also occasionally using Docker t generate build artifacts (so +1 for that) - how do you pull the built blob out of the image? I've used `docker exec` plus `docker cp`, but it feels a little clunky.
- victornomad 7y agoYou can just mount a volume and write the blob into it, very easy and convinient!
- akx 7y agoOoh, right, you can mount in `docker build`? That'd solve it, thanks!
- RangerScience 7y agoOh hmm, no you can't: https://vsupalov.com/cache-docker-build-dependencies-without-volume-mounting/ https://vsupalov.com/cache-docker-build-dependencies-without...
- victornomad 7y agoYou mount it when you run it using -v hostfolder:containerfolder I recommend you though to use Docker-compose, somehow everything becomes much saner than using the normal "docker" executable
- RangerScience 7y agoDepends on the nature of the build artefacts? Gems, jars and NPM packages get posted to a jFrog artefactory. Go and Cocoapods just use straight Git, so Jenkins actually makes commits for those (and in the case of Go, version tags) from inside the Docker container. For the EMR clusters, there's a step in the build script that uploads the files to S3. Another way to do it would be to have the `docker run` / `docker build` script be given a mounted volume that maps to the system's, and then it would write the blobs to that volume, where (I think?) they'd then be accessible to the outer system.