Skip to content

Instantly share code, notes, and snippets.

// ==UserScript==
// @name noVNC Paste
// @include https://portal.arpnetworks.com/noVNC/console?*
// @version 1.0
// ==/UserScript==
function sendString () {
var str = prompt("Please enter a string to paste");
if (!str)
return;
#!/usr/bin/python3
try:
from configparser import RawConfigParser as ConfigParser
except ImportError:
from ConfigParser import ConfigParser
class T(ConfigParser):
def __init__(self, conf_dir=None):
ConfigParser.__init__(self, {"a": "False"})
#!/bin/sh -e
# Email used for registration and recovery contact.
EMAIL=""
BASEDIR="%%ETCDIR%%"
SSLDIR="%%PREFIX%%/etc/ssl/lego"
DOMAINSFILE="${BASEDIR}/domains.txt"
if [ -z "${EMAIL}" ]; then
@mhoran
mhoran / periodic.conf
Last active April 16, 2019 14:35
Configuration for lego peroidic script
# generate two certificates
weekly_lego_certificates="one two"
# account for the certificates
weekly_lego_account="matt@matthoran.com"
# default flags if not overridden per certificate
weekly_lego_global_flags="--path /usr/local/etc/ssl/lego --email ${weekly_lego_account} --http --http.webroot /usr/local/www/acme"
weekly_lego_renew_flags="--days 30"
@mhoran
mhoran / tarsnap.user.js
Last active April 14, 2019 01:21
Tarsnap Account Activity
// ==UserScript==
// @name Tarsnap Account Activity
// @namespace https://gist.github.com/mhoran/
// @include https://www.tarsnap.com/manage.cgi?address=*
// @version 1.0
// ==/UserScript==
by_machine_view = document.body.innerHTML.indexOf('usage by machine') > -1;
verbose_view = document.body.innerHTML.indexOf('account activity (verbose)') > -1;
package main
import (
"fmt"
"net/http"
"os"
"time"
)
func main() {
index d8e31a8..a0cfd53 100644
--- a/CircuitBreaker/src/AspDotNet4/FortuneTeller/Fortune-Teller-UI4/appsettings.json
+++ b/CircuitBreaker/src/AspDotNet4/FortuneTeller/Fortune-Teller-UI4/appsettings.json
@@ -12,6 +12,9 @@
}
},
"hystrix": {
+ "stream": {
+ "validate_certificates": false
+ },
<?xml version="1.0" encoding="utf-8"?>
<unattend xmlns="urn:schemas-microsoft-com:unattend">
<!--
For more information about unattended.xml please refer too
http://technet.microsoft.com/en-us/library/cc722132(v=ws.10).aspx
-->
<settings pass="generalize">
<component name="Microsoft-Windows-PnpSysprep" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<PersistAllDeviceInstalls>true</PersistAllDeviceInstalls>
</component>
PS C:\users\Administrator\go\src\code.cloudfoundry.org\winc> ginkgo -r -race -keepGoing
[1501770861] Winc Suite - 73/73 specs time="2017-08-03T07:35:00-07:00" level=error msg="json: cannot unmarshal array into Go value of type hcsshim.HNSEndpoint"
------------------------------
+ [SLOW TEST:8.462 seconds]
Create when provided valid arguments creates and starts a container
C:/users/Administrator/go/src/code.cloudfoundry.org/winc/cmd/winc/create_test.go:78
------------------------------
time="2017-08-03T07:35:04-07:00" level=error msg="json: cannot unmarshal array into Go value of type hcsshim.HNSEndpoint"
+ Failure [18.273 seconds]
#!/usr/bin/env bash
keyauth="string-from-acme-client"
_sed() {
if [[ "${OSTYPE}" = "Linux" ]]; then
sed -r "${@}"
else
sed -E "${@}"
fi