Ansible Git Module for Private Repository

Ansible is one of the best tool when it comes to deployment and any related things as well. I’m using ansible to deploy my website, and a few of my projects. Using git modules on Ansible is quite easy, for examples: - name: pull the latest code from git git: repo: https://github.com/username/repo.git dest: /path/to/remote/dir With a simple configuration, the git module will clone or update the from repo to the destination directory.
Read more →

Using Pre Commit on Golang Project

Are you using Git to manage your code? Have you ever heard of hooks? pre-commit hook? Git is one of many version control that exist nowadays. Git helps developer, programmer, engineer to manage their code, versioning their project, library or even just as file storage. Hook is an operation that could be executed before, or after our main operation. So pre-commit is an operation that executed right before the commit processed on git.
Read more →

Not Found Handler Gorilla Mux

Recently i used Gorilla Mux as my http router in Go. For your information, gorilla mux is one of the popular http router in Go Programming Language. It happens when i’m trying to write a new microservice in go, and i’m ended up using go-kit. Go-Kit is a great tools when it comes to Microservices, especially in Go. The microservices is still using REST as the communication mechanism, thats why the service itself served using gorilla.
Read more →

I Am In Love With React

I’m In Love. Few days ago i started to use ReactJS more frequently to write a client side of an application. I’ve been known ReactJS since years ago, but i’ve never been using it before to build some application. This whole year i was just writing codes for Backend because that was my job. And honestly, back then i hate javascript. I hate the Frontend kind of thing, hate the frameworks, hate all of the things about Frontend development.
Read more →

Set Expires To Epoch Time In Go Http Response

Today i was having a problem with my web api in Go. A lot of my API’s are cached by the browser because the Expires time of the response was automatically set to 4 days than the first request. The expires time was a header information from the response, if you are not familiar with this. You can use curl -XGET -i http://url/api/endpoint Or you can use the network inspector on modern web browser such as Google Chrome or Firefox and other.
Read more →