This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
import json | |
from subprocess import Popen, PIPE | |
class MCollective: | |
def list_hosts(self): | |
process = Popen("mco rpc rpcutil ping -j".split(), stdout=PIPE) | |
j = process.communicate()[0] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define _GNU_SOURCE | |
#include <dirent.h> /* Defines DT_* constants */ | |
#include <fcntl.h> | |
#include <stdio.h> | |
#include <unistd.h> | |
#include <stdlib.h> | |
#include <sys/stat.h> | |
#include <sys/syscall.h> | |
#define handle_error(msg) \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class PowerShellVmsResource { | |
enum Method { GET, ADD }; | |
enum Detail { | |
DISKS("$_.getmemorystatistics(); $_.getcpustatistics(); "), | |
STATISTICS("$_.getdiskimages(); "); | |
public final String powershell; |