AirPort Extreme guest network with pfSense

AirPort Extreme guest network with pfSense

The AirPort Extreme is a great wireless router. I’m using it strictly as an access point (bridge mode) in front of pfSense. Setup is a breeze, except for the guest network. You’ll need to configure a few things in pfSense: Create a VLAN (tag 1003) Create an interface for the VLAN Enable DHCP on the VLAN interface Create a rule to allow VLAN traffic Configure NAT for VLAN IPs Create a VLAN Interfaces > Assign > VLANs > Add (+)…

Read More Read More

Error: MultipartParser.end(): stream ended unexpectedly: state = START

Error: MultipartParser.end(): stream ended unexpectedly: state = START

It’s been over a year since I last wrote! Wow. I finally hit a bug so frustrating that I couldn’t not write about it. Haha. File uploads in Node.js with Express 4 and Formidable As you probably know, in Express 4, bodyParser was removed and must be included as a module.

Furthermore, file uploads (multipart/form-data) via req.files is no longer supported. So, a module like formidable or multiparty must be used to parse the data. Fortunately, it’s super simple….

Read More Read More

Displaying the git branch on your bash prompt

Displaying the git branch on your bash prompt

My bash prompt looks something like this: Pretty sweet, eh? At a glance, I can see what git branch I’m in and whether or not it’s dirty (red or green). To get this functionality, I utilized Sexy Bash Prompt. For my needs, I found Sexy Bash Prompt to be a little overweight; so here’s my stripped-down version: #!/usr/bin/env bash # Determine what type of terminal to use for tput if [[ $COLORTERM = gnome-* && $TERM = xterm ]] &&…

Read More Read More

Using ng-model with contenteditable

Using ng-model with contenteditable

The ng-model directive is glorious! That is, until you try to use it with contenteditable elements. You’d think it would just… work… but it doesn’t. Fortunately, there’s a way to stiff-arm your way through this problem; just pop the following directive into your application: @myApp.directive ‘contenteditable’, -> { restrict: ‘A’ # match the ‘contenteditable’ attribute require: ‘?ngModel’ # gain access to the associated model priority: 1 # apply this directive before others link: (scope, element, attrs, ngModel) -> # no…

Read More Read More