Skip to content

Commit

Permalink
Add python > 3.9 support
Browse files Browse the repository at this point in the history
  • Loading branch information
tbauriedel committed Sep 19, 2024
1 parent e364f71 commit c7c2ea9
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 2 deletions.
3 changes: 2 additions & 1 deletion plugins/module_utils/influxdb2_organization.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
#
# http://www.apache.org/licenses/LICENSE-2.0

from typing import List
from influxdb_client import Organization
from ansible_collections.tbauriedel.influxdb2.plugins.module_utils.api import (
Api
Expand Down Expand Up @@ -88,7 +89,7 @@ def update(self, id) -> Organization:
def delete(self, id):
return self.client.delete_organization(org_id=id)

def get_all(self) -> list[Organization]:
def get_all(self) -> List[Organization]:
return self.client.find_organizations()

def get_by_id(self, id) -> Organization:
Expand Down
14 changes: 13 additions & 1 deletion roles/influxdb2/tasks/install.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
---
- name: Ensure InfluxDB packages are installed
- name: Install python3 packages
ansible.builtin.package:
name:
- python3
- python3-pip
state: present

- name: Install influxb-client for python
ansible.builtin.pip:
name: influxdb-client
state: present

- name: Install InfluxDB
ansible.builtin.package:
name: "{{ item }}"
state: present
Expand Down

0 comments on commit c7c2ea9

Please sign in to comment.