1. 程式人生 > >Jenkins(十)配置檔案分析

Jenkins(十)配置檔案分析

一、安裝檔案的資訊

/etc/init.d/jenkins檔案,檔案中有關於Jenkins安裝路徑、以及執行的PID檔案等一些資訊。

二、日誌檔案

/var/log/jenkins該目錄下存放的是伺服器的日誌以及每一個構建的專案的日誌。

/var/lib/jenkins 該目錄是JENKINS_HOME的預設主目錄

/var/cache/jenkins存放的是包相關的資訊

  • Jenkins will be launched as a daemon on startup. See /etc/init.d/jenkins for more details.
  • The 'jenkins' user is created to run this service. If you change this to a different user via the config file, you must change the owner of /var/log/jenkins, /var/lib/jenkins, and /var/cache/jenkins.
  • Log file will be placed in /var/log/jenkins/jenkins.log. Check this file if you are troubleshooting Jenkins.
  • /etc/sysconfig/jenkins will capture configuration parameters for the launch.
  • By default, Jenkins listen on port 8080. Access this port with your browser to start configuration.  Note that the built-in firewall may have to be opened to access this port from other computers.  (See  for instructions how to disable the firewall permanently)
  • A Jenkins RPM repository is added in /etc/yum.repos.d/jenkins.repo

三、伺服器的配置檔案

/etc/sysconfig/jenkins 該檔案中可以設定伺服器的埠,等資訊

四、訪問伺服器

啟動服務之後在瀏覽器中訪問伺服器,如果不能正常的顯示,可能是因為防火牆的原因,可以選擇把防火牆關掉

service iptables save

service iptables stop

chkconfig iptables off