Skip to content

Instantly share code, notes, and snippets.

Its me. Mario

Henrique Breim breim

Block or report user

Report or block breim

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 gist:7e7079f4bc0d4d1b123d00c347a79f6a
wget -O dsd.tar.gz
tar -xzf dsd-master.tar.gz
cd dsd-master
mkdir build
cd build
sudo make install
View gist:91ba64a546410de55031511317f31593
curl -SL | tar xJv
View gist:464d5d0aa432bd747b9ed45ee8258369
user ubuntu;
worker_processes 1;
#error_log /home/ubuntu/logs/error.log;
#error_log logs/error.log notice;
#error_log logs/error.log info;
#pid logs/;
breim / deploy sh
Last active Mar 4, 2019
Quiz deploy
View deploy sh
sudo apt-get update -y
sudo apt-get upgrade -y
# General dependencies
sudo apt install git curl openssl libcurl4-openssl-dev autoconf nodejs libssl-dev libreadline-dev zlib1g-dev autoconf bison build-essential libyaml-dev libreadline-dev libffi-dev libgdbm-dev
# Rvm
curl -sSL | gpg --import -
curl -L | bash -s stable
source ~/.rvm/scripts/rvm
View gist:678ae68656943d2686d28d26dacb273f
sudo docker build . -t face8
sudo docker run --name face8 -d -p 8081:8081
sudo docker stop face8
sudo docker start face8
sudo docker ps -a
sudo docker run -it face8 bash
sudo docker exec -it face8 bash
View out.log
== Funcionando (POSTMAN)
D, [2018-11-13T16:47:35.397354 #5848] DEBUG -- : [5f552a92-fdb0-4eec-a9bf-24de2eb7de6c] (0.9ms) COMMIT
I, [2018-11-13T16:47:35.403792 #5848] INFO -- : [5f552a92-fdb0-4eec-a9bf-24de2eb7de6c] [active_model_serializers] Rendered VideoSerializer with ActiveModelSerializers::Adapter::Attributes (0.81ms)
D, [2018-11-13T16:47:35.415142 #5848] DEBUG -- : [5f552a92-fdb0-4eec-a9bf-24de2eb7de6c] (0.2ms) BEGIN
D, [2018-11-13T16:47:35.417026 #5848] DEBUG -- : [5f552a92-fdb0-4eec-a9bf-24de2eb7de6c] User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 LIMIT $2 [["id", 1], ["LIMIT", 1]]
D, [2018-11-13T16:47:35.418859 #5848] DEBUG -- : [5f552a92-fdb0-4eec-a9bf-24de2eb7de6c] SQL (0.4ms) INSERT INTO "logs" ("request_url", "status", "ip_request", "user_id", "http_method", "data", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["request_url", ""], ["status", "200"], ["ip_request", "170.78.
breim /
Last active Oct 23, 2018
nginx package daemon
#! /bin/sh
# Provides: nginx
# Required-Start: $all
# Required-Stop: $all
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: starts the nginx web server
# Description: starts nginx using start-stop-daemon
View gist:d301f9c4ea1ad82dcc58e26579bd1c4e
actions: &actions 'Ações'
api_id: &api_id 'API ID (pegar essa informação no whitelabel)'
credentials_link: &credentials 'Credenciais'
description: &info 'Descrição'
destroy_question: &destroy_question 'Você tem certeza?'
docs_link: &docs 'Docs'
email: &email 'E-mail'
home_link: &home 'Home'
View gist:f1fa3bda9b2d49a2d7340d4957f9ae59
ubuntu@ip-172-31-57-145:~$ gem install chili_player
Fetching: chili_player-0.1.2.gem (100%)
Successfully installed chili_player-0.1.2
Parsing documentation for chili_player-0.1.2
Installing ri documentation for chili_player-0.1.2
Done installing documentation for chili_player after 0 seconds
1 gem installed
ubuntu@ip-172-31-57-145:~$ irb
breim / .vimrc
Created Aug 23, 2018 — forked from joegoggins/.vimrc
Mac Vim .vimrc file
View .vimrc
" Use Vim settings, rather then Vi settings (much better!).
" This must be first, because it changes other options as a side effect.
set nocompatible
" ================ General Config ====================
set number "Line numbers are good
set backspace=indent,eol,start "Allow backspace in insert mode
set history=1000 "Store lots of :cmdline history
set showcmd "Show incomplete cmds down the bottom
You can’t perform that action at this time.