Skip to content

Instantly share code, notes, and snippets.

View EronWright's full-sized avatar

Eron Wright EronWright

View GitHub Profile
@EronWright
EronWright / index.ts
Created February 14, 2020 04:28
Pulumi example for GKE Workload Identity
/*
Creates a GCP service account named 'test-workload-identity' to be used
by a GKE workload using a Kubernetes service account named 'default/default'.
*/
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const gcpConfig = new pulumi.Config("gcp");
const projectId = gcpConfig.get("project");
@EronWright
EronWright / ca-certificate.ts
Last active January 28, 2022 15:26
Generate a CA Certificate using Pulumi
/*
Copyright (c) 2020 StreamNative. All rights reserved.
This work is licensed under the terms of the MIT license.
For a copy, see <https://opensource.org/licenses/MIT>.
*/
import * as pulumi from "@pulumi/pulumi";
import * as tls from "@pulumi/tls";
@EronWright
EronWright / --output.log
Last active December 5, 2017 00:41
Example of forcing a specific snapshot version
$ gradlew --version
------------------------------------------------------------
Gradle 3.5
------------------------------------------------------------
$ gradlew dependencies --configuration compile
:dependencies
------------------------------------------------------------
@EronWright
EronWright / README.md
Last active September 15, 2021 19:03
Simple Maven repository hosted on Apache httpd web server

Simple Maven Repository

Hosting a shared Maven repository on a remote server may be accomplished with a simple web server such as Apache HTTP server. This works because most of the resolution and publishing logic of Maven is implemented in the client. That said, it works only if you know the groupId and artifactId to be published, since appropriate directories must be created by hand.

Do consider using more sophisticated server software such as Artifactory or Sonatype Nexus. Below is the 'bare minimum' alternative.

Caution: this example exposes a writable directory without any authentication, and thus assumes a trusted network.

@EronWright
EronWright / mesos-on-ubuntu.md
Last active June 3, 2020 13:49
Setup Mesos on Ubuntu 16 (Dev Setup)

Configure Mesos

These instructions are derived from those in the Mesos Community Documentation.

Do the below as root.

Install

cat <<EOF >> /etc/apt/sources.list.d/mesosphere.list
deb http://repos.mesosphere.com/ubuntu xenial main
@EronWright
EronWright / Account.java
Last active June 28, 2016 22:17
Account.java - Sample code for instructional purposes
public class Account {
private String accountNumber;
public Account(String accountNumber) {
// Constructor
this.accountNumber = accountNumber;
}
public String getAccountNumber() {
@EronWright
EronWright / homebrew-apache-flink.md
Last active May 12, 2016 18:19
HOWTO - Homebrew Formula for Apache-Flink
@EronWright
EronWright / EMC_Root_CA.crt
Last active May 17, 2016 21:55
My Ubuntu 16 setup script
-----BEGIN CERTIFICATE-----
MIIDajCCAlKgAwIBAgIQDnpJf/sai2ikg8QrEDRcejANBgkqhkiG9w0BAQUFADA9
MQswCQYDVQQGEwJVUzEYMBYGA1UEChMPRU1DIENvcnBvcmF0aW9uMRQwEgYDVQQD
EwtFTUMgUm9vdCBDQTAeFw0xMTAzMDgwMjM1MThaFw0yNjAzMDgwMjM1MThaMD0x
CzAJBgNVBAYTAlVTMRgwFgYDVQQKEw9FTUMgQ29ycG9yYXRpb24xFDASBgNVBAMT
C0VNQyBSb290IENBMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAwEV0
QaykbhIOVKj1BunB8pXsISlXgiv10QSGSxG2Dnbwoli0WSgPpLqPD8bsQuwjReg0
ERGXTXpxDEpb4Kya+YcIr4KGMd+EIdLjogXnrKv1/EWa54UNNjNLU6tkwEnVQ79p
Sbx2weCxEi+VG755+Bbb5AJKDcgk4ss5hXjI8tOzAgHe+tReNQamMSOgCO+4bZJ1
RBalcYHmGxVz2TbK0qrKKC7Um4ALQfRQejB+TuvYMoTZHD8Wm/e3Hdq7wwTOmQUL
@EronWright
EronWright / gist:cb5fb9af46fd810194f8
Created July 2, 2015 14:54
Demonstration of limitation on column pruning for transformed dataframes
import org.apache.spark.ml.feature.StringIndexer
import org.apache.spark.{SparkConf, SparkContext}
import org.apache.spark.sql.sources.{PrunedScan, BaseRelation}
import scala.language.existentials
import org.apache.spark.rdd.RDD
import org.apache.spark.sql._
import org.apache.spark.sql.types._