This file contains hidden or 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
#!/usr/bin/env bash | |
# Error codes | |
AGENT_NOT_INSTALLED=101 | |
AGENT_NOT_ACTIVE=102 | |
function get_datadog_status() { | |
if command -v systemctl &>/dev/null; then | |
agent_status=$(systemctl status datadog-agent.service 2>/dev/null) | |
if [ $? -ne 0 ]; then |
This file contains hidden or 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
#!/usr/bin/env bash | |
function get_datadog_status() { | |
if command -v systemctl &>/dev/null; then | |
agent_status=$(systemctl status datadog-agent.service 2>/dev/null) | |
if [ $? -ne 0 ]; then | |
echo "Datadog agent not installed" | |
return 1 | |
fi | |
agent_health=$(echo "$agent_status" | awk '/Active:/ {print $2}') |
This file contains hidden or 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
package com.otp; | |
import java.util.*; | |
import software.amazon.awssdk.regions.Region; | |
import software.amazon.awssdk.services.sqs.SqsClient; | |
import software.amazon.awssdk.services.sqs.model.*; | |
public class SQS_Example { | |
public static void main(String[] args) { |
This file contains hidden or 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
{ | |
"domain-c91": { | |
"_mor": { | |
"type": "ClusterComputeResource", | |
"value": "domain-c91" | |
}, | |
"availableField": [ | |
{ | |
"key": 1, | |
"name": "com.rackspace.rpcv.goss", |
This file has been truncated, but you can view the full file.
This file contains hidden or 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
{ | |
"host-88": { | |
"_mor": { | |
"type": "HostSystem", | |
"value": "host-88" | |
}, | |
"availableField": [ | |
{ | |
"key": 1, | |
"name": "com.rackspace.rpcv.goss", |
This file has been truncated, but you can view the full file.
This file contains hidden or 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
{ | |
"vm-213": { | |
"_mor": { | |
"type": "VirtualMachine", | |
"value": "vm-213" | |
}, | |
"availableField": [ | |
{ | |
"key": 1, | |
"name": "com.rackspace.rpcv.goss", |
This file contains hidden or 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
{ | |
"datastore-264": { | |
"_mor": { | |
"type": "Datastore", | |
"value": "datastore-264" | |
}, | |
"availableField": [ | |
{ | |
"key": 1, | |
"name": "com.rackspace.rpcv.goss", |
This file contains hidden or 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
{ | |
"datacenter-42": { | |
"_mor": { | |
"type": "Datacenter", | |
"value": "datacenter-42" | |
}, | |
"availableField": [ | |
{ | |
"key": 1, | |
"name": "com.rackspace.rpcv.goss", |
This file contains hidden or 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
{ | |
"group-d1": { | |
"_mor": { | |
"type": "Folder", | |
"value": "group-d1" | |
}, | |
"availableField": [ | |
{ | |
"key": 1, | |
"name": "com.rackspace.rpcv.goss", |
This file contains hidden or 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
"script": "Set-ExecutionPolicy Bypass -Scope CurrentUser -Force\n[System.Net.ServicePointManager]:: | |
SecurityProtocol = @(\n [System.Net.SecurityProtocolType]::Tls;,\n | |
[System.Net.SecurityProtocolType]::Tls12;\n)\n | |
$ScriptResponse = Invoke-WebRequest \"https://vmc-ssm-agent-install.s3-us-west-2.amazonaws.com/ssm-agent-install.ps1\" | |
-UseBasicParsing\n$Script = [System.Text.Encoding]::UTF8.GetString($ScriptResponse.Content)\n$ScriptBlock = [Scriptblock]::Create($Script)\n | |
Invoke-Command -ScriptBlock $ScriptBlock -ArgumentList | |
($args + @(\"wqdWaDWEe6/KVn6vNxNl\", \"49a31a45-d9b6-4d89-a727-1f9d537646c0\", \"eu-west-2\"))" | |
execution:: 767cf564-41f5-41e0-846e-7f3058c7ac21 |
NewerOlder