Skip to content

Instantly share code, notes, and snippets.

@innyso
innyso / docker-machine-tls.md
Last active December 21, 2015 01:11
Enable tls for docker-machine
  1. Add cert to /var/lib/boot2docker/certs/ so that it wont be remove everytime we restart docker-machine
  2. create dir sudo mkdir -p /etc/docker/certs.d/<registry-name>
  3. create sudo ln -s /var/lib/boot2docker/certs/<registry-name>/ca.crt /etc/docker/certs.d/<registry-name>/
  4. restart docker sudo /etc/init.d/docker restart

reference

@innyso
innyso / puppet_create_resource_checklist.md
Last active December 23, 2015 11:56
puppet create_resources checklist
  1. make sure the hiera value has the following structure
users:
  mary:
    group: admin
    alias: m123
  mark:
    group: user
    alias: m456
@innyso
innyso / ruby_object_methods.md
Created January 5, 2016 05:55
print method for ruby object
object_name.methods
object_name.inspect
@innyso
innyso / splunk_config_table.md
Created January 29, 2016 00:52
Useful table for splunk configuration
@innyso
innyso / command_open_track_spotify.md
Created February 7, 2016 05:58
command to open track in spotify
sleep 1; open "spotify:track:7f0jXNMu2xjQUtmKMuWhGA#01:20"
@innyso
innyso / private_gem_server.md
Created February 8, 2016 06:21
running private gem server instruction
@innyso
innyso / command_ps_memory_leak.md
Created March 31, 2016 03:47
Command for seeing which app has memory leak

Error saying fork: Cannot allocate memory

ps --sort -rss -eo rss,pid,command | head

@innyso
innyso / path_in_cygwin.md
Created May 23, 2016 00:45
Correct reference path in cygwin

In cygwin, when referring path from the c drive, make sure we add /cygdrive before the /c/folder1/folder2

@innyso
innyso / ansible_babun.md
Created June 15, 2016 00:28
Getting ansible working on babun

When using ansible on babun I am getting the following error

 [main] python2.7 16500 child_info_fork::abort: address space needed by '_speedups.dll' (0x4B0000) is already occupied

The error was due to the the _speedups.dll provided in markupsafe python library.

Uninstall the markupsafe (I have to do it manually)

@innyso
innyso / container_arbitrary_uid.md
Created June 22, 2016 03:04
Support Arbitrary user ids

When running container in container with arbitrary user id but you want a proper uid to perform task like git pull or any runnable container task.

User nss_wrapper

in Dockerfile

yum install nss_wrapper
.....
command ["./startup.sh"]