Skip to content

Instantly share code, notes, and snippets.

View fabiocruzcoelho's full-sized avatar
:octocat:

Fabio Coelho fabiocruzcoelho

:octocat:
View GitHub Profile
@fabiocruzcoelho
fabiocruzcoelho / comando-kubectl.md
Last active May 30, 2019 16:07
Sobre o comando kubectl

Sobre kubectl

O utilitário kubectl permite que você interfira com o gerenciador de cluster Kubernetes. Por exemplo, você pode adicionar e excluir nós, pods, controladores de replicação e serviços. Você também pode verificar seu status, e assim por diante.

Comandos Basicos

#Exemplos
kubectl get pv
kubectl get pvc
kubectl get pods
set $mod Mod4
# Font for window titles
font pango: System San Francisco Display 9
# color
set $bg-color #2f343f
set $inactive-bg-color #4b5162
set $text-color #f3f4f5
set $inactive-text-color #f3f4f5
# Shadow
shadow = true;
no-dnd-shadow = true;
no-dock-shadow = true;
clear-shadow = true;
shadow-radius = 7;
shadow-offset-x = -7;
shadow-offset-y = -7;
# shadow-opacity = 0.7;
# shadow-red = 0.0;
[cpu_usage]
command=~/.config/i3blocks/blocks/blocks.sh 1
interval=5
#color=#XXXXXX
[memory_free]
command=~/.config/i3blocks/blocks/blocks.sh 3
interval=5
#color=#XXXXXX
@fabiocruzcoelho
fabiocruzcoelho / generate-ssh-key.sh
Created June 28, 2018 18:10 — forked from grenade/01-generate-ed25519-ssh-key.sh
Correct file permissions for ssh keys and config.
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/id_rsa
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/github_rsa
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/mozilla_rsa
# Stack - Gitlab in kubernetes
## Add Repo
```
helm repo add gitlab https://charts.gitlab.io
```
## Install Gitlab
``helm upgrade -i gitlab -f values.yml gitlab/gitlab-omnibus --namespace agilitystack
``
@fabiocruzcoelho
fabiocruzcoelho / notes_shellscript.md
Created May 9, 2018 14:17
Anotações de Shell Scripts
Anotações sobre estudos de Shell Scripts.
@fabiocruzcoelho
fabiocruzcoelho / notes_python.md
Created May 9, 2018 14:16
Anotações Python

Anotações de estudos sobre python

gc D:\list.txt |test-NetConnection -port 53
Test-PortConnection -Destination DC01 -Ports 363
Test-PortConnection -Destination DC01 -Ports 363,80,1433
Test-PortConnection -Destination DC01,DC02 -Ports 363,80,1433
Test-PortConnection -Destination DC01,DC02 -Ports 363,80 | Export-Csv -Path C:\users\$env:username\desktop\results.csv -NoTypeInformation # Save it to CSV file on your desktop
Test-PortConnection -Destination (GC "C:\Temp\Servers.txt") -Ports 363,80,1433
Test-PortConnection -Destination (GC "C:\Temp\Servers.txt") -Ports 363,80,1433 | Out-GridView -Title "Results" # Display in new pop-up window
https://sid-500.com/2018/02/02/powershell-test-open-tcp-ports-with-test-openport-multiple-hosts-multiple-port-numbers/
http://www.powershellbros.com/test-connection-to-servers-on-several-ports/
[host_group]
host-1 ansible_ssh_host=192.168.0.21 node_name=foo
host-2 ansible_ssh_host=192.168.0.22 node_name=bar
[host_group:vars]
custom_var=asdasdasd
You can access host group vars using:
{{ hostvars['host_group'].custom_var }}