Skip to content

Instantly share code, notes, and snippets.

@arkan
arkan / boot.config
Created March 17, 2016 14:18 — forked from kgersen/boot.config
orange ERL 3 - remplacement complet de la Livebox routeur
firewall {
all-ping enable
broadcast-ping disable
ipv6-receive-redirects disable
ipv6-src-route disable
ip-src-route disable
log-martians enable
name WAN_IN {
default-action drop
description "Packets from Internet to LAN"
@arkan
arkan / gist:d3c341b3012879e2c84c
Created November 25, 2015 14:59 — forked from ericallam/gist:1019446
How to log all queries for a PostgreSQL homebrew install on OS X

Open the postgresql.conf config file:

$> mate /usr/local/var/postgres/postgresql.conf

Uncomment the line with 'log_destination' and set it to 'syslog'

log_destination = 'syslog'

Open the syslog config:

@arkan
arkan / output.log
Last active September 11, 2015 13:04
Hi there,
I'm having issues with Docker 1.8.1, on CoreOS(801) with a volume driver.
#docker info
Containers: 6
Images: 44
Storage Driver: overlay
Backing Filesystem: extfs
@arkan
arkan / Dockerfile
Last active September 7, 2015 15:20
How to install dig on CoreOS with the minimum impact possible
FROM alpine:latest
RUN apk add -U bind-tools && rm -f /var/cache/apk/*
ENTRYPOINT ["dig"]
@arkan
arkan / main.go
Last active September 1, 2015 15:27
package main
import (
"os"
"github.com/mailgun/oxy/forward"
"github.com/mailgun/oxy/roundrobin"
"github.com/mailgun/oxy/testutils"
"github.com/mailgun/oxy/utils"
"net/http"
@arkan
arkan / Capfile
Created March 22, 2014 14:39
Capistrano 3 with Sidekiq + Rbenv + Unicorn
# Load DSL and Setup Up Stages
require 'capistrano/setup'
# Includes default deployment tasks
require 'capistrano/deploy'
# Includes tasks from other gems included in your Gemfile
#
# For documentation on these, see for example:
#
{
// "auto_complete_commit_on_tab": true,
"auto_complete": true,
"tab_completion": true,
// "bold_folder_labels": true,
// "color_scheme": "Packages/Color Scheme - Default/Twilight.tmTheme",
"color_scheme": "Packages/Dracula Color Scheme/Dracula.tmTheme",
"ensure_newline_at_eof_on_save": true,
"file_exclude_patterns":
[
using System;
using System.Drawing;
using System.IO;
using System.Net;
using MonoTouch.Foundation;
using MonoTouch.UIKit;
// A MonoTouch iOS Mail like example with a custom view and a UIWebView :
//
// http://stackoverflow.com/questions/10434444/zoom-a-uiwebview-like-ios-mail-app/10463431
class MyCustomCell < UITableViewCell
# This method is used by ProMotion to instantiate cells.
def initWithStyle(style_name, reuseIdentifier: reuseIdentifier)
super
stylish
self
end
# A delegate method when the user clicks the Row(it's blue by default)
# code inspired from http://jainmarket.blogspot.com/2009/05/creating-custom-table-view-cell.html
class CustomCell < UITableViewCell
attr_accessor :primaryLabel
attr_accessor :secondaryLabel
def createLabels
@primaryLabel = UILabel.alloc.init