The view ClusterRole doesn’t actually have permissions for the Cluster level objects like Nodes and Persistent Volume Claims. So we’ll have to create a new RBAC config.
First, we’ll create a new dashboard-viewonly ClusterRole:
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: dashboard-viewonly
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/sh | |
| [[ $EUID == 0 ]] || { echo "Must be run as root."; exit; } | |
| PKGNAME=AgentUninstaller | |
| LOG=/tmp/$PKGNAME.log | |
| touch $LOG | |
| chmod a+rw $LOG | |
| DAEMON_PLIST="/Library/LaunchDaemons/com.airwatch.airwatchd.plist" |
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 | |
| while IFS= read -e -p "haproxy> " cmd; | |
| do | |
| if [ -z "$cmd" ]; then | |
| continue | |
| fi | |
| history -s "$cmd" | |
| case "$cmd" in |
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 python | |
| import MySQLdb | |
| import os, sys | |
| import pprint | |
| pp = pprint.PrettyPrinter() | |
| mysql_host = "localhost" | |
| mysql_user = "dbusername" | |
| mysql_pass = "dbpassword" |
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
| subnet 192.168.0.0 netmask 255.255.255.0 { | |
| range 192.168.0.100 192.168.0.200; | |
| option broadcast-address 192.168.0.255; | |
| option routers 192.168.0.1; | |
| on commit { | |
| set ClientIP = binary-to-ascii(10, 8, ".", leased-address); | |
| set ClientMac = binary-to-ascii(16, 8, ":", substring(hardware, 1, 6)); | |
| log(concat("Commit: IP: ", ClientIP, " Mac: ", ClientMac, "Hostname: ", host-decl-name)); | |
| execute("/usr/local/bin/dhcp-event", "commit", ClientIP, ClientMac, host-decl-name); | |
| } |
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
| global | |
| ssl-default-bind-options no-sslv3 no-tls-tickets | |
| frontend https | |
| # Bind SSL port with PFS-enabling cipher suite | |
| bind :443 ssl crt path_to_certificate no-tls-tickets ciphers ECDHE-RSA-AES256-GCM-SHA384:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-SHA384:ECDHE-RSA-AES128-SHA256:ECDHE-RSA-AES256-SHA:ECDHE-RSA-AES128-SHA:DHE-RSA-AES-256-SHA256:DHE-RSA-AES-256-CBC-SHA:DHE-RSA-AES-128-CBC-SHA:AES256-GCM-SHA384:AES128-GCM-SHA256:AES256-SHA256:AES128-SHA256:AES256-SHA:AES128-SHA | |
| reqadd X-Forwarded-Proto:\ https | |
| # Add the HSTS header with a 1 year max-age |
