Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

several FAQ updates and clarifications #41841

Merged
merged 1 commit into from
Jul 2, 2018
Merged

Conversation

bcoca
Copy link
Member

@bcoca bcoca commented Jun 22, 2018

SUMMARY
ISSUE TYPE
  • Docs Pull Request
COMPONENT NAME

faq

ANSIBLE VERSION
any

@bcoca bcoca requested a review from acozine June 22, 2018 14:43
@ansibot ansibot added affects_2.7 This issue/PR affects Ansible v2.7 docs This issue/PR relates to or includes documentation. needs_triage Needs a first human triage before being processed. support:core This issue/PR relates to code supported by the Ansible Engineering Team. labels Jun 22, 2018
@s-hertel s-hertel removed the needs_triage Needs a first human triage before being processed. label Jun 22, 2018

.. code-block:: jinja

{{ ansible_env.SOME_VARIABLE }}

If you need to set environment variables for TASK execution, see the Advanced Playbooks section about environments.
There is no set way to set environment variables on your target machines, you can use tempalte/replace/other modules to do so,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo here s/tempalte/template/g

Yes! Ansible, Inc makes a great product that makes Ansible even more powerful
and easy to use. See :doc:`../reference_appendices/tower`.
Yes! Ansible, Inc makes a great product that makes Ansible even more powerful and easy to use. See :doc:`../reference_appendices/tower`.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should probably remove the "Ansible, Inc" reference if we're making changes to this line.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Red Hat inc?

so you can use this for custom modules written in any scripting language and control the interpreter location.

Keep in mind that if you put `env` in your module shebang line (`#!/usr/bin/env <other>`),
this facility will be ignored so you will be at the mercy of the remote `$PATH`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not clear on the breadth of the warning about using env in the shebang line - will that cause problems only with non-Python scripts/modules? Or will it disrupt the Ansible's ability to find any interpreter that is not on the connection user's $PATH?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it will disrupt the usage of ansible_<interpreter>_interpreter vars for any module that uses env

@acozine
Copy link
Contributor

acozine commented Jun 22, 2018

Useful additions, thanks. I've added a couple of minor comments.

@bcoca bcoca merged commit d497eba into ansible:devel Jul 2, 2018
@bcoca bcoca deleted the remove_vars branch July 2, 2018 14:47
@ansible ansible locked and limited conversation to collaborators Jul 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
affects_2.7 This issue/PR affects Ansible v2.7 docs This issue/PR relates to or includes documentation. support:core This issue/PR relates to code supported by the Ansible Engineering Team.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants