Tuesday, 18 August 2020

Installing and running Jenkins on Ubuntu ...

 An aide memoire for my future self ......


( partly cribbed from Installing Jenkins )

wget -q -O - https://pkg.jenkins.io/debian-stable/jenkins.io.key | sudo apt-key add -

sudo sh -c 'echo deb https://pkg.jenkins.io/debian-stable binary/ > /etc/apt/sources.list.d/jenkins.list'

sudo apt-get update

sudo apt-get install openjdk-8-jdk -y

sudo apt-get install jenkins -y

sudo service jenkins start

sudo service jenkins status

● jenkins.service - LSB: Start Jenkins at boot time

   Loaded: loaded (/etc/init.d/jenkins; generated)

   Active: active (exited) since Tue 2020-08-18 16:26:25 BST; 1min 10s ago

     Docs: man:systemd-sysv-generator(8)

  Process: 8815 ExecStart=/etc/init.d/jenkins start (code=exited, status=0/SUCCESS)


Aug 18 16:26:23 ubuntu18 systemd[1]: Starting LSB: Start Jenkins at boot time...

Aug 18 16:26:23 ubuntu18 jenkins[8815]: Correct java version found

Aug 18 16:26:23 ubuntu18 jenkins[8815]:  * Starting Jenkins Automation Server jenkins

Aug 18 16:26:24 ubuntu18 su[8863]: Successful su for jenkins by root

Aug 18 16:26:24 ubuntu18 su[8863]: + ??? root:jenkins

Aug 18 16:26:24 ubuntu18 su[8863]: pam_unix(su:session): session opened for user jenkins by (uid=0)

Aug 18 16:26:24 ubuntu18 su[8863]: pam_unix(su:session): session closed for user jenkins

Aug 18 16:26:25 ubuntu18 jenkins[8815]:    ...done.

Aug 18 16:26:25 ubuntu18 systemd[1]: Started LSB: Start Jenkins at boot time.

sudo cat /var/lib/jenkins/secrets/initialAdminPassword

kjfsjfkjsdfjhsdfhsadjfasdfsdaf892uweufusd

and then hit Jenkins: -

http://ubuntu:8080/login?from=%2F


No comments:

Note to self - use kubectl to query images in a pod or deployment

In both cases, we use JSON ... For a deployment, we can do this: - kubectl get deployment foobar --namespace snafu --output jsonpath="{...