Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
packer
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kristopher Ruzic
packer
Commits
107309ab
Commit
107309ab
authored
Sep 07, 2013
by
Mitchell Hashimoto
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
website: document the Puppet provisioner
parent
b92aed55
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
90 additions
and
0 deletions
+90
-0
website/source/docs/provisioners/puppet-masterless.html.markdown
.../source/docs/provisioners/puppet-masterless.html.markdown
+89
-0
website/source/layouts/docs.erb
website/source/layouts/docs.erb
+1
-0
No files found.
website/source/docs/provisioners/puppet-masterless.html.markdown
0 → 100644
View file @
107309ab
---
layout
:
"
docs"
page_title
:
"
Puppet
(Masterless)
Provisioner"
---
# Puppet (Masterless) Provisioner
Type:
`puppet-masterless`
The masterless Puppet provisioner configures Puppet to run on the machines
by Packer from local modules and manifest files. Modules and manifests
can be uploaded from your local machine to the remote machine or can simply
use remote paths (perhaps obtained using something like the shell provisioner).
Puppet is run in masterless mode, meaning it never communicates to a Puppet
master.
<div
class=
"alert alert-info alert-block"
>
<strong>
Note that Puppet will
<em>
not
</em>
be installed automatically
by this provisioner.
</strong>
This provisioner expects that Puppet is already
installed on the machine. It is common practice to use the
<a
href=
"/docs/provisioners/shell.html"
>
shell provisioner
</a>
before the
Puppet provisioner to do this.
</div>
## Basic Example
The example below is fully functional and expects the configured manifest
file to exist relative to your working directory:
<pre
class=
"prettyprint"
>
{
"type": "puppet-masterless",
"manifest_file": "site.pp"
}
</pre>
## Configuration Reference
The reference of available configuration options is listed below.
Required parameters:
*
`manifest_file`
(string) - The manifest file for Puppet to use in order
to compile and run a catalog. This file must exist on your local system
and will be uploaded to the remote machine.
Optional parameters:
*
`execute_command`
(string) - The command used to execute Puppet. This has
various
[
configuration template variables
](
/docs/templates/configuration-templates.html
)
available. See below for more information.
*
`module_paths`
(array of strings) - This is an array of paths to module
directories on your local filesystem. These will be uploaded to the remote
machine. By default, this is empty.
*
`prevent_sudo`
(boolean) - By default, the configured commands that are
executed to run Puppet are executed with
`sudo`
. If this is true,
then the sudo will be omitted.
*
`staging_directory`
(string) - This is the directory where all the configuration
of Puppet by Packer will be placed. By default this is "/tmp/packer-puppet-masterless".
This directory doesn't need to exist but must have proper permissions so that
the SSH user that Packer uses is able to create directories and write into
this folder. If the permissions are not correct, use a shell provisioner
prior to this to configure it properly.
## Execute Command
By default, Packer uses the following command (broken across multiple lines
for readability) to execute Puppet:
```
{{if .Sudo}sudo {{end}}puppet apply \
--verbose \
--modulepath='{{.ModulePath}}' \
{{.ManifestFile}}
```
This command can be customized using the
`execute_command`
configuration.
As you can see from the default value above, the value of this configuration
can contain various template variables, defined below:
*
`ManifestFile`
- The path on the remote machine to the manifest file
for Puppet to use.
*
`ModulePath`
- The paths to the module directories.
*
`Sudo`
- A boolean of whether to
`sudo`
the command or not, depending on
the value of the
`prevent_sudo`
configuration.
website/source/layouts/docs.erb
View file @
107309ab
...
...
@@ -43,6 +43,7 @@
<li><a
href=
"/docs/provisioners/shell.html"
>
Shell Scripts
</a></li>
<li><a
href=
"/docs/provisioners/file.html"
>
File Uploads
</a></li>
<li><a
href=
"/docs/provisioners/chef-solo.html"
>
Chef Solo
</a></li>
<li><a
href=
"/docs/provisioners/puppet-masterless.html"
>
Puppet
</a></li>
<li><a
href=
"/docs/provisioners/salt-masterless.html"
>
Salt
</a></li>
<li><a
href=
"/docs/provisioners/custom.html"
>
Custom
</a></li>
</ul>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment