When creating an AWS EC2 instance, there is a User Data section where you can include scripts that will be run immediately upon instance creation. I was attempting to use AWS CloudFormation to define the infrastructure of my current project and ran into the issue of how to include the...
[Read More]
Absolute Require Paths for Node.js
When developing a node.js application with custom libraries, dealing with relative pathing in your requires can become irritating. It requires (heh) that you evaluate where you are in the project’s directory structure for each reference. I’ve found that always using absolute paths simplifies the process and avoids accidental reference errors,...
[Read More]
On The Absence of Bears
This is the post, in its entirety and with only minor grammatical edits, that I sent to my company’s general Slack channel to explain why I had been hospitalized the day before.
[Read More]
Scripting PM2 startup for a non-root user
I’ve been working on a bash script for standing up a newly created Linux machine. This particular setup will be running node.js supported by the process manager pm2. In addition, I will be using the Node Version Manager (nvm), to pull down and install node.
[Read More]
Apply a style to all but the first item in an ng-repeat for angular.js
Angular has a very handy $first (and $last) variable for use when implementing an ng-repeat. Along with ng-class, the following allows you to apply a style to all but the first item in the iteration. You can negate the expression with ! as you would expect.
[Read More]