Jenkins Operations: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
 
(2 intermediate revisions by the same user not shown)
Line 62: Line 62:
curl -H "Authorization: Basic c[...]4"  https://jenkins.example.com/cloud/blue/rest/organizations/jenkins/pipelines/example/branches/sombranch/runs/${build_number}/nodes/${node_number}/log/?start=0 > ./node.txt
curl -H "Authorization: Basic c[...]4"  https://jenkins.example.com/cloud/blue/rest/organizations/jenkins/pipelines/example/branches/sombranch/runs/${build_number}/nodes/${node_number}/log/?start=0 > ./node.txt
</syntaxhighlight>
</syntaxhighlight>
=Plugin Operations=
==Amazon EC2 Container Service Plugin==
{{Internal|Jenkins_Amazon_EC2_Container_Service_Plugin#Operations|Amazon EC2 Container Service Plugin Operations}}
=Aborting a Build=
{{External|https://www.jenkins.io/doc/book/using/aborting-a-build/}}

Latest revision as of 17:20, 31 August 2020

Internal

Overview

Jenkins Version

Manage Jenkins → About Jenkins

Best Practices

https://wiki.jenkins.io/display/JENKINS/Jenkins+Best+Practices

Running Jenkins as a Docker Container

Running Jenkins as a Docker Container

Procedures

Writing a Jenkins Pipeline

Writing a Jenkins Pipeline

Manage Worker Nodes

Bring up a New Worker Node

Jenkins → Manage Jenkins → Manage Nodes

To bring up a new type of worker node, navigate to the bottom and use the "Provision with node-type" dropdown box.

Configure a New Worker Node Type

Jenkins → Manage Jenkins → Configure System

A node type is known as a "Cloud", so the configuration lives in the "Cloud" section.

The name of the worker type is technically the "name of the Jenkins could of agents".

We want an "Amazon EC2" type of cloud. The "Amazon EC2" could is capable launching multiple types of workers, based on different AMIs..

Load Statistics

Manage Jenkins → Load Statistics

For a specific type of executor: https://jenkins.example.com/cloud/label/<yourlabelhere>/load-statistics

Download Logs

Download a Build's Console Output

Using UI, navigate to the build's console output: Build → Build History → Specific build → View as plain text → get the URL.

curl -H "Authorization: Basic c[...]4"  https://jenkins.example.com/cloud/job/example/job/somejob/33/consoleText > ./build-33.txt

Download a Node Log

curl -H "Authorization: Basic c[...]4"  https://jenkins.example.com/cloud/blue/rest/organizations/jenkins/pipelines/example/branches/sombranch/runs/${build_number}/nodes/${node_number}/log/?start=0 > ./node.txt

Plugin Operations

Amazon EC2 Container Service Plugin

Amazon EC2 Container Service Plugin Operations

Aborting a Build

https://www.jenkins.io/doc/book/using/aborting-a-build/