Skip to content

Instantly share code, notes, and snippets.

@marwein
marwein / Microsoft Office 2019 RTM GVLK Keys
Created January 7, 2019 09:30
Microsoft Office 2019 RTM default #GVLK (Generic Volume License Key)
GVLKs for KMS and Active Directory-based activation of Office 2019 and Office 2016
Applies to: Volume licensed versions of Office 2019 and Office 2016, including Project and Visio
By default, volume licensed versions of Office 2019 and Office 2016 are installed with a Generic Volume License Key (GVLK).
The GVLK enables Office to automatically discover and activate against your KMS host computer or Active Directory infrastructure.
Important
These license keys can't be used to activate your personal copy of Office.
@darencard
darencard / entware_synology.md
Last active July 16, 2026 11:05
Setting up and using Entware on Synology device
@superseb
superseb / defaultdns.md
Last active April 25, 2025 12:16
Change default DNS nameserver used by Kubernetes pods

Change default DNS nameserver used by Kubernetes pods

This can be applied generically but usually applies to Linux nodes that have a local caching nameserver running, which means pointing to an IP in the loopback range (127.0.0.0/8). Ubuntu 18.04 Bionic Beaver does this by default.

Option 1: Change host configuration

sudo systemctl mask systemd-resolved
rm -f /etc/resolv.conf
sudo ln -s /run/systemd/resolve/resolv.conf /etc/resolv.conf
@dragonken
dragonken / .vimrc
Last active September 27, 2025 02:53
YAML space indent for vim
syntax on
filetype plugin indent on
"Get the 2-space YAML as the default when hit carriage return after the colon
autocmd FileType yaml setlocal ts=2 sts=2 sw=2 expandtab
set is hlsearch ai ic scs
nnoremap <esc><esc> :nohls<cr>
"https://vim.fandom.com/wiki/Moving_lines_up_or_down
@stefanvangastel
stefanvangastel / docker-load-and-push.sh
Last active March 9, 2023 23:19
Bash scripts to pull, (optional) retag, save, load and push Docker images. Created to provide easy means to download an image, retag it to use a private registry and then save it to an external disk. In a offline or on-premise environment you can use the load and push script to load images and push them to a private registry.
#!/bin/bash
#### Functions ###
display_usage() {
echo "This script must be run with Docker capable privileges and you should login to your registry before pushing!"
echo -e "\nUsage:\n$0 <saved_image> [--push]\n"
echo -e " <saved_image>\t\t\tThe image file to load and push"
echo -e " [--push]\t\t\tPush to registry"
echo -e "\nExample: $0 /mydir/ubuntu.tar --push "
}
@muendelezaji
muendelezaji / bash-to-zsh-hist.py
Created October 5, 2016 14:18 — forked from op/bash-history-to-zsh-history.py
Convert Bash history to Zsh history
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# This is how I used it:
# $ cat ~/.bash_history | python bash-to-zsh-hist.py >> ~/.zsh_history
import sys
import time
@cnio
cnio / docker create user in home directory
Created April 21, 2016 07:10
docker create user in home/
# in dockerfile
RUN useradd -ms /bin/bash new_user_name
# in cli
useradd -ms /bin/bash new_user_name
@mszynka
mszynka / README.md
Created March 30, 2016 18:57
Custom login message (motd) script

#Custom login message

Example

Last login: Wed Oct 22 21:12:10 2015 from *****
  ___  ___ _____                     _  
  |  \/  |/  ___|                   | | 
  | .  . |\ `--.  ____ _   _  _ __  | | __  __ _ 
  | |\/| | `--. \|_  /| | | || `_ \ | |/ / / _` |
  | |  | |/\__/ / / / | |_| || | | ||   < | (_| |
  \_|  |_/\____/ /___| \__, ||_| |_||_|\_\ \__,_|

__/ |

@meinside
meinside / smartctl_test.md
Last active May 19, 2026 20:16
For checking health of usb hdd on raspberry pi with smartctl.

for testing external hdd with smartctl,

install smartmontools

$ sudo apt-get install smartmontools

start test,

@fokayx
fokayx / git_remote_set-url.md
Last active July 14, 2026 05:27
Git switch remote URLs. Git 更換遠端伺服器倉庫網址

Git 更換遠端伺服器倉庫網址URL

1.確認目前Git遠端伺服器網址: git remote -v

git remote -v
origin  https://github.com/USERNAME/REPOSITORY.git (fetch)
origin  https://github.com/USERNAME/REPOSITORY.git (push)

2.更換Git遠端伺服器位網址,使用:git remote set-url