大网数据广告活动
服务器运维问答

Does Puppet 4 include Code Manager?

· 52CE 我爱测

I've been reading about using R10K with Puppet to manage my environments with git. According to this blog some of the functionality of R10K was built into later versions of puppet: Because R10k was so popular and widely deployed,…

问题原文

原帖链接 · Philip Kirkbride · CC BY-SA 3.0

I've been reading about using R10K with Puppet to manage my environments with git.

According to this blog some of the functionality of R10K was built into later versions of puppet:

Because R10k was so popular and widely deployed, an environment solution that was a simple step-up from an R10k deployment was made the target, and directory environments were born.

This led me to question if I should use R10K. So I started reading about the use of control repos in the Puppet documentation. According to the documentation I can either use R10K or Code Manager:

If you already have a Puppetfile, you can now configure code management. Code management configuration steps differ, depending on whether you’re using Code Manager (recommended) or r10k.

I had never heard of Code Manager so I went to the page describing Code Manager in the Puppet documentation. According to this page Code Manager uses R10K under the hood.

I'm getting the impression from the documentation that Code Manager is now a built in feature of Puppet? Is this the case or is it something that needs to be installed?

Note: I'm using the community version of Puppet not enterprise.

已采纳解答

原帖链接 · Peter Souter · CC BY-SA 3.0

Code Manager is a PE only feature, it's not built into Puppet.

Code Manager is basically an API that gets triggered when events happen on your Git server.

Example Workflow with Gitlab:

  • Someone merges a pull-request into the production branch of the control repo
  • Gitlab fires off a JSON payload at the code manager API
  • The code manager API reads the payload, sees that it's for the production branch
  • Code manager triggers an R10k Run for the production branch

I'm simplifying, as there's other steps (error checking, authentication etc) but that's essentially what's happening.

For open-source users, there's a less featured Code Manager like tool in the r10k repo: https://github.com/voxpupuli/puppet-r10k#webhook-support

It works in a similar way, but it's has less features and is not officially supportable. But it's a similar workflow: Sinatra app listens for JSON Payloads, when it receives one it triggers and R10k run for the given branch.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2017-04-27)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 3.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。