Skip to content

Conversation

@pjezek
Copy link
Contributor

@pjezek pjezek commented Oct 2, 2024

Hello

Please review this change:
The {{ [ service_group ] + alloy_user_groups } was replaced to {{ alloy_service_group }} instead of {{ [ alloy_service_group ] + alloy_user_groups }} in c9000d1106232916440b7d26c7da8f98fb5367b2.

Commit c9000d1106232916440b7d26c7da8f98fb5367b2 broke #212
see comments:

Thanks and have a nice day.

@CLAassistant
Copy link

CLAassistant commented Oct 2, 2024

CLA assistant check
All committers have signed the CLA.

@PabloEForgeFlow
Copy link

This should probably be a priority, #209 introduced a regression that breaks support for extra groups. As a result, alloy is unable to extract certain logs at the same time, such as those from docker and some of /var/log, which require groups docker and adm respectively.

@ishanjainn ishanjainn merged commit ecdb42f into grafana:main Oct 15, 2024
@sepulworld
Copy link

This doesn't work...

    "msg": "Group ['alloy', 'adm', 'docker'] does not exist"

It has to be something like

- name: Create alloy user
  ansible.builtin.user:
    name: "{{ alloy_service_user }}"
    group: "{{ alloy_service_group }}"
    groups: "{{ alloy_user_groups | join(',') }}"
    system: true
    create_home: false  # Appropriate for a system user, usually doesn't need a home directory
  become: true

you can't pass a list of groups into the group: input. It needs to go into groups:

ansible.builtin.user:
name: "{{ alloy_service_user }}"
group: "{{ alloy_service_group }}"
group: "{{ [ alloy_service_group ] + alloy_user_groups }}"

Choose a reason for hiding this comment

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

it should be groups:

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.

5 participants