Archives: work

A YouTube channel for my son

January 11, 2017 | By Brian | No Comments | Filed in: work.

My son decided that he wanted his own YouTube channel to publish his Minecraft sessions. I think he wants to become the next DanTDM (13M subscribers!). Two big hurdles with this one:

  1. Finding a good screen recorder for Windows 10
  2. Not using his full name as the name of the channel

Finding screen recorder software isn’t very hard, Google has a bunch of options. But each one seemed more scammy than the next. We finally settled on Wondershare Filmora, because that’s what his buddy in fifth grade uses. He’s still practicing so the huge watermark on the recordings isn’t bothering him yet. To remove it, requires a purchase which is $59 and I’m guessing that will happen soon.

Because he’s already got his own email with @olore.net hooked into Google (thanks to me for setting up the Google Apps for your domain like 100 years ago when it was free for everyone), creating a channel and uploading videos is a piece of cake. Almost too easy, especially for a 4th grader. While complete anonymity isn’t quite possible, I at least wanted to remove his full name from the top of his channel page. Easier said that done.

Eventually I found that if I created a Google+ page for/as him, he could add a nickname. Unfortunately, his nickname then appeared between his first and last name in quotes. Not what I was looking for, but close. Finally I landed on the solution – in the same screen where his First, Last and Nick name are in Google+ I removed his Last name, and Nick name, then changed his Minecraft handle as his First name. There was a warning about this change taking affect for all Google services, which probably means GMail too, which isn’t ideal, but for now his name is off his channel, and just his Minecraft name shows, which is perfect.

Without further adieu, I give you the joecraft2015 channel !

This is what I do

April 2, 2015 | By Brian | No Comments | Filed in: work.

Lotsa people can write code. I have a ton of respect for those that take the time to make it so incredibly clear it requires no explanation. I prefer descriptive names over comments. No one writes it beautifully the first time, every time. That’s why just “getting it to work” is never good enough. I am a software gardener, and I really enjoy it.

To that end, I thought this example of a recent refactor would be a good example to share. This actually help us fix a bug which turned out to be the fact that the unit tests was passing in a number for expectedLogoutTime, while the actual code was passing in a Date object. (Hence why I changed the variable name to expectedLogoutDate.)

Before

After

Yo + Angular + Cordova = Yay!

December 12, 2013 | By Brian | 2 Comments | Filed in: work.

Starting with Daniel Simard’s awesome grunt-angular-phonegap, I was able to get a Hello World (aka ‘Allo ‘Allo) cordova base app running on my Android simulator without much trouble. It didn’t quite work out of the box, and I am not sure yet how to contribute back, but until I figure that out, I thought I would share what I did to get things going.

  cordova platform add android

To get ‘grunt serve’ to work, I had to copy platforms/android/assets/cordova*.js to app/

  cp platforms/android/assets/www/cordova*.js app/

In Gruntfile.js, in the ‘build’ step, I commented out the ‘cdnify’ task which forces the app to load jquery from google’s CDN instead of locally.

Added <script src=”cordova.js”></script> above the inclusion of jquery.js in app/index.html

Created script/fscordova.js, from http://www.ng-newsletter.com/posts/angular-on-mobile.html#native

Added <script src=”scripts/fscordova.js”></script>above the inclusion of app.js

Added fsCordova’ to things to inject in app.js after ‘ngRoute’.

Listen to cordova ready within scripts/controller/main.js

angular.module('myappApp')
.controller('MainCtrl', function ($scope, CordovaService) {

CordovaService.ready.then(function() {
  //console.log("CORDOVA IS READY -----------");
  $('.text-muted').html("Woot Woot!"); //yes it's jQuery... shoot me!
});

$scope.awesomeThings = [
  'HTML5 Boilerplate',
  'AngularJS',
  'Karma'
];
});

Now you can run

  grunt phonegap:build serve

and more importantly:

  grunt phonegap:build phonegap:emulate && platforms/android/cordova/log

 

Enjoy!

Screen Shot 2013-12-12 at 11.29.10 PM

Don’t use register.com

December 11, 2013 | By Brian | 1 Comment | Filed in: work.

If you try to renew your domain name on register.com it costs $38. If you click the button to transfer it to another company, they offer you the renewal price of $10.

So frickin slimy, but I am lazy and probably will just pay the $10 and stay there. If you need a domain, go to http://namecheap.com/, that’s where most of mine are

When ProxyPass and ProxyPassReverse aren’t enough

July 1, 2013 | By Brian | No Comments | Filed in: work.


If you’ve ever used ProxyPass and ProxyPassReverse you know how awesomely powerful they are when integrating multiple backends and keeping the things neat and tidy in Apache.

Recently I had to integrate with a backend app using Apache as a reverse proxy. Ideally, and how I’ve done it a million times in the past, you are able to have the backend application respond on a particular host/port/path ( i.e. http://foo.example.com:1234/backend ). This makes setting up Apache via ProxyPass and ProxyPassReverse a snap.

  ProxyPass        /backend/ http://foo.example.com:1234/backend/
 ProxyPassReverse /backend/ http://foo.example.com:1234/backend/

So what happens when you can’t run the backend application on a specific context root? By that I mean it can only run at: http://foo.example.com:1234/.




This is where mod_proxy_html comes in. In a nutshell, mod_proxy_html allows you to rewrite html, javascript & css so that the URLs can cleanly go through your reverse proxy. This means that the backend application responds with

<script src="/script/application.js" type="text/javascript"></script>

mod_proxy_html will converted it to

<script src="/backend/script/application.js" type="text/javascript"></script>

To get this to work, add the following to httpd.conf

Include conf.d/proxy_html.conf

ProxyPass        /backend/ http://foo.example.com:1234/
ProxyPassReverse /backend/ http://foo.example.com:1234/
ProxyHTMLURLMap http://foo.example.com:1234 /backend

<Location /backend/>
  ProxyHTMLEnable On
  ProxyPassReverse http://foo.example.com:1234/
  SetOutputFilter proxy-html
  ProxyHTMLURLMap / /backend/
  ProxyHTMLURLMap /backend /backend
</Location>

mod_proxy_html is available in Apache 2.4, and as a 3rd party installable module in older Apache 2.x. I needed it in Apache 2.2 on Centos 6 and used the RPM from epel.

This post just scratches the surface with what you can do with mod_proxy_html. There are a ton of options for configuring meta headers, html fixups, and buffer sizes. Go check it out!

Tags: , , ,