update docs
This commit is contained in:
parent
e146973d08
commit
e8a7d948db
|
@ -61,6 +61,15 @@ Optional Parameters:
|
||||||
"ansible_env_vars": [ "ANSIBLE_HOST_KEY_CHECKING=False", "ANSIBLE_SSH_ARGS='-o ForwardAgent=yes -o ControlMaster=auto -o ControlPersist=60s'", "ANSIBLE_NOCOLOR=True" ]
|
"ansible_env_vars": [ "ANSIBLE_HOST_KEY_CHECKING=False", "ANSIBLE_SSH_ARGS='-o ForwardAgent=yes -o ControlMaster=auto -o ControlPersist=60s'", "ANSIBLE_NOCOLOR=True" ]
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
If you are running a Windows build on AWS, Azure or Google Compute and would
|
||||||
|
like to access the auto-generated password that Packer uses to connect to a
|
||||||
|
Windows instance via WinRM, you can use the template variable
|
||||||
|
{{.WinRMPassword}} in this option.
|
||||||
|
For example:
|
||||||
|
|
||||||
|
```json
|
||||||
|
"ansible_env_vars": [ "WINRM_PASSWORD={{.WinRMPassword}}" ],
|
||||||
|
```
|
||||||
|
|
||||||
- `command` (string) - The command to invoke ansible.
|
- `command` (string) - The command to invoke ansible.
|
||||||
Defaults to `ansible-playbook`.
|
Defaults to `ansible-playbook`.
|
||||||
|
@ -78,6 +87,18 @@ Optional Parameters:
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
If you are running a Windows build on AWS, Azure or Google Compute and would
|
||||||
|
like to access the auto-generated password that Packer uses to connect to a
|
||||||
|
Windows instance via WinRM, you can use the template variable
|
||||||
|
{{.WinRMPassword}} in this option.
|
||||||
|
For example:
|
||||||
|
|
||||||
|
```json
|
||||||
|
"extra_arguments": [
|
||||||
|
"--extra-vars", "winrm_password={{ .WinRMPassword }}"
|
||||||
|
]
|
||||||
|
```
|
||||||
|
|
||||||
- `groups` (array of strings) - The groups into which the Ansible host
|
- `groups` (array of strings) - The groups into which the Ansible host
|
||||||
should be placed. When unspecified, the host is not associated with any
|
should be placed. When unspecified, the host is not associated with any
|
||||||
groups.
|
groups.
|
||||||
|
@ -128,13 +149,6 @@ Optional Parameters:
|
||||||
- `user` (string) - The `ansible_user` to use. Defaults to the user running
|
- `user` (string) - The `ansible_user` to use. Defaults to the user running
|
||||||
packer.
|
packer.
|
||||||
|
|
||||||
- `set_winrm_passwd` (boolean) - Set to `true` if you are running on AWS, Azure or
|
|
||||||
Google Compute and would like to access the generated password that Packer uses to
|
|
||||||
connect to the instance via WinRM. The password will be avaliable to the Ansible
|
|
||||||
provisioner through the environment variable `GENERATED_WINRM_PASSWORD`. You will
|
|
||||||
also need to set `ansible_password` in your ansible playbook, for example,
|
|
||||||
`ansible_password: "{{ lookup('env','GENERATED_WINRM_PASSWORD') }}"`
|
|
||||||
|
|
||||||
## Default Extra Variables
|
## Default Extra Variables
|
||||||
|
|
||||||
In addition to being able to specify extra arguments using the
|
In addition to being able to specify extra arguments using the
|
||||||
|
|
Loading…
Reference in New Issue