Skip to content

Instantly share code, notes, and snippets.

Consul and consul-template
https://hub.docker.com/_/ruby/
progrium/consul
gliderlabs/registrator
HOW TO
SET IP
DOCKER_IP=$(/sbin/ip -o -4 addr list eth0 | awk '{print $4}' | cut -d/ -f1 | grep -v 10.)
kitchen@1ed8205754be:~$ mysql -u root -pTEST -h 127.0.0.1
ERROR 1045 (28000): Access denied for user 'root'@'127.0.0.1' (using password: YES)
kitchen@1ed8205754be:~$ mysql -u root -pTEST -h 172.17.0.2
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 54
Server version: 5.5.47-0+deb8u1-log (Debian)
set $xheader "SAMEORIGIN";
if ($http_referer ~ "XXXX") {
set $xheader "NONE";
}
proxy_hide_header X-Frame-Options;
add_header X-Frame-Options $xheader;
root@debianJessie:~# cat /etc/init/tty1.conf
# tty1 - getty
#
# This service maintains a getty on tty1 from the point the system is
# started until it is shut down again.
start on stopped rc RUNLEVEL=[2345] and (
not-container or
container CONTAINER=lxc or
container CONTAINER=lxc-libvirt)
stop on runlevel [!2345]
root@debianJessie:~# initctl list | grep tty
tty4 start/running, process 789
tty5 start/running, process 792
tty2 start/running, process 803
tty3 start/running, process 807
tty1 stop/waiting
tty6 start/running, process 809
root@debianJessie:~#
FROM ruby
run curl https://gist.githubusercontent.com/pollosp/1ebd781f01e95b33e869/raw/6ff280d4b4f3e52e88936c61f24975ed4f1fb845/dockerfile -o /mnt/rackup.sh
run chmod +x /mnt/rackup.sh
ENTRYPOINT /mnt/rackup.sh

Keybase proof

I hereby claim:

  • I am pollosp on github.
  • I am pollosp (https://keybase.io/pollosp) on keybase.
  • I have a public key whose fingerprint is 6B46 263D AE2D 0F8F 3A8C E8CF A1A9 39D5 10DA E8C5

To claim this, I am signing this object: