Updated: Dec 21, 2020
I’ve personally used these commands to debug in production. I also used GUI methods like k9s and lenses.io.
kubectl get pods --as-group="somecompany:somecompany-teamname" --as="test"
| #!/bin/bash | |
| # List available platforms for building | |
| docker buildx ls | |
| # Create multiple builder instances to build multi-platform with build command | |
| docker buildx create --use | |
| docker buildx build --platform linux/amd64,linux/arm64 --push -t membermatters/membermatters . | |
| # Build for single platform |
| #!/bin/bash | |
| # List installed JDK versions | |
| /usr/libexec/java_home -V | |
| # Export in current session | |
| export JAVA_HOME=`/usr/libexec/java_home -v <version>` | |
| # Create a function in .bashrc, .zshrc, .zshenv, etc | |
| function switch_openjdk_version() { |
| #!/bin/bash | |
| kubectl autoscale deployment <name-of-deployment> --cpu-percent=75 --min=2 --max=10 |
| #!/bin/bash | |
| # Symlink a file | |
| ln -s [path of the target file] [symbolic name] | |
| # example | |
| ln -s my_folder/my_doc.txt my_document | |
| # Symlink a directory | |
| ln -s source_folder destination_folder |
| select AURORA_VERSION(); | |
| select @@aurora_version; | |
| show variables like '%version'; |
| Application Load Balancer Access Log Headers | |
| type time elb client:port target:port request_processing_time target_processing_time response_processing_time elb_status_code target_status_code received_bytes sent_bytes "request" "user_agent" ssl_cipher ssl_protocol target_group_arn "trace_id" "domain_name" "chosen_cert_arn" matched_rule_priority request_creation_time "actions_executed" "redirect_url" "error_reason" "target:port_list" "target_status_code_list" "classification" "classification_reason" | |
| Network Load Balancer Access Log Headers | |
| type version time elb listener client:port destination:port connection_time tls_handshake_time received_bytes sent_bytes incoming_tls_alert chosen_cert_arn chosen_cert_serial tls_cipher tls_protocol_version tls_named_group domain_name alpn_fe_protocol alpn_be_protocol alpn_client_preference_list | |
| Classic Load Balancer Access Log Headers |
| # Replace string with the Device Instance Path of your choice | |
| pnputil /disable-device "PCI\VEN_10DE&DEV_1FBC&SUBSYS_0A691028&REV_A1\4&30232E66&0&0008" |
| #!/bin/bash | |
| ( | |
| set -x; cd "$(mktemp -d)" && | |
| OS="$(uname | tr '[:upper:]' '[:lower:]')" && | |
| ARCH="$(uname -m | sed -e 's/x86_64/amd64/' -e 's/\(arm\)\(64\)\?.*/\1\2/' -e 's/aarch64$/arm64/')" && | |
| KREW="krew-${OS}_${ARCH}" && | |
| curl -fsSLO "https://github.com/kubernetes-sigs/krew/releases/latest/download/${KREW}.tar.gz" && | |
| tar zxvf "${KREW}.tar.gz" && | |
| ./"${KREW}" install krew |
| Install-Module -Name AWS.Tools.AccessAnalyzer -Confirm:$false | |
| Install-Module -Name AWS.Tools.Account -Confirm:$false | |
| Install-Module -Name AWS.Tools.ACMPCA -Confirm:$false | |
| Install-Module -Name AWS.Tools.AlexaForBusiness -Confirm:$false | |
| Install-Module -Name AWS.Tools.Amplify -Confirm:$false | |
| Install-Module -Name AWS.Tools.AmplifyBackend -Confirm:$false | |
| Install-Module -Name AWS.Tools.AmplifyUIBuilder -Confirm:$false | |
| Install-Module -Name AWS.Tools.APIGateway -Confirm:$false | |
| Install-Module -Name AWS.Tools.ApiGatewayManagementApi -Confirm:$false | |
| Install-Module -Name AWS.Tools.ApiGatewayV2 -Confirm:$false |