12 Days of Posts: Day 5 – Service discovery with Consul

We are going to move away from JavaScript for a few days. The last few months I have been making quite a few posts about Docker, Ansible, and Vagrant. The main reason for this is because I recently moved my blog from a Linux server that was setup by hand to some Docker containers that are automatically configured. In this post I will touch on Consul. Consul is a service discovery tool.

12 Days of Posts: Day 4 – using call and apply

We have seen some ways that we can take advantage of JavaScript’s functional roots. This theme will continue for this post as we will look at call and apply. Call and apply are very similar. Both methods will execute the function, set the this value and pass in parameters. Call does this by having the parameters each explicitly defined while apply takes an array of parameters. Here is an example using our trusty add function and whatIsThis.

12 Days of Posts: Day 3 – using bind with a function

We are already at day 3. We are continuing with JavaScript and building on what we have already covered. We are going to cover the bind method of the function object. Bind is used to define what this is inside of a function. It will return a new function (there is that ‘functions are a first class object’ idea again!) and not modify the current function. Let’s look at an example.

12 Days of Posts: Day 2 – Partial application of a function

This day’s post is a continuation of the last post. In the last post we covered that a function can return a function, but we did not cover any use cases. This post will discuss a very useful one. We have an add function: function add(x, y){ return x + y; } We can partially apply one of the parameters and return a new function. To reinforce what this means we will look at an example.

12 Days of Posts: Day 1 Functions can return functions

I am attempting to do something a little different. Right now everywhere you go there is something related to Christmas. This inspired me to challenge myself to write 12 short posts before Christmas. Here is the first. Functions can return functions In JavaScript functions are first class objects. For our purposes here that means that functions can be returned from other functions, used as parameters for other functions, and the value stored in a variable.

WordPress on Docker: the videos I have created a three video series on running WordPress in Docker. This is different than my previous posts on Docker and WordPress. The posts I had written before focused mainly on my journey of moving my site to Docker. This means that many pieces were directly tied to my implementation. These videos and code does not have that requirement. The repository can be used to create a WordPress site from scratch and having running in the cloud in just a few minutes.

WordPress Docker containers

This post will cover what each container in our Dockerized WordPress setup does. This should not be viewed as a standalone post as there is a video playlist that covers more. The playlist demonstrates how you can quickly and easily bring up a Dockerized WordPress install. First we will start with an image that will explain so much with so little. Yes, there are six different containers. This is so that we can keep each container with a single purpose and even a single process in most cases.

How to link Docker containers together

This is the third post in a series about moving my WordPress blog into the cloud using Docker. Bringing up Docker containers with docker-compose Docker-compose is a tool from Docker that allows us to define how each container will fit in our application. It makes for a single command to get everything up and running. Docker-compose should already be installed on our target machine by Ansible. First thing we will do is look at our docker-compose.

WordPress and Docker the correct way

We now have a good foundation to build our WordPress site off of. Docker is installed and ready. We will quickly cover why Docker, some best practices, and finally the actual how of our Docker containers. Much like the previous post, this is not designed to be an introduction to Docker. There are literally thousands of intro to Docker articles and by the time I publish this that number will have doubled.

My talk on React

This is a talk I gave for a local Meetup about React. It is called ‘Why I like React’. I cover the basics of building React components. Then I spend some time talking about functional programming. Finally I wrap it all together to show how React is functional in nature. The final demo shows how to ‘think in React’. Presentation Slides Github Repo