agent_disenable

pdk
tasks
A task to enable or disable the Puppet agent
Gabe Schuyler

Gabe Schuyler

gabe

1,293 downloads

1,293 latest version

5.0 quality score

Version information

  • 1.0.0 (latest)
released Dec 30th 2019
This version is compatible with:
  • Puppet Enterprise 2019.8.x, 2019.7.x, 2019.5.x, 2019.4.x, 2019.3.x, 2019.2.x, 2019.1.x, 2019.0.x, 2018.1.x, 2017.3.x, 2017.2.x, 2017.1.x, 2016.5.x, 2016.4.x
  • Puppet >= 3.0.0 < 7.0.0
  • RedHat
    ,
    CentOS
    ,
    Debian
    ,
    Ubuntu
    ,
    Solaris
    ,
    AIX
    ,
    Amazon
    ,
    Raspbian
    ,
    Windows
Tasks:
  • agent_disenable

Start using this module

Documentation

gabe/agent_disenable — version 1.0.0 Dec 30th 2019

Overview

This task makes it easy to enable or disable a Puppet agent remotely. It simply runs the puppet agent --enable or puppet agent --disable command for you on the remote host. You can optionally supply a message for a disabled agent to report when someone tries to run the disabled agent.

Parameters

The task takes one required parameter, and optionally a second.

action (required)

Set to enable or disable to put the agent in the desired state.

message (optional)

An optional message to append to the --disable flag.

Usage

Puppet Enterprise console

Once the module is available in your production code environment, it will become available in the console and you can use it just like any other task.

Command Line

You'll need to supply the parameters on the command line, as in the following two examples.

bolt task run agent_disenable action=disable message='hand edits rock' \
  --user root --password --targets ssh://kermit,ssh://gonzo,ssh://animal

bolt task run agent_disenable action=enable \
  --user Administrator --password --targets winrm://hoggle,winrm://bowie