Skip to content

Instantly share code, notes, and snippets.

View jnbdz's full-sized avatar
👨‍💻
None stop

JN Σ jnbdz

👨‍💻
None stop
View GitHub Profile
@jnbdz
jnbdz / php-fpm-cli
Last active August 29, 2015 14:26 — forked from muhqu/php-fpm-cli
#!/bin/bash
#
# The MIT License (MIT)
#
# Copyright (c) 2014 Mathias Leppich <mleppich@muhqu.de>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
#! /bin/sh
#
# Downloaded from:
# http://bazaar.launchpad.net/~ubuntu-branches/ubuntu/trusty/supervisor/trusty/view/head:/debian/supervisor.init
#
# skeleton example file to build /etc/init.d/ scripts.
# This file should be used to construct scripts for /etc/init.d.
#
# Written by Miquel van Smoorenburg <miquels@cistron.nl>.
# Modified for Debian
@jnbdz
jnbdz / JsScrollBar.js
Last active October 27, 2015 18:55
Vanilla ScrollBar
var isInt = function(n) {
return n % 1 === 0;
},
isFloat = function(n) {
return n === Number(n) && n % 1 !== 0;
};
function isFunction(functionToCheck) {
var getType = {};
return functionToCheck && getType.toString.call(functionToCheck) === '[object Function]';
var dialClock = function(rotate) {
var dial = document.getElementById('dial-clock'),
ctx = dial.getContext('2d'),
angle,
secHandLength = 360,
bigDegNum = (isInt(rotate) || isFloat(rotate))?rotate:3,
smallDegNum = (isInt(rotate) || isFloat(rotate))?rotate * 5:15;
ctx.clearRect(0, 0, dial.width, dial.height);
zone "one.example.com" {
type master;
file "/etc/bind/zones/db.one.example.com"; # zone file path
# allow-transfer { 10.128.20.12; }; # ns2 private IP address - secondary
};
zone "8.10.in-addr.arpa" {
type master;
file "/etc/bind/zones/db.10.8"; # 10.8.0/24 subnet
# allow-transfer { 10.128.20.12; }; # ns2 private IP address - secondary
acl "trusted" {
# 127.0.0.1;
10.8.0/24;
# 10.8.1.0/24;
};
options {
directory "/var/cache/bind";
recursion yes; # enables resursive queries
$TTL 604800
@ IN SOA one.example.com. admin.one.example.com. (
3 ; Serial
604800 ; Refresh
2419200 ; Retry
604800 ) ; Negative Cache TTL
; name servers
IN NS ns1.one.example.com.
; PTR Records
$TTL 604800
@ IN SOA ns1.one.example.com. admin.one.example.com. (
3 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ; Negative Cache TTL
)
;
; name servers - NS records
@jnbdz
jnbdz / db.jn
Created January 13, 2016 23:33
;
; BIND data file for TLD ".jn"
;
$TTL 604800
@ IN SOA jn. root.jn. (
2 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
@jnbdz
jnbdz / .vimrc
Created January 21, 2016 11:45
.vimrc 2016
set nocompatible " be iMproved, required
filetype off " required
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" alternatively, pass a path where Vundle should install plugins
"call vundle#begin('~/some/path/here')
" let Vundle manage Vundle, required