BOOM Analytics: Exploring Data-Centric, Declarative Programming for the Cloud
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
#!/usr/bin/env python3 | |
import sys, os | |
import json | |
import requests | |
from argparse import ArgumentParser | |
from enum import Enum | |
def allowlist_append(domain, token, addr): | |
endpoint = f"https://admin.splunk.com/{domain}/adminconfig/v2/access/s2s/ipallowlists" |
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
#!/usr/bin/env python | |
import os | |
import requests | |
import json | |
from datetime import datetime | |
from flask import Flask, jsonify, request | |
app = Flask(__name__) |
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
#!/usr/bin/env python | |
import requests | |
import argparse | |
import json | |
def remove_unwanted_data(data): | |
if 'eai:acl' in data: del data['eai:acl'] | |
if 'pass4SymmKey' in data: del data['pass4SymmKey'] |
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
--- | |
version: "3" | |
services: | |
# utility | |
ouroboros: | |
image: pyouroboros/ouroboros | |
container_name: ouroboros | |
volumes: | |
- /var/run/docker.sock:/var/run/docker.sock | |
environment: |
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
#!/usr/bin/env python | |
import sys, os, getpass | |
import requests, json | |
import random | |
# suppress the warning about unverified https | |
from requests.packages.urllib3.exceptions import InsecureRequestWarning | |
requests.packages.urllib3.disable_warnings(InsecureRequestWarning) |
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 os | |
print('test') | |
print(os.environ) |
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
print("Loading Script") | |
import os | |
import re | |
import json | |
import requests | |
# config | |
host = os.environ['ARTIFACTORY_URL'] | |
username = os.environ['ARTIFACTORY_USER'] |
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
columns => Id,Description,BarId,BarName | |
type Bar struct { | |
id int `db:BarId` | |
name sql.NullString `db:BarName` | |
} | |
type Foo struct { | |
id int `db:Id` | |
description sql.NullString `db:Description` |
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
require 'octokit' | |
require 'influxdb' | |
require 'yaml' | |
influxdb_config_file = File.dirname(File.expand_path(__FILE__)) + '/../config/influxdb.yml' | |
influxdb_config = YAML::load(File.open(influxdb_config_file)) | |
influxdb = InfluxDB::Client.new influxdb_config['database'], | |
username: influxdb_config['username'], | |
password: influxdb_config['password'], |
NewerOlder