jenkins+svn 自动化上线
一.环境:
[root@bimvm01 ~]# cat /etc/redhat-release
CentOS Linux release 7.6.1810 (Core)
[root@bimvm01 ~]# uname -a
Linux bimvm01 3.10.0-957.el7.x86_64 #1 SMP Thu Nov 8 23:39:32 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
Jenkins 版本
jenkins-2.118-1.1
Jdk版本1.8.0
java-1.8.0-openjdk.x86_64
二.安装
1.安装epel源
rpm -ivh https://mirrors.kernel.org/fedora-epel/7/x86_64/Packages/e/epel-release-7-11.noarch.rpm
2.安装jenkins
wget -O /etc/yum.repos.d/jenkins.repo https://pkg.jenkins.io/redhat/jenkins.repo
rpm --import https://pkg.jenkins.io/redhat/jenkins.io.key
yum install jenkins -y
3.安装jdk
yum install java-1.8.0-openjdk.x86_64 -y
4.安装svn 客户端
yum install -y subversion
查看svn命令帮助:
svn help
5.启动jenkins
/etc/init.d/jenkins restart
或
java -jar /usr/lib/jenkins/jenkins.war
6.关闭防火墙
systemctl stop firewalld.service
systemctl disable firewalld.service
or(开放端口)
firewall-cmd --permanent --add-port=8080/tcp
7.测试jenkins
http://192.168.1.170:8080
8.输入密码
[root@bimvm01 ~]# cat /var/lib/jenkins/secrets/initialAdminPassword
b6a6666602f34ab4866f9cdf7e5082d9
9.安装插件
10.创建用户
11.jenkins 安装完成
12.安装maven
mkdir /home/maven
cd /home/maven
#上传maven包
tar -xvf apache-maven-3.6.0-bin.tar.gz
mv apache-maven-3.6.0 maven
vim /etc/profile
##增加以下内容
export MAVEN_HOME=/home/maven/maven
export MAVEN_HOME
export PATH=${PATH}:${MAVEN_HOME}/bin
##重新刷新配置文件
source /etc/profile
##测试安装
[root@bimvm01 maven]# mvn -version
Apache Maven 3.0.5 (Red Hat 3.0.5-17)
Maven home: /usr/share/maven
Java version: 1.8.0_201, vendor: Oracle Corporation
Java home: /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.201.b09-2.el7_6.x86_64/jre
Default locale: zh_CN, platform encoding: UTF-8
OS name: "linux", version: "3.10.0-957.el7.x86_64", arch: "amd64", family: "unix"
13.在jenkins中配置jdk和maven
14.插件管理中下载Publish over SSH插件
15创建一个新项目
16.配置该任务
17.构建触发器
18.构建执行shell
#!/bin/bash
##########################
## 建威CMS
##########################
now_time=$(date +"%Y%m%d_%H%M%S")
cd /home/bim/cms
tar -zcvf cms_back_${now_time}.tar.gz *
mv cms_back_* /home/bim/back/cmsback
systemctl reload nginx
yum install npm -y
#!/bin/bash -lie
#sh /home/bim/back/jianweioa.sh
#!/bin/bash
##########################
## 建威OA
##########################
now_time=$(date +"%Y%m%d_%H%M%S")
cd /home/bim/jianweioa #切换至构建目录
node -v
npm -v #检查编译环
cp -r /home/bim/back/jianweioaback/index.js /home/bim/jianweioa/config/
cp -r /home/node_modules /home/bim/jianweioa/
rm -rf /home/bim/jianweioa/src/api/service.js
cp /home/bim/back/jianweioaback/api/service.js /home/bim/jianweioa/src/api
#npm install chromedriver --chromedriver_cdnurl=http://cdn.npm.taobao.org/dist/chromedriver
#npm install
#npm install wangeditor
#npm install webpack
#npm i
#npm install http-server -g
npm run build #编译项目
cd dist
tar -zcvf jwoa_${now_time}.tar.gz * #打包备份
mv jwoa_* /home/bim/back/jianweioaback
rm -rf /home/bim/web/jianweioa/*
mv /home/bim/jianweioa/dist/* /home/bim/web/jianweioa
rm -rf /home/bim/jianweioa/*
systemctl restart nginx
注:2
# 打开配置文件
vim /etc/sysconfig/jenkins
# 修改$JENKINS_USER,并去掉当前行注释
$JENKINS_USER="root"
chown -R root:root /var/lib/jenkins
chown -R root:root /var/cache/jenkins
chown -R root:root /var/log/jenkins
# 重启Jenkins(若是其他方式安装的jenkins则重启方式略不同)
systemctl restart jenkins
# 查看Jenkins进程所属用户
ps -ef | grep jenkins
# 若显示为root用户,则表示修改完成
#!/bin/bash
##########################
## 建威OA
##
##########################
now_time=$(date +"%Y%m%d_%H%M%S")
cp /home/bim/back/jianweioaback/index.js /home/bim/jianweioa/config/
cd /home/bim/jianweioa #切换至构建目录
node -v
npm -v #检查编译环
npm install chromedriver --chromedriver_cdnurl=http://cdn.npm.taobao.org/dist/chromedriver
npm install
npm install wangeditor
npm install webpack
npm i
npm run build #编译项目
cd dist
tar -zcvf jwoa_${now_time}.tar.gz * #打包备份
mv jwoa_* /home/bim/back/jianweioaback
#rm -rf /home/bim/web/jianweioa/*
mv /home/bim/jianweioa/dist/* /home/bim/web/jianweioa
ls /home/bim/jianweioa | grep -v node_modules | xargs -i rm -rf {}
systemctl restart nginx
由用户 xuewenlong 启动
Running as SYSTEM
构建中 在工作空间 /home/bim/jianweioa 中
Updating https://192.168.1.200/svn/TestSVN/web/jianweioa at revision '2019-04-30T10:03:53.357 +0800' --quiet
Using sole credentials yulinjie/****** (svn) in realm ‘<https://192.168.1.200:443> VisualSVN Server’
At revision 1312
Using sole credentials yulinjie/****** (svn) in realm ‘<https://192.168.1.200:443> VisualSVN Server’
[jianweioa] $ /bin/bash -lie /tmp/jenkins7296205467554102448.sh
bash: 此 shell 中无任务控制
v10.15.3
6.4.1
> jianweioa@1.0.0 build /home/bim/jianweioa
> node build/build.js
Hash: [1m178a8e8725ee622ab067[39m[22m
Version: webpack [1m3.12.0[39m[22m
Time: [1m72413[39m[22mms
[1mAsset[39m[22m [1mSize[39m[22m [1mChunks[39m[22m [1m[39m[22m [1m[39m[22m [1mChunk Names[39m[22m
[1m[32mstatic/imgs/.svn/prop-base/background.png.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/img/asidebg.c3cf0b7.png[39m[22m 48 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/fonts/OAIcons.964a65d.woff[39m[22m 17.4 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/fonts/OAIcons.32db094.eot[39m[22m 17.5 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/fonts/OAIcons.93901bf.ttf[39m[22m 17.3 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/img/OAIcons.7c830dd.svg[39m[22m 61.9 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/fonts/element-icons.6f0a763.ttf[39m[22m 11 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/img/homelogo.3ba8e09.png[39m[22m 12.1 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[33mstatic/js/vendor.71c0e42d72cbb3a0195a.js[39m[22m [1m[33m826 kB[39m[22m [1m0[39m[22m [1m[32m[emitted][39m[22m [1m[33m[big][39m[22m vendor
[1m[33mstatic/js/app.cdb168323639ec8ea899.js[39m[22m [1m[33m358 kB[39m[22m [1m1[39m[22m [1m[32m[emitted][39m[22m [1m[33m[big][39m[22m app
[1m[32mstatic/js/manifest.2ae2e69a05c33dfc65f8.js[39m[22m 857 bytes [1m2[39m[22m [1m[32m[emitted][39m[22m manifest
[1m[33mstatic/css/app.7892718fc7fe44c4f918da18a9c22625.css[39m[22m [1m[33m291 kB[39m[22m [1m1[39m[22m [1m[32m[emitted][39m[22m [1m[33m[big][39m[22m app
[1m[32mstatic/css/app.7892718fc7fe44c4f918da18a9c22625.css.map[39m[22m 456 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/js/vendor.71c0e42d72cbb3a0195a.js.map[39m[22m 3.25 MB [1m0[39m[22m [1m[32m[emitted][39m[22m vendor
[1m[32mstatic/js/app.cdb168323639ec8ea899.js.map[39m[22m 1.31 MB [1m1[39m[22m [1m[32m[emitted][39m[22m app
[1m[32mstatic/js/manifest.2ae2e69a05c33dfc65f8.js.map[39m[22m 4.97 kB [1m2[39m[22m [1m[32m[emitted][39m[22m manifest
[1m[32mindex.html[39m[22m 574 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/asidebg.png[39m[22m 48 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/asidelogo.png[39m[22m 4.57 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/background.png[39m[22m 203 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/homelogo.png[39m[22m 12.1 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/logo.png[39m[22m 4.44 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/.svn/all-wcprops[39m[22m 306 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/.svn/entries[39m[22m 517 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/.svn/format[39m[22m 2 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/.svn/prop-base/favicon.ico.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/all-wcprops[39m[22m 1.62 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/entries[39m[22m 2.02 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/format[39m[22m 2 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/prop-base/asidebg.png.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/prop-base/asidelogo.png.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/prop-base/avatar.png.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/img/background.de3cb54.png[39m[22m 203 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/prop-base/homelogo.png.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/prop-base/logo.png.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/prop-base/mail.png.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/prop-base/newapply.png.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/prop-base/newimgs.png.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/prop-base/phone.png.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/prop-base/share_qq.png.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/prop-base/share_weixin.png.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/prop-base/testimg.jpeg.svn-base[39m[22m 131 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/text-base/asidelogo.png.svn-base[39m[22m 4.57 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/text-base/avatar.png.svn-base[39m[22m 2.71 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/text-base/logo.png.svn-base[39m[22m 4.44 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/text-base/mail.png.svn-base[39m[22m 356 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/text-base/newapply.png.svn-base[39m[22m 5.67 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/text-base/phone.png.svn-base[39m[22m 387 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/text-base/share_qq.png.svn-base[39m[22m 591 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/text-base/share_weixin.png.svn-base[39m[22m 605 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/avatar.png[39m[22m 2.71 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/mail.png[39m[22m 356 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/newapply.png[39m[22m 5.67 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/phone.png[39m[22m 387 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/share_qq.png[39m[22m 591 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/share_weixin.png[39m[22m 605 bytes [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/text-base/homelogo.png.svn-base[39m[22m 12.1 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/.svn/text-base/favicon.ico.svn-base[39m[22m 17 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/favicon.ico[39m[22m 17 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/text-base/testimg.jpeg.svn-base[39m[22m 37.2 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/testimg.jpeg[39m[22m 37.2 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/text-base/asidebg.png.svn-base[39m[22m 48 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/text-base/newimgs.png.svn-base[39m[22m 68.6 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/newimgs.png[39m[22m 68.6 kB [1m[39m[22m [1m[32m[emitted][39m[22m
[1m[32mstatic/imgs/.svn/text-base/background.png.svn-base[39m[22m 203 kB [1m[39m[22m [1m[32m[emitted][39m[22m
Build complete.
Tip: built files are meant to be served over an HTTP server.
Opening index.html over file:// won't work.
index.html
static/
static/imgs/
static/imgs/.svn/
static/imgs/.svn/prop-base/
static/imgs/.svn/prop-base/asidebg.png.svn-base
static/imgs/.svn/prop-base/asidelogo.png.svn-base
static/imgs/.svn/prop-base/avatar.png.svn-base
static/imgs/.svn/prop-base/background.png.svn-base
static/imgs/.svn/prop-base/homelogo.png.svn-base
static/imgs/.svn/prop-base/logo.png.svn-base
static/imgs/.svn/prop-base/mail.png.svn-base
static/imgs/.svn/prop-base/newapply.png.svn-base
static/imgs/.svn/prop-base/newimgs.png.svn-base
static/imgs/.svn/prop-base/phone.png.svn-base
static/imgs/.svn/prop-base/share_qq.png.svn-base
static/imgs/.svn/prop-base/share_weixin.png.svn-base
static/imgs/.svn/prop-base/testimg.jpeg.svn-base
static/imgs/.svn/text-base/
static/imgs/.svn/text-base/asidelogo.png.svn-base
static/imgs/.svn/text-base/avatar.png.svn-base
static/imgs/.svn/text-base/logo.png.svn-base
static/imgs/.svn/text-base/mail.png.svn-base
static/imgs/.svn/text-base/newapply.png.svn-base
static/imgs/.svn/text-base/phone.png.svn-base
static/imgs/.svn/text-base/share_qq.png.svn-base
static/imgs/.svn/text-base/share_weixin.png.svn-base
static/imgs/.svn/text-base/homelogo.png.svn-base
static/imgs/.svn/text-base/testimg.jpeg.svn-base
static/imgs/.svn/text-base/asidebg.png.svn-base
static/imgs/.svn/text-base/newimgs.png.svn-base
static/imgs/.svn/text-base/background.png.svn-base
static/imgs/.svn/all-wcprops
static/imgs/.svn/entries
static/imgs/.svn/format
static/imgs/testimg.jpeg
static/imgs/newimgs.png
static/imgs/asidebg.png
static/imgs/asidelogo.png
static/imgs/background.png
static/imgs/homelogo.png
static/imgs/logo.png
static/imgs/avatar.png
static/imgs/mail.png
static/imgs/newapply.png
static/imgs/phone.png
static/imgs/share_qq.png
static/imgs/share_weixin.png
static/.svn/
static/.svn/prop-base/
static/.svn/prop-base/favicon.ico.svn-base
static/.svn/text-base/
static/.svn/text-base/favicon.ico.svn-base
static/.svn/all-wcprops
static/.svn/entries
static/.svn/format
static/favicon.ico
static/img/
static/img/asidebg.c3cf0b7.png
static/img/background.de3cb54.png
static/img/OAIcons.7c830dd.svg
static/img/homelogo.3ba8e09.png
static/fonts/
static/fonts/OAIcons.964a65d.woff
static/fonts/OAIcons.32db094.eot
static/fonts/OAIcons.93901bf.ttf
static/fonts/element-icons.6f0a763.ttf
static/js/
static/js/vendor.71c0e42d72cbb3a0195a.js
static/js/app.cdb168323639ec8ea899.js
static/js/manifest.2ae2e69a05c33dfc65f8.js
static/js/vendor.71c0e42d72cbb3a0195a.js.map
static/js/app.cdb168323639ec8ea899.js.map
static/js/manifest.2ae2e69a05c33dfc65f8.js.map
static/css/
static/css/app.7892718fc7fe44c4f918da18a9c22625.css
static/css/app.7892718fc7fe44c4f918da18a9c22625.css.map
Finished: SUCCESS
后台war包自动打包发布
安装插件
#!/bin/bash -lie
#!/bim/bash
now_time=$(date +"%Y%m%d_%H%M%S")
rm -rf /home/tomcat/apache-tomcat-9.0.10/webapps/oa-0.0.1-SNAPSHOT*
cp /var/lib/jenkins/workspace/jwoawar/target/oa-0.0.1-SNAPSHOT.war /home/tomcat/apache-tomcat-9.0.102/webapps/
cp /var/lib/jenkins/workspace/jwoawar/target/oa-0.0.1-SNAPSHOT.war /home/bim/data/jianweioa/oa-0.0.1-SNAPSHOT-${now_time}.war
#rm -rf /var/lib/jenkins/workspace/jwoawarwar/*
##!/bin/bash -lie
#sh +x /home/tomcat/apache-tomcat-9.0.10/bin/shutdown.sh
##!/bin/bash -lie
#sh +x /home/tomcat/apache-tomcat-9.0.10/bin/startup.sh
tomcat监控自启脚本
#!/bin/sh
# 获取tomcat进程ID(其中[grep -w 'tomcat']代码中的tomcat需要替换为你的tomcat文件夹名)
TomcatID=$(ps -C java u --cols=500|grep /home/tomcat | awk '{print $2}')
# tomcat启动程序(这里注意tomcat实际安装的路径)
StartTomcat=/home/tomcat/apache-tomcat-9.0.10/bin/startup.sh
TomcatCache=/home/apache-tomcat-9.0.10/work
#定义要监控的页面地址
WebUrl=http://localhost:8080
#日志输出
GetPageInfo=/tmp/TomcatMonitor.Info
TomcatMonitorLog=/tmp/TomcatMonitor.log
Monitor()
{
echo "[info]开始监控tomcat...[$(date +'%F %H:%M:%S')]"
if [ $TomcatID ];then #这里判断Tomcat进程是否存在
echo "[info]当前tomcat进程ID为:$TomcatID,继续检测页面..."
# 检测是否启动成功(成功的话页面会返回状态"200")
TomcatServiceCode=$(curl -s -o $GetPageInfo -m 10 --connect-timeout 10 $WebUrl -w %{http_code})
if [ $TomcatServiceCode -eq 200 ];then
echo "[info]页面返回码为$TomcatServiceCode,tomcat启动成功,测试页面正常"
else
echo "[error]tomcat页面出错,请注意...状态码为$TomcatServiceCode,错误日志已输出到$GetPageInfo"
echo "[error]页面访问出错,开始重启tomcat"
kill -9 $TomcatID # 杀掉原tomcat进程
sleep 3
rm -rf $TomcatCache # 清理tomcat缓存
$StartTomcat
fi
else
echo "[error]tomcat进程不存在!tomcat开始自动重启..."
echo "[info]$StartTomcat,请稍候..."
rm -rf $TomcatCache
$StartTomcat
fi
echo "--------------------------"
}
Monitor>>$TomcatMonitorLog
jenkins+svn 自动化上线的更多相关文章
- jenkins+svn+gradle自动化部署笔记
自己虚拟机jekins配置:(jenkins+svn+gradle)自动化部署,1.linux配置好jdk,解压tomcat,将 jenkins.war翻到webapps目录下.2.系统管理-管理用户 ...
- 自动化部署-Jenkins+SVN+MSBuild
这篇文章主要介绍下使用Jenkins实现自动化部署 下载 https://jenkins.io/download/ 安装 按步骤安装即可,下载的是windows版本,安装完成后,会看到这样一个正在运行 ...
- Jenkins +svn +maven +tomcat+ ansible 自动化批量部署
Jenkins +svn +maven +tomcat+ ansible 自动化批量部署 一.部署svn yum install subversion 先创建目录 mkdir /home/svn 创建 ...
- Jenkins+svn+ftp自动化发布asp.net项目
今天将自己所掌握的(Jenkins+svn+ftp自动化发布asp.net项目)知识分享给大家,希望能帮组到大家: (1)先下载Jenkins并安装: (2)安装.Net所需要的插件: (3)配置插件 ...
- Jenkins+SVN+Maven+shell 自动化部署实践
JAVA环境中利用Jenkins+svn+maven进行自动化部署实践 一. 前言2 1.介绍jenkins2 1.本地项目打包2 2.通过secureCRT工具,手动传输到服务器2 3.然后 ...
- 使用Maven+Nexus+Jenkins+Svn+Tomcat+Sonar搭建持续集成环境
前言 但凡一个略有规模的项目都需要一个持续集成环境的支撑,为什么需要持续集成环境,我们来看一个例子.假如一个项目,由A.B两位程序员来协作开发,A负责前端模块,B负责后端模块,前端依赖后端.A和B都习 ...
- Maven+Nexus+Jenkins+Svn+Tomcat+Sonar搭建持续集成环境
使用Maven+Nexus+Jenkins+Svn+Tomcat+Sonar搭建持续集成环境(一) 2015-01-14 20:28 by 飘扬的红领巾, 4322 阅读, 5 评论, 收藏, 编辑 ...
- 使用Maven+Nexus+Jenkins+Svn+Tomcat+Sonar搭建持续集成环境(二)
前言 上一篇随笔Maven+Nexus+Jenkins+Svn+Tomcat+Sonar搭建持续集成环境(一)介绍maven和nexus的环境搭建,以及如何使用maven和nexus统一管理库 ...
- Maven+Nexus+Jenkins+Svn+Tomcat+Sonar搭建持续集成环境(二)
上一篇随笔Maven+Nexus+Jenkins+Svn+Tomcat+Sonar搭建持续集成环境(一)介绍maven和nexus的环境搭建,以及如何使用maven和nexus统一管理库文件和版本,以 ...
随机推荐
- javascript----放大模式
放大模式 1.介绍:放大模式降低模块之间直接的联系,降低耦合,当一个模块出现错误,不会影响另一个模块的功能
- 走进WebApiClientCore的设计
WebApiClient WebApiClient是NCC开源社区的一个项目,是目前微服务里http接口调用的一把锋利尖刀,项目早期设计与开发的时候,是基于.netframework的,然后慢慢加入n ...
- Java switch case语句
switch case 语句判断一个变量与一系列值中某个值是否相等,每个值称为一个分支. switch case 语句语法格式如下: switch(expression){ case value : ...
- 为什么Tableviewcell创建时可以不判空
dequeueReuseableCellWithIdentifier:与dequeueReuseableCellWithIdentifier:forIndexPath:的区别: 前者不必向tableV ...
- POJ3735
题目链接:http://poj.org/problem?id=3735 解题思路: 先构造一个(n+1)*(n+1)的单位矩阵E,在此基础上进行操作: 1.g i -------------& ...
- HDU1588
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1588 题目大意:g(i)= k * i + b. 给定 k 和 b,求0 <= i < n ...
- 【python爬虫】scrapy入门7:Scrapy中runspider和crawl的区别
runspider:不依赖创建项目 命令:scrapy runspider myspider.py 等同于 pyhton myspider.py crawl:使用spider进行爬取,依赖项目创建 ...
- OAUTH开放授权
OAUTH开放授权 OAUTH开放授权为用户资源的授权提供了一个安全的.开放而又简易的标准.OAUTH的授权不会使第三方触及到用户的帐号信息例如用户名与密码等,即第三方无需使用用户的用户名与密码就可以 ...
- Spring基础之AOP
一.AOP能解决什么问题 业务层每个service都要管理事务,在每个service中单独写事务,就会产生很多重复性的代码,而且修改事务时,需要修改源码,不利于维护.为此,把横向重复的代码,纵向抽取形 ...
- [工具-001]C++更换EXE的ICON图标
我们都知道每个可执行文件EXE都会有自己的图标,它可以在项目生成的时候进行指认,但是有时候我们会遇到两种情况:1.没有源代码,2.我们的项目很多,一个个进行更换很耗时.本人就是因为接到这么一个需求,要 ...