安装maven 下载maven,解压
[[email protected] local]# pwd /usr/local [[email protected] local]# tar -zxvf apache-maven-3.0.5-bin.tar.gz [[email protected] local]# cd apache-maven-3.0.5/ [[email protected] apache-maven-3.0.5]# pwd /usr/local/apache-maven-3.0.5
配置maven环境变量
[[email protected] apache-maven-3.0.5]# vim /etc/profile # 在profile文件末尾增加如下配置 # maven env export MAVEN_HOME=/usr/local/apache-maven-3.0.5 export PATH=$MAVEN_HOME/bin:$PATH [[email protected] apache-maven-3.0.5]# source /etc/profile [[email protected] apache-maven-3.0.5]# mvn -version Apache Maven 3.0.5 (r01de14724cdef164cd33c7c8c2fe155faf9602da; 2013-02-19 05:51:28-0800) Maven home: /usr/local/apache-maven-3.0.5 Java version: 1.7.0_79, vendor: Oracle Corporation Java home: /usr/local/jdk1.7.0_79/jre Default locale: en_US, platform encoding: UTF-8 OS name: "linux", version: "2.6.32-504.16.2.el6.x86_64", arch: "amd64", family: "unix"
安装Hudson
1.配置nginx
[[email protected] domains]# cat tools.hudson.local.com upstream tomcat_tools.hudson.local { server 127.0.0.1:8025 weight=10 max_fails=2 fail_timeout=300s; } server { listen 80; server_name tools.hudson.local.com; root /export/data/javaRoot/tools.hudson.local.com/; access_log /export/nginx/logs/tools.hudson.local.com/tools.hudson.local.com_access.log main; error_log /export/nginx/logs/tools.hudson.local.com/tools.hudson.local.com_error.log warn; error_page 403 404 /40x.html; location / { index index.html index.htm; proxy_next_upstream http_500 http_502 http_503 http_504 error timeout invalid_header; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_pass http://tomcat_tools.hudson.local; expires 0d; } }
2、部署tomcat实例
[[email protected] tools.hudson.local.com]# pwd /export/data/javaRoot/tools.hudson.local.com [[email protected] tools.hudson.local.com]# unzip hudson-3.2.2.war [[email protected] tools.hudson.local.com]# mkdir /usr/local/hudson-home -p
配置husonHome,huson插件会安装到这个路径下
[[email protected] tools.hudson.local.com]# vim /etc/profile # 在末尾增加Hudson_HOME配置 # hudson env export HUDSON_HOME=/usr/local/hudson-home [[email protected] tools.hudson.local.com]# source /etc/profile
3、启动tomcat服务,访问http://tools.hudson.local.com
首次安装:可以直接安装默认勾选的三个插件即可,后面可以在安装完成之后根据需要安装其它的插件.安装完成的界面如下:点击Install,安装完后界面会自行跳转.
安装插件信息查看:http://tools.hudson.local.com/pluginManager/available
配置Hudson
a)系统管理/Configure Security中启动安全配置
注册刚才配置的admin账号.b)全局信息配置,与插件配置 转载请注明出处:[http://www.cnblogs.com/dennisit/p/4547087.html]
时间: 2024-09-30 23:56:52