From 9f2d6a159ea3fa62d50ed49e7229f3320ff852ed Mon Sep 17 00:00:00 2001 From: baptou12 Date: Wed, 8 Nov 2023 14:00:39 +0100 Subject: [PATCH] feat: allow minor update --- roles/bootstrap/tasks/install_node.yaml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/roles/bootstrap/tasks/install_node.yaml b/roles/bootstrap/tasks/install_node.yaml index 26d08c20..6469cb02 100644 --- a/roles/bootstrap/tasks/install_node.yaml +++ b/roles/bootstrap/tasks/install_node.yaml @@ -1,14 +1,17 @@ --- +- name: Set NodeJS major version variable + ansible.builtin.set_fact: + node_major_version: "18" - name: Add nodejs apt key ansible.builtin.apt_key: url: https://deb.nodesource.com/gpgkey/nodesource.gpg.key state: present - name: Add nodejs 18.x ppa for apt repo ansible.builtin.apt_repository: - repo: deb https://deb.nodesource.com/node_18.x bullseye main + repo: "deb https://deb.nodesource.com/node_{{ node_major_version }}.x bullseye main" update_cache: true - name: Install nodejs ansible.builtin.apt: update_cache: true name: nodejs - state: present + state: latest