Skip to content

Instantly share code, notes, and snippets.

🌐
Terraform again

Afonso Rodrigues afonsoaugusto

🌐
Terraform again
Block or report user

Report or block afonsoaugusto

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View create key ssh for github.txt
ssh-keygen -t rsa -b 4096 -C "email@domain.com.br"
eval "$(ssh-agent -s)"
ssh-add ~/.ssh/id_rsa
sudo apt-get install xclip
sudo yum install xclip
xclip -sel clip < ~/.ssh/id_rsa.pub
View docker-proxysql.yml
version: '3.3'
services:
visualizer:
image: dockersamples/visualizer:stable
ports:
- "8080:8080"
stop_grace_period: 1m30s
volumes:
View docker-compose.yml
apiVersion: apps/v1beta2
kind: Deployment
metadata:
name: myapp
spec:
selector:
matchLabels:
app: myapp
replicas: 2
template:
View Docker-commands.md

Comandos docker treinamento:

[First Alpine Linux Containers][1]

  • Baixa e executa o container
docker container run hello-world
  • Faz o download da imagem:
View db.env
WA_DB_ENGINE=MYSQL
WA_DB_HOSTNAME=db
WA_DB_PORT=3306
WA_DB_USERNAME=root
WA_DB_PASSWORD=testpass
View Config_git_Atom.txt
git config --global user.email "afonsoaugustoventura@gmail.com"
git config --global user.name "Afonso Rodrigues"
git config --global push.default simple
git remote set-url origin git@github.com:afonsoaugusto/report_system_bot.git
ssh-keygen -t rsa -b 4096 -C "afonsoaugustoventura@gmail.com"
eval "$(ssh-agent -s)"
ssh-add ~/.ssh/id_rsa
cat ~/.ssh/id_rsa
sudo apt-get install xclip
xclip -sel clip < ~/.ssh/id_rsa.pub
@afonsoaugusto
afonsoaugusto / report_system_bot.py
Created Nov 11, 2018
Projeto Bot Telegram para report de script no servidor.
View report_system_bot.py
# 1 - Relatórios simples do SO (reports_so.py).
# 2 - Obter o retorno de scripts executados no SO (Linux) (execute_script_so.py)
# 3 - Criar o bot para executar a lib acima (report_system_bot.py)
# 4 - Autenticação do usuário do bot (auth_bot.py)
# 5 - Rodar no Heroku ou Openshift
# 6 - Integrar com Github
# 7 - Rodar CI.
# 8 - GitHubPages.
View snake_pygame.py
import random
import pygame
from pygame.locals import *
SIZE_FRAME = 300
LIMIT_FRAME = SIZE_FRAME-10
def on_grid_random():
x = random.randint(0,LIMIT_FRAME)
y = random.randint(0,LIMIT_FRAME)
@afonsoaugusto
afonsoaugusto / listagg_ordenado.sql
Last active Nov 9, 2018
Remove repetition in result from listagg
View listagg_ordenado.sql
drop table ListAggTest;
CREATE TABLE ListAggTest AS (
SELECT 1 as num1,DECODE(mod(rownum,2),1,'A|B','B|A') Num2 FROM dual CONNECT BY rownum<=10
);
select * from ListAggTest;
/*
NUM1 NUM
---------- ---
View docker
Dashboard Kibpx05
Twitter: #DevopsDayOSS
Docker - https://www.katacoda.com/courses/docker
Docker compose
ssh ip172-18-0-3-bfi3s2iv9dig00ccies0@direct.labs.play-with-docker.com
You can’t perform that action at this time.