Argument "SOURCE" is required
java -jar jenkins-cli.jar install-plugin SOURCE ... [-deploy] [-name VAL] 
[-restart] [--username VAL] [--password VAL] [--password-file VAL]
Installs a plugin either from a file, an URL, or from update center.
 SOURCE              : If this points to a local file, that file will be
                       installed. If this is an URL, Jenkins downloads the URL
                       and installs that as a plugin.Otherwise the name is
                       assumed to be the short name of the plugin in the
                       existing update center (like "findbugs"),and the plugin
                       will be installed from the update center
 -deploy             : Deploy plugins right away without postponing them until
                       the reboot.
 -name VAL           : If specified, the plugin will be installed as this short
                       name (whereas normally the name is inferred from the
                       source name automatically.)
 -restart            : Restart Jenkins upon successful installation
 --username VAL      : User name to authenticate yourself to Jenkins
 --password VAL      : Password for authentication. Note that passing a
                       password in arguments is insecure.
 --password-file VAL : File that contains the password


The URL you are downloading a particular plugin is the SOURCE

From: 
<[email protected]<mailto:[email protected]>> on 
behalf of Hemant Gupta <[email protected]<mailto:[email protected]>>
Reply-To: 
"[email protected]<mailto:[email protected]>" 
<[email protected]<mailto:[email protected]>>
Date: Monday, April 4, 2016 at 2:44 PM
To: "[email protected]<mailto:[email protected]>" 
<[email protected]<mailto:[email protected]>>
Subject: Re: What is the best way to download all the Jenkins plugins along 
with their dependencies?

thanks for your responses.

How can i use jenkins-cli.jar file to modify the below curl command:
curl -o $PLUGIN_DIR/$name-$Version.hpi 
$JENKINS_PLUGINS_URL/$name/$latest_version/$name.hpi



On Friday, April 1, 2016 at 7:17:36 PM UTC-5, Mark Waite wrote:
If the goal is to download and install the plugins and their dependencies, you 
could use the jenkins-cli.jar file and make command line calls to Jenkins 
itself.  I think it will then resolve the dependencies for you.

Mark Waite

On Fri, Apr 1, 2016 at 5:06 PM Ian Duffy <[email protected]<javascript:>> wrote:
I build them all as RPMs and let yum resolve the dependencies.



On 1 April 2016 at 23:50, jieryn <[email protected]<javascript:>> wrote:
bash$ jar xf the.jpi
bash$ find the/WEB-INF/lib

On Fri, Apr 1, 2016 at 6:28 PM, Hemant Gupta <[email protected]<javascript:>> 
wrote:
> Thanks for response !!
> I can write bash to download the plugin(.hpi) from the
> http://updates.jenkins-ci.org/download/plugins/
>
> But, if I download a .hpi plugin file, it doesn't download the dependent
> .hpi files.
> In other words, downloading a plugin doesn't download its dependencies.
>
> Can you throw some light on writing the logic that would also download the
> dependencies?
>
>
> On Friday, April 1, 2016 at 4:59:13 PM UTC-5, Jesse Farinacci wrote:
>>
>> The built plugin (.jpi / .hpi) already has its dependencies bundled
>> within it. Every plugin has a symlink to the latest version. This
>> seems like a pretty straightforward web crawler walk, downloading only
>> the /latest/ linkage from
>> http://updates.jenkins-ci.org/download/plugins/
>>
>> On Fri, Apr 1, 2016 at 5:51 PM, Hemant Gupta <[email protected]> wrote:
>> > I am thinking of writing a bash script(plugin.sh) that would download
>> > the
>> > plugins along with their dependencies.
>> >
>> > I am also thinking of creating a text file(plugin.txt) where I would
>> > list
>> > the plugin and version that I need to download.
>> >
>> > The bash script(plugin.sh) will take text file(plugin.txt) as an input
>> > and
>> > would download all the plugins along with their dependencies in the
>> > /var/lib/plugins
>> >
>> >
>> > I am sure someone must have done this earlier. I will highly appreciate
>> > if
>> > you can provide a few references to it.
>> >
>> > --
>> > 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/4cc79c22-9c9c-4f11-91b2-f190c7d0f4e0%40googlegroups.com.
>> > For more options, visit https://groups.google.com/d/optout.
>
> --
> 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]<javascript:>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/ff7dc842-ebac-4f20-8ef3-b2bd1b1aedea%40googlegroups.com.
>
> For more options, visit https://groups.google.com/d/optout.

--
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]<javascript:>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAArU9iYioQod5bMU_dACjCgJY9nu5485zA%3DhaRNz2pi2%3DXQJ9A%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


--
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]<javascript:>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAEJ3w4Xxu_uW-rxYw1w4FubrUDxS%3DgsGuvAWsx1i_iMFW9j4vw%40mail.gmail.com<https://groups.google.com/d/msgid/jenkinsci-users/CAEJ3w4Xxu_uW-rxYw1w4FubrUDxS%3DgsGuvAWsx1i_iMFW9j4vw%40mail.gmail.com?utm_medium=email&utm_source=footer>.
For more options, visit https://groups.google.com/d/optout.

--
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]<mailto:[email protected]>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/4c787fa3-94fe-4344-b13d-a370f1c71853%40googlegroups.com<https://groups.google.com/d/msgid/jenkinsci-users/4c787fa3-94fe-4344-b13d-a370f1c71853%40googlegroups.com?utm_medium=email&utm_source=footer>.
For more options, visit https://groups.google.com/d/optout.

-- 
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/D32849B7.4E383%25ingunawa%40cisco.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to