Skip to content

Instantly share code, notes, and snippets.


Phil Huang pichuang

View GitHub Profile
View Azure Playground Roles
"id": "/subscriptions/964df7ca-3f8/providers/Microsoft.Authorization/roleDefinitions/fd429c21-039b-4ba7-bfb3-f791a6ce8e94",
"properties": {
"roleName": "Starkiller",
"description": "see:",
"assignableScopes": [
"permissions": [
pichuang / autounattend.xml
Last active June 13, 2022 02:31
Default Values for TKG Windows Nodes
View autounattend.xml
<?xml version="1.0" encoding="utf-8"?>
<unattend xmlns="urn:schemas-microsoft-com:unattend">
<settings pass="windowsPE">
<component name="Microsoft-Windows-PnpCustomizationsWinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS"
<PathAndCredentials wcm:action="add" wcm:keyValue="A">
View webserver-simple-deployment.yaml
apiVersion: apps/v1
kind: Deployment
name: webserver-simple-deployment
replicas: 2
app: webserver-simple-app
View gist:e111702aaf3602a8111dda2ff1e443a0
fdisk -l
df -h
fdisk /dev/sda
pvcreate /dev/sda3
vgdisplay | grep "VG Name"
vgextend ubuntu-vg /dev/sda3
lvdisplay | grep "LV Path"
lvextend /dev/ubuntu-vg/ubuntu-lv /dev/sda3
View squid.conf
$ cat squid.conf
# Recommended minimum configuration:
# allow all requests
acl all src
http_access allow all
# And finally deny all other access to this proxy
View vmrest-cannot-poweron
$ tail -f /Users/pichuang/Library/Logs/VMware\ Fusion/vmware-vmfusion.log
2022-02-10T08:12:59.643Z In(05) VMware Fusion VMMgr::OpenVM (cfgPath=/Users/pichuang/vm_pool/CentOS 7 64-bit.vmwarevm/CentOS 7 64-bit.vmx)
2022-02-10T08:12:59.664Z In(05) host-24220517 /Users/pichuang/vm_pool/CentOS 7 64-bit.vmwarevm/CentOS 7 64-bit.vmx: Reloading config state.
2022-02-10T08:12:59.671Z In(05) host-24220517 VMHS: Transitioned vmx/execState/val to poweredOff
2022-02-10T08:12:59.680Z In(05) RemoteDeviceMgr VTHREAD 123145527058432 "RemoteDeviceMgr" tid 24220520
2022-02-10T08:12:59.680Z In(05) vigorCnx VTHREAD 123145527595008 "vigorCnx" tid 24220521
2022-02-10T08:12:59.682Z In(05) VMware Fusion SnapshotTree: Emitting refresh (/Users/pichuang/vm_pool/CentOS 7 64-bit.vmwarevm/CentOS 7 64-bit.vmx)
2022-02-10T08:12:59.684Z In(05) vigorCnx VigorOfflineGetToolsVersion: updated tools version to 0
2022-02-10T08:12:59.685Z In(05) VMware Fusion ReadProxyFile: Failed to read file: /etc/vmware/hostd/proxy.xml
2022-02-10T08:12:59.692Z In
pichuang / fluent.conf
Created January 3, 2022 06:33
Tanzu Kubernetes Grid - VMware Log Insight
View fluent.conf
@id in_tail_container_logs
@type tail
path /var/log/containers/*.log
pos_file /var/log/fluentd-containers.log.pos
tag raw.kubernetes.*
read_from_head true
# Open below line if you need have filename as tag field (now without prefix kubernetes.)
# path_key tag
View prepare-tce-v0.10.0-rc.2-on-docker.txt
Phase 1
# Install an NTP Server with Chrony on Ubuntu 20.04
sudo timedatectl set-timezone Asia/Taipei
sudo apt update
sudo apt install chrony -y
sudo systemctl start chronyd
sudo systemctl status chronyd
sudo timedatectl set-timezone Asia/Taipei
sudo apt update
sudo apt install chrony -y
sudo systemctl start chronyd
sudo systemctl status chronyd
sudo timedatectl set-ntp true
sudo systemctl restart chronyd
chronyc activity
pichuang / octant-workflow
Created November 30, 2021 15:15
View octant-workflow
tee /usr/lib/systemd/system/octant.service <<-'EOF'