Subscribed unsubscribe Subscribe Subscribe

Kentaro Kuribayashi's blog

Software Engineering, Management, Books, and Daily Journal.

Started Verity Project

I started another project named "Verity", which is a tool/library to build an inventory of system information. It aims to implement some parts of features from facter and ohai.

The reason why I had to create it is that tools written in Go like ohai/facter was needed when I would revise the architecture of my project, Triglav. I did re-design it and was convinced that it would be better to implement it in Go. Why so do I want to describe later, when I finish the project ;)

Usage

Do go get from this repository:

$ go get github.com/kentaro/verity/bin

Notice that you have to add bin directory to install verity command.

Then execute the command:

$ verity
{"cpu":{"cache_size":"6144 KB","model_name":"Intel(R) Core(TM) i7-2677M CPU @ 1.80GHz","processor":"0","stepping":"7","total":"1","vendor_id":"GenuineIntel"},"hostname":"localhost.localdomain","memory":{"active":"59832kB","anon_pages":"10672kB","bounce":"0kB","buffers":"14156kB","cached":"81084kB","commit_limit":"2856252kB","committed_as":"331420kB","dirty":"4kB","free":"316972kB","inactive":"46080kB","mapped":"7740kB","nfs_unstable":"0kB","page_tables":"1912kB","slab":"33700kB","slab_reclaimable":"13348kB","slab_unreclaim":"20352kB","swap_cached":"0kB","swap_free":"2621432kB","swap_total":"2621432kB","total":"469644kB","vmalloc_chunk":"34359711736kB","vmalloc_total":"34359738367kB","vmalloc_used":"20736kB","writeback":"0kB"}}

How to Hack

This repository provides Linux development environment with Vagrant.

$ vagrant up
$ vagrant ssh
[vagrant $] cd home/vagrant/go/src/github.com/kentaro/verity

To build verity command:

[vagrant $] make

To test whole the project:

[vagrant $] make test