nodejs-installed

Description

Install nodejs.

Variables

Name Type Default Description

version

string 10.x

The version of nodejs to install.

Code

doc:
  short_help: Install nodejs.

args:
  version:
    doc:
      short_help: The version of nodejs to install.
    type: string
    required: false
    default: 10.x
  user:
    doc:
      short_help: The user to install nodejs for.
    type: string
    required: false

frecklets:
- frecklet:
    name: geerlingguy.nodejs
    type: ansible-role
    properties:
      idempotent: true
      internet: true
    desc:
      short: 'install nodejs (version: {{:: version ::}})'
  task:
    become: true
  vars:
    nodejs_version: '{{:: version ::}}'
frecklecute nodejs-installed --help

Usage: frecklecute nodejs-installed [OPTIONS]

  Install nodejs.

Options:
  --version VERSION  The version of nodejs to install.
  --help             Show this message and exit.
# -*- coding: utf-8 -*-


#
# module path: pycklets.nodejs_installed.NodejsInstalled
#


from dataclasses import dataclass
from pyckles import AutoPycklet
from typing import *    # noqa

@dataclass
class NodejsInstalled(AutoPycklet):
    """Install nodejs.

       Args:
         version: The version of nodejs to install.

    """

    FRECKLET_ID = "nodejs-installed"

    version: str = None


    def __post_init__(self):
        super(NodejsInstalled, self).__init__(var_names=["version"])


frecklet_class = NodejsInstalled
# -*- coding: utf-8 -*-


#
# module path: pycklets.nodejs_installed.NodejsInstalled
#


from pyckles import AutoPycklet

class NodejsInstalled(AutoPycklet):
    """Install nodejs.

       Args:
         version: The version of nodejs to install.

    """

    FRECKLET_ID = "nodejs-installed"

    def __init__(self, version="10.x"):

        super(NodejsInstalled, self).__init__(var_names=["version"])
        self._version = version

    @property
    def version(self):
        return self._version

    @version.setter
    def version(self, version):
        self._version = version



frecklet_class = NodejsInstalled