Giter VIP home page Giter VIP logo

Comments (3)

toote avatar toote commented on August 26, 2024

@viraptor You are correct, thanks for pointing out! It was my fault as it was one of the first changes I did in this repository without completely understanding the code's and compose nuances.

While I want to correct the option, I am really interested in your expectations on how it should work and what kind of configurations you want off it. Also, I am not 100% sure how specifying a target would work when you are building multiple services. Do you have any thoughts on that?

from docker-compose-buildkite-plugin.

viraptor avatar viraptor commented on August 26, 2024

I am really interested in your expectations on how it should work and what kind of configurations you want off it.

My original use case was to have a service app pointing at a Dockerfile with multiple stages. Then the test steps would use an override to use target: ci which includes the test tools, while other steps would use the default which builds just the deployable image.

Turns out I had more differences to implement, so ended up just duplicating the service as ...-prod and ...-test in the docker-compose itself and assigning different targets there.

I think the option could still be useful in a simpler setup.

Also, I am not 100% sure how specifying a target would work when you are building multiple services. Do you have any thoughts on that?

Nope, I suspect it would have to be a hack for a single service only.

from docker-compose-buildkite-plugin.

camallen avatar camallen commented on August 26, 2024

I just ran into this issue and assumed that specifying the target option would override the compose file to add a target build directive to the overridden service definition, thus allowing me to target a stage in a multi stage build.

Sadly this just slaps an incorrect --target onto the docker compose cmd which results in

$ docker-compose -f docker-compose.yml -p buildkite018c900423954192bc6a0b21321ae8ae -f docker-compose.buildkite-10-override.yml build --pull --target base app
unknown flag: --target
🚨 Error: The command exited with status 16

FWIW - My use case is similar to @viraptor in that i want to target a multi stage build.

#231 (comment) provides a similar use case I have where i'd like to prebuild multi stage cache images to avoid extra work in subsequent builds.

from docker-compose-buildkite-plugin.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.