Skip to content

Instantly share code, notes, and snippets.

View brunohulk's full-sized avatar

Bruno Borges brunohulk

View GitHub Profile
#vagrant global-status -> Status of the vagrant's boxes
#Create a vagrant file
vagrant init
#Vagrant file sample
Vagrant.configure("2") do |config|
config.vm.box = "rbayliss/PHP53"
config.vm.network "forwarded_port", guest: 80, host: 8080
@brunohulk
brunohulk / Recreate container
Last active October 18, 2022 15:05
Recreate docker containers
docker-compose rm --all && docker-compose pull && docker-compose build --no-cache && docker-compose up -d --force-recreate
@brunohulk
brunohulk / tcmp+dmp
Created January 23, 2018 14:10
Getting started TCP dump
2009 #tcpdump dst
2012 tcpdump dst 192.168.0.123
2013 tcpdump dst host 192.168.0.123
2014 tcpdump -nn dst host 192.168.0.123
2015 tcpdump -nn -X #N para de resolver ip NN IP e porta
2016 tcpdump -nn dst host 192.168.0.123
2017 tcpdump -nnvv dst host 192.168.0.123
2018 tcpdump -nnvvA port 5000 #VVV verbose
2019 tcpdump -nnvvA port 50000 #A ler o paylod do pacote
2020 tcpdump -nnvvA port 50000 > /tmp/teste
@brunohulk
brunohulk / gist:91fe9c0e7a936815d06e48f26fc4140e
Last active August 6, 2021 07:49
Basic structure for a project
src/
Domain/
Entity/
ValueObject/
Factory/
Service/
Repository/
Persistence/
Repository/
ssh -fNg -L 8080:0.0.0.0:82 [email protected] (Ip de destino)
Redireciona as requisições que chegam na porta 8080 para porta 82 no servidor 190.217.79.90
syntax on
set nu
colorscheme desert
version: '2'
services:
# MongoDB: https://hub.docker.com/_/mongo/
mongo:
image: mongo:3
# Elasticsearch: https://www.elastic.co/guide/en/elasticsearch/reference/5.5/docker.html
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:5.6.9
environment:
- http.host=0.0.0.0