пятница, 26 апреля 2019 г.

Install Jenkins CentOS 7.6

How to Install and Configure Jenkins

Install Jenkins
sudo wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat/jenkins.repo
sudo rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key
yum -y install jenkins

yum -y install java-1.8.0-openjdk

systemctl enable jenkins
systemctl start jenkins

yum -y install setroubleshoot-server selinux-policy-devel
sepolicy network -t http_port_t
semanage port -m -t http_port_t -p tcp 8080

Nginx Reverse Proxy config

Configure Jenkins

Jenkins User

cat /etc/passwd |grep jenkins
jenkins:x:998:996:Jenkins Automation Server:/var/lib/jenkins:/bin/false

change false to bash
vi /etc/passwd
jenkins:x:998:996:Jenkins Automation Server:/var/lib/jenkins:/bin/bash

set a password for jenkins
passwd jenkins
<enter your password>

su - jenkins

ssh-keygen
ssh-copy-id jenkins@localhost

visudo

   after
root    ALL=(ALL)       ALL
   add
jenkins ALL=(ALL)       NOPASSWD: ALL



среда, 24 апреля 2019 г.

Docker LA


docker node inspect --pretty NODEID
docker node demote NID

CheatSheet
https://www.docker.com/sites/default/files/Docker_CheatSheet_08.09.2016_0.pdf

docker commit -m "COMMENTs" -a "author" nasty_girl tcox/ubusshd:v1

DockerFile
#Custom Ubuntu image with SSH installed

FROM ubuntu:xenial
MAINTAINER ryanblack <ryanblack@inbox.ru>
RUN apt-get update
RUN apt-get install -y telnet openssh-server

воскресенье, 14 апреля 2019 г.