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.template; | |
import com.google.common.collect.ImmutableList; | |
import com.google.common.collect.ImmutableMap; | |
import net.corda.core.messaging.CordaRPCOps; | |
import net.corda.core.messaging.FlowProgressHandle; | |
import net.corda.core.node.NodeInfo; | |
import net.corda.core.identity.CordaX500Name; | |
import net.corda.core.identity.Party; |
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 main | |
import ( | |
"log" | |
"os" | |
"cloud.google.com/go/pubsub" | |
"golang.org/x/net/context" | |
) |
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
FROM gcr.io/google-appengine/jetty | |
ENV NEWRELIC_HOME ${JETTY_BASE}/newrelic | |
ADD helloworld-servlet-1.0-SNAPSHOT.war ${JETTY_BASE}/webapps/root.war | |
ADD ./newrelic ${NEWRELIC_HOME} | |
WORKDIR $JETTY_BASE | |
ENV JAVA_OPTS "${JAVA_OPTS} -javaagent:${NEWRELIC_HOME}/newrelic.jar -agentpath:/opt/cdbg/cdbg_java_agent.so=--log_dir=/var/log/app_engine,--alsologtostderr=true,--cdbg_extra_class_path=/var/lib/jetty/webapps/root/WEB-INF/classes:/var/lib/jetty |
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
runtime: custom | |
env: flex | |
env_variables: | |
DBG_ENABLE: true |
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
#!/bin/bash | |
for PROJECT in $(gcloud projects list --format="value(projectId)") | |
do | |
for CLUSTERZONES in $(gcloud beta container clusters list --project=${PROJECT} --format="csv[no-heading](name,zone)") | |
do | |
# Parse (name,zone) --> $CLUSTER, $LOCATION | |
IFS="," read CLUSTER LOCATION <<<"${CLUSTERZONES}" | |
echo -e "Project: ${PROJECT}" | |
echo -e "Cluster: ${CLUSTER}" |
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 python2 | |
import re | |
import sys | |
# Parse Log lines of the form: "2017-12-17T16:00:00.000000000Z Function execution took X ms, finished with status code: YYY" | |
TIMESTAMP = "(?P<timestamp>20[1-2][0-9]-[0-1][0-9]-[0-3][0-9]T[012][0-9]:[0-6][0-9]:[0-6][0-9].[0-9]{9}Z)" | |
DURATION = "(?P<duration>[0-9]+)" | |
UNITS = "(?P<units>[m]+s)" | |
CODE = "(?P<code>[234][0-9]{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
/* globals exports, require */ | |
//jshint strict: false | |
//jshint esversion: 6 | |
"use strict"; | |
const crc32 = require("fast-crc32c"); | |
const gcs = require("@google-cloud/storage")(); | |
const imagemagick = require("imagemagick-stream"); | |
const root = "[[REPLACE: ${ROOT}]]"; |
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
{ | |
"name": "gcs-downsizer", | |
"version": "0.0.1", | |
"description": "Downsize image files to thumbnails stored to GCS", | |
"scripts": { | |
"start": "node index.js" | |
}, | |
"author": "Your Name <[email protected]>", | |
"dependencies": { | |
"@google-cloud/storage": "1.5.1", |
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
{ | |
// Required arguments | |
serviceName:: error "'name' must be specified", | |
servicePort:: error "'servicePort' must be specified", | |
prefix:: error "'prefix' must be specified", | |
domain:: error "'domain' must be specified", | |
local name(num) = $.prefix + num + “.” + $.domain | |
apiVersion: "extensions/v1beta1", |
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
local ingress = import "./ingress.jsonnet"; | |
ingress + { | |
serviceName:: "multi-domain", | |
servicePort:: 9999, | |
prefix:: [[YOUR-PREFIX]], | |
domain:: [[YOUR-DOMAIN]], | |
} |