Complete the code to install a Jenkins plugin using the CLI.
java -jar jenkins-cli.jar -s http://localhost:8080 install-plugin [1]
The git plugin is a common Jenkins plugin installed via CLI using this command.
Complete the code to list all installed Jenkins plugins using the CLI.
java -jar jenkins-cli.jar -s http://localhost:8080 [1]
The list-plugins command shows all plugins installed in Jenkins.
Fix the error in the command to update a Jenkins plugin.
java -jar jenkins-cli.jar -s http://localhost:8080 [1] git
The correct command to update a plugin is update-plugin. Other options are invalid.
Fill both blanks to create a command that installs and then restarts Jenkins safely.
java -jar jenkins-cli.jar -s http://localhost:8080 [1] git && java -jar jenkins-cli.jar -s http://localhost:8080 [2]
First, install-plugin installs the plugin. Then, safe-restart restarts Jenkins safely after installation.
Fill all three blanks to create a command that updates a plugin, lists plugins, and then safely restarts Jenkins.
java -jar jenkins-cli.jar -s http://localhost:8080 [1] git && java -jar jenkins-cli.jar -s http://localhost:8080 [2] && java -jar jenkins-cli.jar -s http://localhost:8080 [3]
The commands update the plugin, list all plugins, and then safely restart Jenkins.