Skip to content

Instantly share code, notes, and snippets.

View acidtib's full-sized avatar

Dainel Vera acidtib

View GitHub Profile
@acidtib
acidtib / step.md
Created September 12, 2020 21:02 — forked from evenchange4/step.md
Deploy a Express.js project on Heroku

Deploy a Express.js project on Heroku

Step by step from command line by Michael Hsu

Quick start

Create a Node.js web framework 'express'

$ express myfirstexpress && cd myfirstexpress

Declare dependencies with NPM /package.json

@acidtib
acidtib / traefik_portainer.md
Created June 25, 2020 02:32 — forked from ruanbekker/traefik_portainer.md
Traefik with SSL + Portainer on Docker Swarm Repro

Traefik and Portainer on Docker Swarm with Letsencrypt

Reproducing a Traefik with SSL and Portainer setup on a 2 Node Docker Swarm

Install Docker:

Install Docker on both nodes with a Bootstrap Script:

$ curl https://gitlab.com/rbekker87/scripts/raw/master/setup-docker-ubuntu.sh | bash
@acidtib
acidtib / gitflow-breakdown.md
Created March 16, 2017 16:47 — forked from JamesMGreene/gitflow-breakdown.md
A comparison of using `git flow` commands versus raw `git` commands.

Initialize

gitflow git
git flow init git init
git commit --allow-empty -m "Initial commit"
git checkout -b develop master

Connect to the remote repository

Ever wondered how much who adds/removes, its time to find out :D (those are real stats, i just obfuscated the names )

###Results

Git scores (in LOC):
mr-add              :  +482273       -9466
justu               :  +286250       -159905
grosser             :  +152384       -323344

another : +121257 -82116

#!/bin/bash
#
# Blog post @ https://blog.kylemanna.com/sharing/gogo-inflight-wireless-with-openvpn/
#
# Bail on errors
set -e
SERVER_IP=$(host myip.opendns.com. resolver1.opendns.com | awk '/has address/ { print $4 }')
@acidtib
acidtib / deis-v1-to-v2-cheatsheet.md
Created September 28, 2016 01:53 — forked from olalonde/deis-v1-to-v2-cheatsheet.md
Deis v1 to v2 cheatsheet

Deis v1 to v2 cheatsheet

Warning: those are personal not, can't guarantee they are correct!

alias kd="kubectl --namespace=deis"

Table of Contents

@acidtib
acidtib / openbazaar-go-ubuntu.md
Created September 25, 2016 20:59 — forked from drwasho/openbazaar-go-ubuntu.md
Install OpenBazaar-Go on a Linux Digital Ocean Droplet

Install OpenBazaar-Go on Linux Digital Ocean Droplet

First off I'm going to assume you have created a user with sudo permissions, and that you're not running from root. I'm also assuming you have a satisfactory knowledge of the Linux terminal/bash commands.

If you have any trouble, join our OpenBazaar Slack group, and pop into the #openbazaar-ipfs channel.

Step 1: Create the install script

  • In your terminal, type: sudo nano install.sh
  • Paste in the following script:
@acidtib
acidtib / fix-homebrew-npm.md
Created August 2, 2016 04:22 — forked from DanHerbert/fix-homebrew-npm.md
Instructions on how to fix npm if you've installed Node through Homebrew on Mac OS X or Linuxbrew

Fixing npm On Mac OS X for Homebrew Users

Installing node through Homebrew can cause problems with npm for globally installed packages. To fix it quickly, use the solution below. An explanation is also included at the end of this document.

Solution

This solution fixes the error caused by trying to run npm update npm -g. Once you're finished, you also won't need to use sudo to install npm modules globally.

Before you start, make a note of any globally installed npm packages. These instructions will have you remove all of those packages. After you're finished you'll need to re-install them.

@acidtib
acidtib / remote-file-exists.php
Created July 27, 2016 19:57 — forked from vyspiansky/remote-file-exists.php
PHP: file_exists for remote URL
<?php
// Source: http://goo.gl/aZ1h8v
$file_headers = @get_headers($url);
if ($file_headers[0] == 'HTTP/1.0 404 Not Found'){
$file_exists = false;
} else {
$file_exists = true;
}
?>