Skip to content

Instantly share code, notes, and snippets.

View afonsoaugusto's full-sized avatar
👾
SRE & DevOps

Afonso Rodrigues afonsoaugusto

👾
SRE & DevOps
View GitHub Profile
I. Base de Código
Uma base de código com rastreamento utilizando controle de revisão, muitos deploys
II. Dependências
Declare e isole as dependências
III. Configurações
Armazene as configurações no ambiente
IV. Serviços de Apoio
@afonsoaugusto
afonsoaugusto / Springer Text books.txt
Created April 28, 2020 17:51
Springer Text books
S.No. Book Title Author Edition OpenURL
1
Fundamentals of Power Electronics
Robert W. Erickson, Dragan
Maksimovic
2nd ed.
2001 http://link.springer.com/openurl?genre=book&isbn=978-0-306-48048-5
2
Handbook of the Life Course
Jeylan T. Mortimer, Michael J.
# docker run --rm -it -e 'ACCEPT_EULA=Y' -e 'SA_PASSWORD=Q3e3nrZQEBx7VmxbqhQFK7ddwg' -p 1433:1433 mcr.microsoft.com/mssql/server
create database permissions CONTAINMENT = PARTIAL;
use permissions;
CREATE USER Barry WITH PASSWORD = 'sdjklalie8rew8337!$d';
select containment,name from sys.databases;
create schema app_barry;

Example code

cd /home/training/udacity_training
[training@localhost udacity_training]$ head -50 data/purchases.txt | ./code/mapper.py | sort | ./code/reducer.py 

[training@localhost udacity_training]$ pwd
/home/training/udacity_training
@afonsoaugusto
afonsoaugusto / gitprint.js
Created March 28, 2020 22:05 — forked from beevelop/gitprint.js
Print GitHub markdown files
document.querySelector('#readme').setAttribute('style', 'position: absolute; top: 0; left: 0; right: 0; bottom: 0; z-index: 100; background-color: white')
document.querySelector('body').appendChild(document.querySelector('#readme'))
window.print()
@afonsoaugusto
afonsoaugusto / api.py
Created March 24, 2020 21:12
Example API Flask Python with APM Elastic
import logging
from flask import Flask, make_response
from elasticapm.contrib.flask import ElasticAPM
from elasticapm.handlers.logging import LoggingHandler
app = Flask(__name__)
apm = ElasticAPM(app)
@app.route("/")
sudo apt-get install ascii2uni
file=$(cat log | ascii2uni -a U -q)
echo -e $file
https://amazon.qwiklabs.com/
Faqs:
https://aws.amazon.com/pt/ec2/faqs/
https://aws.amazon.com/pt/s3/faqs/
https://aws.amazon.com/pt/vpc/faqs/
https://aws.amazon.com/pt/route53/faqs/
https://aws.amazon.com/pt/rds/faqs/
https://aws.amazon.com/pt/sqs/faqs/
#!/bin/bash
#_______________________________________________________________________________
#__
#__ collect.sh
#__
#__ Faz a coleta de network provindo do sar
#__
#__ autor : Afonso Rodrigues
#__ data : 27/08/2019
#__
docker run --rm \
-p "8300:8300" \
-p "8400:8400" \
-p "8500:8500" \
-p "8600:53/udp" \
consul \
agent -dev -client 0.0.0.0