2021/01/04
- GoCD, the CI/CD tool like Jenkins
2021/01/17
!<command prefix letter>
will rerun the last command that starts with this prefix.
2021/01/23
- runbook/playbook is for commonly problems solution and instruction.
2021/01/25
- pipeline
echo 123 |& cat
,|&
means piping message to both stdout and stderr.
2021/01/27
envsubst
command: substitutes environment variables in shell format strings.
2021/04/03
yq
, similar withjq
command but for yaml parsing.
2021/05/11
ps -o etime -o time -p <pid>
, show process the elapsed time since it started, and the cpu time.
2021/09/05
docker container run
is the same asdocker run
docker container run
=docker container create
+docker container start
+ [docker container attach
]
2021/10/06
-
Docker has OS or not? , obviously no, remember docker vs virtual machine. Docker is lightweight virtualization, For Linux docker, the container always runs/shares on linux/host kernel, docker image supplies the necessary files, libs, utilities, etc.
-
We have ubuntu, centos, alpine docker image, they can run in the same host OS, the key differences are filesystem/libraries, they share the host OS kernel. see this post, also see the second answer: “Since the core kernel is common technology, the system calls are expected to be compatible even when the call is made from an Ubuntu user space code to a Redhat kernel code. This compatibility make it possible to share the kernel across containers which may all have different base OS images.”
-
Docker run on MacOS, Docker on Mac actually creates a Linux VM by
LinuxKit
and containers run on it.
2021/10/31
- DNS record type
TXT
andA
:TXT
is for owner custom info,A
is IP hostname mapping.
2021/12/25
- Why
ls -l
does not show group name: because of aliasalias ls="ls -G"
,-G
will suppress the group name in long format, using/bin/ls -l
instead.