Skip to content

Instantly share code, notes, and snippets.

View jgwerner's full-sized avatar
🙃

Greg Werner jgwerner

🙃
View GitHub Profile
@jgwerner
jgwerner / main_gpt.tf
Created February 23, 2023 22:28
Example output of a main.tf file created by ChatGPT
provider "aws" {
region = "us-west-2"
}
resource "aws_vpc" "example" {
cidr_block = "10.0.0.0/16"
tags = {
Name = "example-vpc"
}
}

Keybase proof

I hereby claim:

To claim this, I am signing this object:

@jgwerner
jgwerner / illumidesk-local-style-sheet
Created June 8, 2021 18:12
IllumiDesk custom style sheet
/* stylelint-disable at-rule-empty-line-before,at-rule-name-space-after,at-rule-no-unknown */
@import "~antd/lib/style/color/colors.less";
@theme: default;
// The prefix to use on all css classes from ant.
@ant-prefix: ant;
// An override for the html selector for theme prefixes
@html-selector: html;
@jgwerner
jgwerner / illumidesk-global-style
Created June 8, 2021 18:10
Global style sheet for IllumiDesk
@import "~antd/lib/style/color/colors.less";
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@100;300;500;700;900&display=swap&css');
body{
font-family: 'Inter', sans-serif;
}
:global(.site-layout) :global(.site-layout-background) {
background: @white;
position: relative;
@jgwerner
jgwerner / kecloak_saml_poc.md
Last active February 8, 2022 11:15
Keycloak + JupyterHub + SAML v2.0 PoC

Keycloak + JupyterHub + ingress-nginx + AWS NLB

Overview

We have successfully set up a working version of Keycloak with Kubernetes (we are using AWS EKS) with JupyterHub using the [ingress-nginx)(https://github.com/kubernetes/ingress-nginx) as a reverse proxy. Keycloak is set up with JupyterHub as a standard OIDC client (confidential) and the JupyterHub successfully redirects to the Keycloak page that prompts the user to login. (For FYI this configuration is set up with the GenericOAuthenticator).

The Keyclaok Identity Provider has been tested with multiple third-party SAML IdP's, such as Okta and Auth0. The Keycloak broker successfully connects with the IdP and the user is prompted to add their credentials. After succussfully authenticating, however, the Keycloak service returns:

14:39:41,946 WARN  [org.keycloak.events] (default task-60) type=IDENTITY_PROVIDER_RESPONSE_ERROR
@jgwerner
jgwerner / kc.yaml
Created February 12, 2021 22:27
Keycloak custom helm config
hostAliases: []
commonLabels: {}
commonAnnotations: {}
clusterDomain: cluster.local
extraDeploy: []
image:
registry: docker.io
repository: illumidesk/keycloak
tag: latest
## Specify a imagePullPolicy

IllumiDesk Accessibility Conformance Report

Revised Section 508 Edition

VPAT

Version 2.4 (Revised) – January 2021

Name of Product:

@jgwerner
jgwerner / add_graders.py
Last active January 6, 2021 01:06
add-graders
"""
Creates the shared grader notebook list by looping through a course array and then calls the
grader-setup-service microservice to create the grader notebook for the course if it doesn't exist.
All courses are created as deployments. To fetch a list of grader deployments that should be reflected
then run:
```
kubectl get deployment -n <namespace>
```
@jgwerner
jgwerner / gist:d2436c3006d11c1953a0ab894691d041
Created November 6, 2019 11:40
Alternative to docker images purge to remove dangling images.
# remove docker images by line in text file
# alternative to `docker images purge`
!/bin/bash
images_file=dangling_images.txt
list_dangling_images () {
docker images --filter dangling=true | while read IMAGE_ID; do
>> $images_file
done
# Based in large part from https://github.com/canha/golang-tools-install-script
#!/bin/bash
set -e
VERSION="1.9"
print_help() {
echo "Usage: bash goinstall.sh OPTION"
echo -e "\nOPTIONS:"