diff --git a/local.yml b/local.yml index 1289339..2039c9f 100644 --- a/local.yml +++ b/local.yml @@ -165,6 +165,8 @@ - include_tasks: tasks/workstation/mac-os/software/brew.yml when: ansible_system == "Darwin" + - include_tasks: tasks/workstation/linux/software/nodejs.yml + ## Configuration Tasks ## - include_tasks: tasks/workstation/shared/settings/gnome.yml diff --git a/tasks/workstation/linux/software/nodejs.yml b/tasks/workstation/linux/software/nodejs.yml new file mode 100644 index 0000000..287b4bd --- /dev/null +++ b/tasks/workstation/linux/software/nodejs.yml @@ -0,0 +1,35 @@ +--- +# 20260730 - Hyperling +# Install much more recent Node versions. + +# https://linuxcapable.com/how-to-install-node-js-on-debian-linux/ + +- name: Workstation | Software | NodeJS + block: + + - name: Workstation | Software | NodeJS | Facts + set_fact: + node_version: node_24.x + + - name: Workstation | Software | NodeJS | Old | Remove + package: + name: npm + state: absent + + - name: Workstation | Software | NodeJS | extrepo | Install + package: + name: extrepo + state: present + update_cache: yes + + - name: Workstation | Software | NodeJS | extrepo | Enable {{ node_version }} + shell: "extrepo enable {{ node_version }}" + + - name: Workstation | Software | NodeJS | Install + package: + name: nodejs + state: latest + update_cache: yes + + when: ansible_pkg_mgr == "apt" + and coding == true