Skip to content

Instantly share code, notes, and snippets.

Avatar
💭
🎾

John dmpe

💭
🎾
View GitHub Profile
View gist:61783eb65a9bae7ca77f2945aa06e773
<md:EntitiesDescriptor xmlns="urn:oasis:names:tc:SAML:2.0:metadata" xmlns:md="urn:oasis:names:tc:SAML:2.0:metadata" xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" Name="urn:keycloak"><md:EntityDescriptor xmlns="urn:oasis:names:tc:SAML:2.0:metadata" xmlns:md="urn:oasis:names:tc:SAML:2.0:metadata" xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" entityID="http://localhost:8080/auth/realms/master"><md:IDPSSODescriptor WantAuthnRequestsSigned="true" protocolSupportEnumeration="urn:oasis:names:tc:SAML:2.0:protocol"><md:KeyDescriptor use="signing"><ds:KeyInfo><ds:KeyName>EQxZBqlBK1w6iOgQhC2mXTMfx--u8xJlJIpMA2AhaWo</ds:KeyName><ds:X509Data><ds:X509Certificate>MIICmzCCAYMCBgF3xjnmxDANBgkqhkiG9w0BAQsFADARMQ8wDQYDVQQDDAZtYXN0ZXIwHhcNMjEwMjIxMjAxMTU5WhcNMzEwMjIxMjAxMzM5WjARMQ8wDQYDVQQDDAZtYXN0ZXIwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQC8R0SUTnrveqtW8jcmsPM43CcngxQIB/7dS1tWd1MA6OvZRPofW+833qdCadowyfHhJqLcKRUCvS35j53jQZJiP
View example.ign
{
"ignition": {
"version": "3.2.0"
},
"passwd": {
"users": [
{
"groups": [
"sudo",
"docker"
@dmpe
dmpe / import_certificate.sh
Created Mar 9, 2020
citrix - ssl cert cannot be trusted - tested on ubuntu
View import_certificate.sh
#!/bin/bash
cert_name=""
mv $cert_name /opt/Citrix/ICAClient/keystore/cacerts
/opt/Citrix/ICAClient/util/ctx_rehash
@dmpe
dmpe / backup.ps1
Created Dec 28, 2019
Azure Key Vault - Backup secrets using powershell (core) - Uses newer az Module
View backup.ps1
[string]$VaultName = 'keyvault'
Get-AzKeyVaultSecret -VaultName $VaultName |
ForEach-Object {
Backup-AzKeyVaultSecret `
-VaultName $VaultName `
-Name $_."Name" `
-OutputFile ('/home/jm/Documents/azure-keyvault-backups/{0}.blob' -f $_."Name")
}
@dmpe
dmpe / branch_cleanup.sh
Created May 24, 2019
delete remote and locale devel-cur-* branch
View branch_cleanup.sh
# https://stackoverflow.com/questions/2003505/how-do-i-delete-a-git-branch-locally-and-remotely
release_in_question="9.0.3.290.02"
future_release=""
git checkout master
# get latest from remote
git pull origin pull
@dmpe
dmpe / Dockerfile
Last active Jun 10, 2019
Neverfinished Dockerfile for jupyterhub with selected plugins/extensions. Using this nginx config and jupyter_conf.py I can guarantee that it is going to work on a Ubuntu server, on a subdomain.
View Dockerfile
############
### We must build our own image, conda is a no go
# https://gist.github.com/affixalex/97bc870e478b4f77a161e5fb2d63ec6d
# https://hub.docker.com/r/jupyterhub/jupyterhub/dockerfile
#######
FROM jupyterhub/jupyterhub:latest
USER root
RUN pip3 install oauthenticator ipywidgets nbdime ipyleaflet ipympl jupyterlab-git jupyterlab_sql jupyterlab_code_formatter \
@dmpe
dmpe / startup_ubuntu.sh
Last active Apr 14, 2019
A post script which installs some basic tools for Ubuntu OS
View startup_ubuntu.sh
#!/bin/bash
sudo apt update
sudo apt upgrade -y
sudo apt install -y wget curl
cd Downloads/
# Chrome
wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
View pima-indians-diabetes.csv
6 148 72 35 0 33.6 0.627 50 1
1 85 66 29 0 26.6 0.351 31 0
8 183 64 0 0 23.3 0.672 32 1
1 89 66 23 94 28.1 0.167 21 0
0 137 40 35 168 43.1 2.288 33 1
5 116 74 0 0 25.6 0.201 30 0
3 78 50 32 88 31.0 0.248 26 1
10 115 0 0 0 35.3 0.134 29 0
2 197 70 45 543 30.5 0.158 53 1
8 125 96 0 0 0.0 0.232 54 1
@dmpe
dmpe / airquality.csv
Created Feb 22, 2018
Air quality New York data 1973 from datasets R library
View airquality.csv
Ozone Solar.R Wind Temp Month Day
1 41 190 7.4 67 5 1
2 36 118 8 72 5 2
3 12 149 12.6 74 5 3
4 18 313 11.5 62 5 4
5 NA NA 14.3 56 5 5
6 28 NA 14.9 66 5 6
7 23 299 8.6 65 5 7
8 19 99 13.8 59 5 8
9 8 19 20.1 61 5 9
@dmpe
dmpe / swiss_religion2.csv
Created Jan 5, 2018
swiss_religion2.csv
View swiss_religion2.csv
Catholic Place Protestant LabelCatholic LabelProtestant
1 9.96 Courtelary 90.04 Catholic 9.96 % Protestant 90.04 %
2 84.84 Delemont 15.16 Catholic 84.84 % Protestant 15.16 %
3 93.4 Franches-Mnt 6.6 Catholic 93.4 % Protestant 6.6 %
4 33.77 Moutier 66.23 Catholic 33.77 % Protestant 66.23 %
5 5.16 Neuveville 94.84 Catholic 5.16 % Protestant 94.84 %
6 90.57 Porrentruy 9.43 Catholic 90.57 % Protestant 9.43 %
7 92.85 Broye 7.15 Catholic 92.85 % Protestant 7.15 %
8 97.16 Glane 2.84 Catholic 97.16 % Protestant 2.84 %
9 97.67 Gruyere 2.33 Catholic 97.67 % Protestant 2.33 %