安装常用linux软件
apt update
apt install sudo vim curl wget
全新安装debian 10系统
curl -fLO https://raw.githubusercontent.com/bohanyang/debi/master/debi.sh && chmod a+rx debi.sh
sudo ./debi.sh --cdn --network-console --ethx --bbr --user root --password $Password --timezone Asia/Shanghai --version 10
sudo shutdown -r now
安装docker
卸载旧版本docker
sudo apt-get remove docker docker-engine docker.io containerd runc
安装新版本docker
curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh get-docker.sh
安装jenkins/blue-ocean
docker run \
-u root \
-d \
--restart unless-stopped \
-p 8080:8080 \
-p 50000:50000 \
-v jenkins-data:/var/jenkins_home \
-v /var/run/docker.sock:/var/run/docker.sock \
--name jenkins \
jenkinsci/blueocean
配置Jenkins?slave?service
vi?/etc/systemd/system/jenkins-slave.service
[Unit]
Description=Jenkins Slave Service
After=network.target
[Service]
Type=simple
User=root
Restart=1
RestartSec=5s
ExecStart=/usr/bin/java -jar /opt/jenkins/agent.jar -jnlpUrl http://jenkins.dlmu.ml:8080/computer/toronto-arm/jenkins-agent.jnlp -secret 2148259b4f7ced25aeb8c25030a2efd0091caaf4c3e426af6677171992832d94 -workDir "/root/jenkins
[Install]
WantedBy=multi-user.target
|