Command | Description |
---|---|
curl -sSL https://get.docker.com/ | sh |
Install Docker |
docker run --rm -it -v /var/run/docker.sock:/var/run/docker.sock docker |
Run Docker-outside-docker |
docker exec -u 0 -i -t 12ef720c4caf /bin/bash -c "export TERM=xterm; exec bash" |
Enable ROOT with TERM - Ref |
docker ps -a | grep -v CONTAINER | awk '{print $1}' | xargs -n1 docker rm -f |
RM all instances |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wmic /output:sysinfo.html cpu get /format:hform >> nul & wmic /append:sysinfo.html computersystem get /format:hform >> nul |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt-get install -y git unzip libunwind8 gettext libssl-dev libcurl4-openssl-dev zlib1g libicu-dev uuid-dev | |
sudo apt-get install -y nodejs npm | |
sudo ln -s /usr/bin/nodejs /usr/sbin/node | |
sudo apt-get -y install mosquitto-clients | |
# Setup libcurl | |
sudo apt-get -y install make automake libtool curl | |
curl -sSL https://github.com/libuv/libuv/archive/v1.8.0.tar.gz | sudo tar zxfv - -C /usr/local/src |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
openssl req -newkey rsa:2048 -x509 -nodes -sha512 -days 365 -extensions v3_ca -keyout ca.key -out ca.crt -subj "/CN=wavebroker-ca/O=aspnet" | |
openssl genrsa -out server.key 2048 | |
openssl req -out server.csr -key server.key -new -subj "/CN=localhost/O=aspnet" | |
openssl x509 -req -in server.csr -CA ca.crt -CAkey ca.key -CAcreateserial -out server.crt -days 365 | |
chmod 444 ca.crt | |
chmod 444 server.crt | |
openssl genrsa -out client.key 2048 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ssh-keygen -l -E md5 -f ~/.ssh/id_rsa.pub |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#preview | |
curl https://dotnetcli.blob.core.windows.net/dotnet/preview/Binaries/1.0.0-preview2-002990/dotnet-dev-ubuntu-x64.1.0.0-preview2-002990.tar.gz | tar xvz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo mkdir -p /etc/docker/certs.d/myregistry.azurecr.io | |
curl "http://www.microsoft.com/pki/mscorp/msitwww2(1).crt" \ | |
| sudo openssl x509 -inform der -outform pem -out /etc/docker/certs.d/myregistry.azurecr.io/ca.crt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Diagnostics; | |
using System.IO; | |
using System.Threading.Tasks; | |
namespace Hub | |
{ | |
class DockerCliClient | |
{ |
Quick references - https://danielmiessler.com/study/tmux/#gs.DCu=kaY
acr=`az acr credential show -n $registryName --output json`
username=$(echo $acr | jq -r '.username')
password=$(echo $acr | jq -r '.password')
kubectl create secret docker-registry acr-secret --docker-server $registryEndpoint--docker-username `echo $acr | jq -r '.username'` --docker-password `echo $acr | jq -r '.password'` --docker-email [email protected]
secret "acr-secret" created