在ubuntu12.04上安装部署foreman

Foreman是一个puppet的全生命周期的管理工具,有点类似于puppet的dashboard前端。本文主要介绍如何在ubuntu 12.04上安装配置foreman.

1.为ubuntu12.04添加foreman的源

#在文件/etc/apt/sources.list的末尾添加如下的地址
deb http://deb.theforeman.org/ precise 1.3

#添加该源对应的key
#其中-O-表示将下载的文件输出到标准终端上,
wget -q http://deb.theforeman.org/foreman.asc -O- | apt-key add -

#更新
apt-get update

至此,foreman的源已经准备完毕。

2.安装foreman

#采用sqllite作为foreman的存储后端
apt-get install foreman foreman-sqlite3

3.配置foreman

#数据库采用默认的/etc/foreman/database.yml

#编辑/etc/foreman/settings.yaml
#your default puppet server - can be overridden in the host level
#if none specified, plain "puppet" will be used.
#:puppet_server: 127.0.0.1
:unattended: true
:puppetconfdir: /etc/puppet/puppet.conf
:login: false
:require_ssl: false
#下载https://raw.github.com/theforeman/puppet-foreman/master/templates/foreman-report_v2.rb.erb
#重命名该文件为/usr/lib/ruby/1.8/puppet/reports/foreman.rb
#编辑foreman.rb
#更改foreman_url为foreman的安装地址,如
#$foreman_url='http://127.0.0.1:3000'

修改puppetmaster的配置文件puppet.conf,添加:

#在main段中添加
reports=log, foreman

修改puppetagent的配置文件puppet.conf,添加

report = true

4.初始化foreman的数据库

#进入到foreman的安装目录
cd /usr/share/foreman

RAILS_ENV=production rake db:migrate

5.启动foreman

service foreman restart

浏览器访问http://127.0.0.1:3000

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值