Skip to content

Instantly share code, notes, and snippets.

View ntnguyencse's full-sized avatar
💭
I may be slow to respond.

Nguyen Thanh Nguyen (Andy) ntnguyencse

💭
I may be slow to respond.
  • @juyoutech
  • Ho Chi Minh
  • 09:51 (UTC +07:00)
View GitHub Profile
@ntnguyencse
ntnguyencse / docker-compose.yml
Created July 24, 2024 07:32 — forked from kizzx2/docker-compose.yml
Restart a docker container periodically with docker-compose
version: '3'
services:
app:
image: nginx:alpine
ports: ["80:80"]
restart: unless-stopped
restarter:
image: docker:cli
volumes: ["/var/run/docker.sock:/var/run/docker.sock"]
@ntnguyencse
ntnguyencse / HOWTO.md
Created January 24, 2024 05:55 — forked from cvan/HOWTO.md
How to serve a custom HTTPS domain on GitHub Pages with CloudFlare: *FREE*, secure and performant by default

Instructions

CloudFlare is an awesome reverse cache proxy and CDN that provides DNS, free HTTPS (TLS) support, best-in-class performance settings (gzip, SDCH, HTTP/2, sane Cache-Control and E-Tag headers, etc.), minification, etc.

  1. Make sure you have registered a domain name.
  2. Sign up for CloudFlare and create an account for your domain.
  3. In your domain registrar's admin panel, point the nameservers to CloudFlare's (refer to this awesome list of links for instructions for various registrars).
  4. From the CloudFlare settings for that domain, enable HTTPS/SSL and set up a Page Rule to force HTTPS redirects. (If you want to get fancy, you can also enable automatic minification for text-based assets [HTML/CSS/JS/SVG/etc.], which is a pretty cool feature if you don't want already have a build step for minification.)
  5. If you
title Engineering Blogs
published true
description
tags engineering, learning
cover_image

I'm always interested in learning, especially around my roles in engineering and leadership.

@ntnguyencse
ntnguyencse / kubernetes1.28.sh
Created August 31, 2023 02:47 — forked from saiyam1814/kubernetes1.28.sh
kubernetes1.28.sh
echo "step1- install kubectl,kubeadm and kubelet 1.28.0"
curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add -
echo "deb https://apt.kubernetes.io/ kubernetes-xenial main" | sudo tee /etc/apt/sources.list.d/kubernetes.list
echo "kubeadm install"
sudo apt update -y
sudo apt -y install vim git curl wget kubelet=1.28.0-00 kubeadm=1.28.0-00 kubectl=1.28.0-00
echo "memory swapoff"
sudo sed -i '/ swap / s/^\(.*\)$/#\1/g' /etc/fstab
@ntnguyencse
ntnguyencse / kubernetes1.27.sh
Created August 31, 2023 02:47 — forked from saiyam1814/kubernetes1.27.sh
kubernetes1.27.sh
echo "step1- install kubectl,kubeadm and kubelet 1.27.1"
curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add -
echo "deb https://apt.kubernetes.io/ kubernetes-xenial main" | sudo tee /etc/apt/sources.list.d/kubernetes.list
echo "kubeadm install"
sudo apt update -y
sudo apt -y install vim git curl wget kubelet=1.27.1-00 kubeadm=1.27.1-00 kubectl=1.27.1-00
echo "memory swapoff"
sudo sed -i '/ swap / s/^\(.*\)$/#\1/g' /etc/fstab
@ntnguyencse
ntnguyencse / Git-signing.md
Last active March 30, 2023 07:54 — forked from paolocarrasco/README.md
How to understand the `gpg failed to sign the data` problem in git

Problem

You have installed GPG, then tried to commit and suddenly you see this error message after it:

error: gpg failed to sign the data
fatal: failed to write commit object

Debug