Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/artcom/ansible-role-win-node-app
Ansible role to clone a Node app and install its dependencies on a Windows 10 machine
https://github.com/artcom/ansible-role-win-node-app
Last synced: about 1 month ago
JSON representation
Ansible role to clone a Node app and install its dependencies on a Windows 10 machine
- Host: GitHub
- URL: https://github.com/artcom/ansible-role-win-node-app
- Owner: artcom
- License: mit
- Created: 2020-09-30T12:54:39.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2021-09-17T11:20:57.000Z (over 3 years ago)
- Last Synced: 2024-11-07T06:36:44.967Z (3 months ago)
- Size: 22.5 KB
- Stars: 0
- Watchers: 14
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Node App
Ansible role to clone a Node app and install its dependencies on a Windows 10 machine.## Description
This role will clone a node app from a git repository over https, install Node and the Node app dependencies. Credentials can be passed to the role to install from a private repository. Optionally Node gyp dependencies will be installed.## Requirements
This role requires a reboot handler:
```yaml
- name: reboot
ansible.windows.win_reboot:
```## Role Variables
Available variables are listed below, along with default values `(see defaults/main.yml)`:
```yaml
node_version: null
node_app_path: null
node_app_repo: null
node_app_tag: null
node_app_process: node
use_node_gyp: false
python2_version: null
visual_cpp_build_tools_version: null
```
Required variables (role will fail if the variables are not set):
```yaml
node_version: "string"
node_app_path: "string"
node_app_repo:
url: "string"
private: "boolean"
node_app_tag: "string"
```
Required variables for a private repo (role will fail if the variables are not set):
```yaml
deployment_user: "string"
deployment_password: "string"
```
Required variables when using node_gyp (role will fail if the variables are not set):
```yaml
python2_version: "string"
visual_cpp_build_tools_version: "string"
```## Dependencies
* [check-required-variables](https://github.com/artcom/ansible-role-check-required-variables)# Example Playbook
```yaml
- name: install node app
hosts: allhandlers:
- name: reboot
ansible.windows.win_reboot:tasks:
- ansible.builtin.include_role:
name: win-node-app
vars:
node_version: "14.4.0"
node_app_path: "{{ ansible_user_dir }}/node_app_name"
node_app_repo:
url: "https://github.com/username/node_app_name.git"
node_app_tag: "1.0.0"
```## License
MIT