Last active
December 26, 2015 15:09
-
-
Save masayuki5160/7170391 to your computer and use it in GitHub Desktop.
Vagrant + Cent OS + Jenkins で検証したときのメモ
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
【環境】 | |
Cent OS 6.4 | |
【インストールとか】 | |
Javaの用意 | |
# yum install java-1.7.0-openjdk.x86_64 | |
Jenkinsの用意 | |
# wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat/jenkins.repo | |
# rpm --import http://pkg.jenkins-ci.org/redhat/jenkins-ci.org.key | |
# yum install jenkins | |
Vagrant側での用意 | |
# vi /etc/sysconfig/iptables | |
で以下一行追加してJenkins用に8080ポートをあける。 | |
-A INPUT -m state --state NEW -m tcp -p tcp --dport 8080 -j ACCEPT | |
VagrantファイルでIP指定してできるように設定(ほかの方法もありますが今回はこれで) | |
config.vm.network :private_network, ip: "192.168.33.12" | |
※コメントアウトしてあるだけと思いますのでそれをはずせば大丈夫なはず | |
Jenkinsを起動 | |
service jenkins start | |
ホストより下記URLへアクセス | |
http://192.168.33.12:8080 | |
※iptablesとかいじってるのでうまくいかないときはvagrant reload等してみてください | |
【参考】 | |
VagrantでCentOSを入れてJenkinsを導入してみる http://t32k.me/mol/log/vagrant1-2-centos6-4-jenkins1-5/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment