Hello,

The answer is straight forward, I missed somehow.

Under agent just include label options


pipeline {
    agent {
        docker { image 'node:14-alpine'

                 label '<label_name>' }

    }


Thank you


On Wed, 26 Aug, 2020, 6:23 pm john levin, <[email protected]> wrote:

>
> Hello Everyone
>
> I have a scenario like i need to run my CI builds in a container and this
> container should run on slave machines accordingly (i have same image in
> all my slave machines). But pipeline is accepting either agent as docker or
> slave machines.
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/a425f6c3-b16f-435d-91a6-66fadf18e05cn%40googlegroups.com
> <https://groups.google.com/d/msgid/jenkinsci-users/a425f6c3-b16f-435d-91a6-66fadf18e05cn%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAGJXh7rhEfTrpyUOLQHxcL8J%2BkE7JHzTHdrpspwm%3D4tXbQbgXg%40mail.gmail.com.

Reply via email to