Skip to content

Instantly share code, notes, and snippets.

View zigang93's full-sized avatar
😶‍🌫️

Tan Zi Gang zigang93

😶‍🌫️
  • PingSpace
  • Penang , Malaysia
  • 11:00 (UTC +08:00)
View GitHub Profile
@zigang93
zigang93 / pull-run-docker-image.sh
Created August 8, 2024 07:54
Run docker image at background and remove image before deploy
#!/bin/bash
if [ -z "$1" ]; then
echo "Please provide the image registry as the first argument."
exit 1
fi
if [ -z "$2" ]; then
echo "Please provide the image name as the second argument."
exit 1
@zigang93
zigang93 / install.sh
Last active June 30, 2025 08:04
cloudflare ubuntu install
# Add cloudflare gpg key
sudo mkdir -p --mode=0755 /usr/share/keyrings
curl -fsSL https://pkg.cloudflare.com/cloudflare-main.gpg | sudo tee /usr/share/keyrings/cloudflare-main.gpg >/dev/null
# Add this repo to your apt repositories
echo 'deb [signed-by=/usr/share/keyrings/cloudflare-main.gpg] https://pkg.cloudflare.com/cloudflared any main' | sudo tee /etc/apt/sources.list.d/cloudflared.list
# install cloudflared
sudo apt-get update && sudo apt-get install cloudflared