Skip to content

Instantly share code, notes, and snippets.

@santoshhr88
santoshhr88 / generate-certificate-chain.sh
Created January 20, 2021 06:56 — forked from granella/generate-certificate-chain.sh
Create self-signed certificate with root and ca for development
#!/bin/bash
rm *.jks 2> /dev/null
rm *.pem 2> /dev/null
echo "===================================================="
echo "Creating fake third-party chain root -> ca"
echo "===================================================="
# generate private keys (for root and ca)
@santoshhr88
santoshhr88 / openssl-full-chain-trust-website.sh
Created October 23, 2020 04:38 — forked from rms1000watt/openssl-full-chain-trust-website.sh
Openssl get full chain of trust from website
# The first one in that file is the actual cert of the website
# The following ones in that file is the chain. Possibly this should separate full-chain.pem to chain.pem + cert.pem
openssl s_client -host www.google.com -port 443 -showcerts 2>&1 | sed -n '/BEGIN CERTIFICATE/,/END CERTIFICATE/p' > ~/Desktop/full-chain.pem
@santoshhr88
santoshhr88 / setup_kdc.sh
Last active September 13, 2020 11:40 — forked from abajwa-hw/setup_kdc.sh
Setup KDC
# curl -sSL https://gist.github.com/abajwa-hw/bca3d23fe146c3ebd59a9b5fd19480a3/raw | sudo -E sh
export host=$(hostname -f)
export realm=${realm:-CLOUDERA.COM}
export domain=${domain:-cloudera.com}
export kdcpassword=${kdcpassword:-BadPass#1}
set -e
sudo yum -y install krb5-server krb5-libs krb5-auth-dialog krb5-workstation
@santoshhr88
santoshhr88 / setup_knoxSSO_hdp265.sh
Created August 19, 2020 13:19 — forked from abajwa-hw/setup_knoxSSO_hdp265.sh
Setup Knox SSO for Ambari/Ranger/Atlas on HDP 2.6.5
#!/usr/bin/env bash
export cluster_name=$1
export host=$(hostname -f)
export ambari_pass=$2
export knox_ldap_pass=$3
hostname=$(hostname -f)
current_dir=$(pwd)
cd /tmp
#Copy config-update to /tmp
cp /tmp/masterclass/ranger-atlas/HortoniaMunichSetup/config_update.py .