Skip to content

Instantly share code, notes, and snippets.

View bitoiu's full-sized avatar

Vitor Monteiro bitoiu

View GitHub Profile
@bitoiu
bitoiu / docker-compose.yml
Last active August 2, 2024 19:26
Graylog docker-compose for Synology DSM 7 deployment
# My article on this:
# I use PUID and PGID as environments variables, but I removed it from this snipped
# Change the passwords especially if this is externally exposed
# TIP: It takes a while for the graylog interface to come up, so check for errors and be patient
version: "3.7"
services:
mongo:
container_name: mongo
image: mongo:4.4.18
@bitoiu
bitoiu / MyToken.sol
Created January 25, 2018 15:47 — forked from anonymous/MyToken.sol
Created using browser-solidity: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://ethereum.github.io/browser-solidity/#version=soljson-v0.4.19+commit.c4cbbb05.js&optimize=false&gist=
//contract FixedSupplyToken is ERC20Interface, Owned {
//https://ethernaut.zeppelin.solutions/
contract MyToken {
uint totalTokens;
uint tokenCost;
mapping(address => uint) reserve;
mapping(address => uint) balances;
mapping(address => Account) accounts;
@bitoiu
bitoiu / Wallet.sol
Created January 25, 2018 14:41 — forked from anonymous/Wallet.sol
Created using browser-solidity: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://ethereum.github.io/browser-solidity/#version=soljson-v0.4.19+commit.c4cbbb05.js&optimize=false&gist=
contract Wallet {
address owner;
address approver;
unit amountToWithdrawal;
function Wallet(address app) {
owner = msg.sender;
approver = app;
}
@bitoiu
bitoiu / test_webhookwithlambaproxy.json
Last active October 24, 2017 10:42
Webhook Processing (API Gateway + Lambda + DynamoDB + GH Pages)
{
"resource":"/webhook",
"path":"/webhook",
"httpMethod":"POST",
"headers":
{
"X-GitHub-Delivery":"1230123",
"X-GitHub-Event":"member",
"User-Agent":"bitoiu"
}
@bitoiu
bitoiu / electron-prerequisites.md
Created September 7, 2017 12:23 — forked from hollenberry/electron-prerequisites.md
Electron Workshop Prerequisites

Prerequisites

  • Install Git
  • Get familiar with Git commands
  • Install a text editor
  • Install Node.js

Install Git

macOS

@bitoiu
bitoiu / keybase.md
Created July 5, 2017 13:00
keybase.md

Keybase proof

I hereby claim:

  • I am bitoiu on github.
  • I am bitoiu (https://keybase.io/bitoiu) on keybase.
  • I have a public key whose fingerprint is 9B63 F4AB FA86 00C7 7D75 B64E 14A8 1C60 DE06 F469

To claim this, I am signing this object:

@bitoiu
bitoiu / template.sh
Created December 30, 2015 18:19
Bash GitHub Enterprise setup
echo "Configuring GitHub Enterprise"
ghehost=`terraform output ghehost`
ghepass=`terraform output ghehost-admin-password`
gheport=8443
echo "Checking for GitHub Enterprise availability..."
for i in `seq 1 100`;
do
@bitoiu
bitoiu / lunch-options.md
Last active May 2, 2017 19:13
Stonehouse Vitor Monteiro: 12th December Lunch time
Name Starter Main Pudding
Nuno Partridge & pheasant terrine Baked Cod Fillet Banoffee pie
Fiona Partridge & pheasant terrine Baked Cod Fillet Jude's ice cream & sorbet
Nick Soup Roast Turkey Sticky Toffee Pudding
Sophonn Partridge & pheasant terrine Rib eye steak with salad and peppercorn sauce Banoffee Pie
Peter Partridge & pheasant terrine Rib eye steak with salad and peppercorn sauce Banoffee pie
Vitor Partridge & pheasant terrine Porcini Mushroom and Mascarpone Risotto Banoffee Pie
Bianca Partridge & pheasant terrin
@bitoiu
bitoiu / GithubPullRequestDeficiencies.md
Created October 23, 2015 15:55 — forked from skingsland/GithubPullRequestDeficiencies.md
Reasons why Crucible/Fisheye is better than Github (Enterprise) Pull Requests for reviewing code

GENERAL:

  • You can't include commits from different repos in a single code review using github pull requests, whereas you can with Crucible code reviews.
  • It's risky to use a pull request for code that isn't ready to be merged yet. What if someone doesn't see the "DON'T MERGE" comment/title, and clicks the big green merge button?

VIEWING:

  • You can't adjust the line width in which files are displayed, even if you make your browser window wider than the page. Some XML/HTML content extends well past 80 characters.
    • There are numerous Chrome extensions which purport to provide this feature, but I haven't been able to get any of them to work for gh:e.
  • You can't choose to ignore white space, so if a change involved indenting a lot of lines, you'll have a hard time figuring out what changed. In Crucible, you can choose to ignore white space.
  • You can't see the full file name, if the file name and path are longer than ~70 characters, and the HTML element that contains the file name is absolutely sized so y
@bitoiu
bitoiu / self-signed-wildcard-cert-for-ghes.md
Last active November 5, 2024 09:48
Self-Signed Wildcard certificate with SAN using openssl / SSL

Copy the default template of openssl.cnf to a writable location.

cp /System/Library/OpenSSL/openssl.cnf src

Uncomment the req_extensions = v3_req

req_extensions = v3_req # The extensions to add to a certificate request

Add subjectAltName to v3_req section