su¶
Collection Note
This module is part of the ansible.builtin collection. To install the collection, use:
Added in version2.8.
Synopsis¶
- This become plugin allows your remote/login user to execute commands as another user via the su utility.
Parameters¶
| Parameter | Defaults / Choices | Comments |
|---|---|---|
| become_exe | Default: su |
Su executable Env: ANSIBLE_BECOME_EXE Env: ANSIBLE_SU_EXE |
| become_flags | Options to pass to su Env: ANSIBLE_BECOME_FLAGS Env: ANSIBLE_SU_FLAGS |
|
| become_pass | Password to pass to su Env: ANSIBLE_BECOME_PASS Env: ANSIBLE_SU_PASS |
|
| become_user | Default: root |
User you 'become' to execute the task Env: ANSIBLE_BECOME_USER Env: ANSIBLE_SU_USER |
| prompt_l10n list / elements=string |
List of localized strings to match for prompt detection If empty we'll use the built in one Do NOT add a colon (:) to your custom entries. Ansible adds a colon at the end of each prompt; if you add another one in your string, your prompt will fail with a "Timeout" error. Env: ANSIBLE_SU_PROMPT_L10N |
Authors¶
- Ansible (@core)