Chef Patterns and Antipatterns

Just read an interesting Doug Ireton’s blog post about Chef patterns and antipatterns.

January 28, 2014 · 1 min · Serg K0SSK

Nginx, Conditioned Proxy_set_header Assignment

Sometimes it’s needed to assign some proxy header depending on some variable value. But proxy_set_header does not work with “if” cause (at least didn’t work with nginx 1.4.1). So the following construction won’t work: ...

January 8, 2014 · 2 min · Serg K0SSK

Some Notes Regarding Rsyslog and Remote Logging for Rails Apps

We use SyslogLogger gem in order to forward rails application log to system log. in rails Gemfile: group :production do gem "SyslogLogger", "~> 2.0", :require => 'syslog/logger' end in config/environments/production.rb config.logger = Syslog::Logger.new "rails_application_name" The problem was that logs actually were forwarded to syslog, messages and user.log and sent to remote server and written to syslog, messages and user.log there. I was asked to make things DRY(ier). ...

January 2, 2014 · 2 min · Serg K0SSK

Skype + Pulseaudio 4.0 in Debian Jessie/testing Buzz

After the recent system upgrade of my Debian x64 home desktop I’ve noticed Skype started to make creepy buzzzzzzz sound or no sound at all. The issue is caused by the new version of pulseaudio, 4.0. The workaround is to set environment variable PULSE_LATENCY_MSEC=30: $ PULSE_LATENCY_MSEC=30 skype &>/dev/null & Here is a thread devoted to this issue.

December 22, 2013 · 1 min · Serg K0SSK

RaspberryPi with Root Partition encryption, unlocked using a flash drive

Why unlock using flash drive: Because you don’t have keyboard or monitor connected to your RPi, do you? Information: I was using Pezz’s gist, which helped me a lot. Thank you very much, Pezz. Why Arch linux: because I wanted to try Arch, default kernels of Raspbian and Pidora lack(lacked? Maybe already have) needed encryption modules. SD card preparation Download Arch linux image from here: RPi downloads On your desktop check list of devices: $ ls -lah /dev | grep sd brw-rw---T 1 root disk 8, 0 Aug 11 15:43 sda brw-rw---T 1 root disk 8, 1 Aug 11 15:43 sda1 brw-rw---T 1 root disk 8, 2 Aug 11 15:43 sda2 brw-rw---T 1 root disk 8, 3 Aug 11 15:43 sda3 brw-rw---T 1 root disk 8, 4 Aug 11 15:43 sda4 Now insert SD card into card reader on desktop, and check list once again. You’ll see a new device we’ll write Arch linux image to. ...

December 20, 2013 · 5 min · Serg K0SSK