--- #################################################################### # WARNING: These are designed specifically for Ansible tests # # and should not be used as examples of how to write Ansible roles # #################################################################### # test code for the npm module # Copyright (c) Ansible Project # GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt) # SPDX-License-Identifier: GPL-3.0-or-later # ------------------------------------------------------------- # Setup steps - when: - not (ansible_facts.os_family == 'Alpine') # TODO block: # expand remote path - command: 'echo {{ remote_tmp_dir }}' register: echo - set_fact: remote_dir: '{{ echo.stdout }}' - include_tasks: run.yml vars: nodejs_version: '{{ item }}' nodejs_path: 'node-v{{ nodejs_version }}-{{ ansible_facts.system|lower }}-{{ nodejs_arch }}' nodejs_arch: '{{ "x64" if ansible_architecture == "x86_64" else "arm64" if ansible_architecture in ("arm64", "aarch64") else ansible_architecture }}' nodejs_ext: '{{ ".tar.xz" if ansible_system == "Linux" else ".tar.gz" }}' nodejs_download: 'https://nodejs.org/dist/v{{ nodejs_version }}/{{ nodejs_path }}{{ nodejs_ext }}' with_items: - 16.20.2 # oldest node version with macOS arm64 support