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

Fix #169 -- add systemd env options #174

Closed
wants to merge 1 commit into from

Conversation

ghost
Copy link

@ghost ghost commented Nov 17, 2023

What type of PR is this?

  • bug
  • cleanup
  • documentation
  • [ X] feature

What this PR does / why we need it:

It adds the optional ability to add and configure an rke-{server,agent} systemd environment file to /etc/default

Which issue(s) this PR fixes:

Fixes #169

Release Notes

Add the ability to optionally create an /etc/default/rke-{server,agent} file to configure the systemd file for proxy information.


# See https://docs.rke2.io/advanced#configuring-an-http-proxy
# Add proxy information for the systemd environment
# systemd-extra-env:

Choose a reason for hiding this comment

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

Suggested change
# systemd-extra-env:
# systemd_extra_env:


- name: Add the systemd env file
ansible.builtin.blockinfile:
path: /etc/default/rke2-{{ caller_role_name }}

Choose a reason for hiding this comment

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

Suggested change
path: /etc/default/rke2-{{ caller_role_name }}
path: /etc/default/rke2-{{ rke2_common_caller_role_name }}


# See https://docs.rke2.io/advanced#configuring-an-http-proxy
# Add proxy information for the systemd environment
# systemd-extra-env:

Choose a reason for hiding this comment

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

Suggested change
# systemd-extra-env:
# systemd_extra_env:

{% for item in systemd_extra_env %}
{{ item }}
{% endfor %}
- name: Reload the systemd daemon

Choose a reason for hiding this comment

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

Maybe is it better to use handlers ?

@aleiner
Copy link
Contributor

aleiner commented Jun 21, 2024

address via #242 due to rework

@aleiner aleiner closed this Jun 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Request for Clarification [setting proxy information]
2 participants