検疫所が指定する宿泊施設とは

日本に戻った。簡単じゃなかった。

向こう滞在中に国がオミクロン危険地区みたいな指定食らってしまって、日本に戻るとPCR検査いくらあってもワクチンいくら打ってても問答無用で指定施設に数日いないといけない。意味不明。

到着は成田だったのでその付近のホテルが宿泊施設として指定された。ホテルの館一つまるごとがその目的に割り当てられてるっぽくて貸し切り状態。とはいえ受付済んで部屋に入ったら部屋から出られなくなるから、一階にコンビニがあってもモンエナ買いにいけずつらかった。


When I accidentally Longhorn CSI

Symptoms: CPU load on all the nodes, but not the pods. Looking at Grafana, I noticed that CPU load on some of my nodes was constantly very high. At the same time, even the total CPU use of all the pods summed wasn’t above 0.4. What gives? This usually gives that the control plane is getting fried by something. It may be trying to relieve disk pressure, or in this case, trying to revive CSI.

Trying to figure out what was causing problems I checked the pods in kube-system with kubectl get pods -n kube-system. It quickly became apparent that there is a problem: disk-related pods like csi-resizer, csi-snapsotter and csi-provisioner were in CrashLoopBackOff.

I’ll be quite honest in that I’m not sure what the problem was. A few searches later I came to the conclusion that an earlier node reboot had left the pods with a corrupted DNS cache or something along those lines. Basically every issue I found with the symptoms I was seeing came down to DNS problems (longhorn/longhorn#2225, longhorn/longhorn#3109, rancher/k3os#811).

Alas I haven’t touched any of the networking machinery of Kubernetes (nor configured any of it for k3s) so my first idea was just the good old one from IT Crowd: “have you tried turning it off and on again?” So I did. Luckily another restart of the afflicted nodes solved the issue. I’m glad it did because I dread what I’d have had to do otherwise.


Steps to a more stable k3s cluster

It’s all too easy to kill a k3s cluster. I’ve been using k3s for years now and I’ve had plenty of adventures tweaking various aspects of running it. Before it’d take just a small change to an Argo Application to trigger a cascading failure. Hopefully now it’s a bit more resilient. Just a bit.

ship helm

PDF export with the Ruby 3.0.3 docker image

You might happen to use the wicked_pdf gem for PDF output in your Rails app. You might happen to use the wkhtmltopdf-binary gem to provide the required binaries. You might want to get the above to work on the latest (at this point 3.0.3-bullseye) Ruby docker image. Short answer: give up. A bit longer answer: it’s easier than you think.


Patching delayed_job for Ruby 3

Monkey patching is bad. That’s where you should start from. It can cause trouble where you’d least expect it, conflicts with libraries you’d least expect in ways you’d least expect. And yet here I am sharing code for patching the delayed_job gem to (more or less) work with Ruby 3. Doesn’t this violate my own policies? There are a few choices.

  1. give up upgrading to Ruby 3 altogether
  2. monkey patch delayed_job as an emergency fix and make time to figure out what to do
  3. contribute to delayed_job making sure the gem is solid on Ruby 3
  4. get rid of all the .delay calls and switch to another async job library

reititはいいぞ

reititClojure/Scriptの高速なルーター。はい30文字。

brown wooden pathway on green grass field near brown rocky mountain under white clouds during daytime

またまた忙しい

忙しいぞ。

遠征に出るのでアドカレの記事を事前に書き溜める必要がある。そして勢い余って色々書きたくなる。現状すでにブログに書き溜めが6件、未完成さらに4件、後会社のブログにも一件ある。楽しいし記録に残るんで今後振り返にも役に立つし、例えば転職考えることになったらその時アピールもできるし(できるか)。

あとは遠征の準備そのものでやることが多い。渡航で必要なPCR検査とか接種証明書の準備、今オミクロンで盛り上がってる世の中で一日で渡航条件が変わる可能性すらあるから油断ならない(変わりませんように)。実際に荷造りも始めて、ハイパーライトのリュックを遠征でいよいよ試せるかもしれないからワクワクしてる。本来は夏のK2で使う予定だったけど、それはコロナでとんだよね…


Stuff that broke in Rails 6.1

Rails uses a “shifted” “semantic” “versioning” which pretty much comes down to the following. Major version: “we’ll most definitely break everything you ever depended on, half of them without warning.” Minor version: “we’ll probably break many stuff you depend on, some of them without warning.” Patch version: “we might accidentally some core APIs, but we promise it’s not intentional (or documented).” Knowing that, I still embarked on the grand endeavor of upgrading from Ruby on Rails 6.0.4.1 to 6.1.4.1. What could possibly go wrong, right?

Railway tracks are suspended above the washed out Tank Hill underpass of the Trans Canada Highway 1 after devastating rain storms caused flooding and landslides, northeast of Lytton, British Columbia, Canada November 17, 2021. B.C. Ministry of Transportation and Infrastructure/Handout via REUTERS
Rails in Canada and on Ruby share (un)surprising similarities (source)

激重一日

夜あまりよく寝れなかった。昨日kustomizeとhelmとargoと戦ってイライラしてたらモンエナ飲みすぎただろうな。夜遅くなるほど生産性が向上するクセをなんとかしたい、フル回転している頭が睡眠の邪魔になる。

最近オフィスが完全フリアドになって袖机とか私物片付けてねと指令が下った。どうせずっとリモートだし逆にいつオフィス行くかと悩んでた。で全然よく寝れなかったから朝アラームよりも先に目が覚めて、じゃ今日オフィス行こうと。朝の強化ジョギングは欠かさず。


Előterjesztés

Elmúlt érák homályába tűnő fiatalkoromban alkalmanként feltűnt “a Tereskova”. Nem az énekesnő maga persze, hanem az ő Unikum című dala, aminek kórusa hogy “unikum, sör, rum, kevert / nem értem miért vagyok reggel levert”. Kalandvágyó (bár altert részemről alig hallgató) fiatalként felmerült, hogy ezt a szettet Tereskova néven fogyasszuk. Tekintve, hogy három feles és egy sör azért már nem marad nyom nélkül, gyakran ugyan nem.

De elég a múltba tekintésből, vár a jövő! Szeretném előterjeszteni a Tereskova testvér-szettjét, a Korpiklaanit. Ugyan a Tereskova az énekesnő egy számában bukkan fel, a Korpiklaaninak italonként van egy-egy száma (így persze elvileg a sorrend tetszőleges). Maga a kombó: Jager, sör, tequila, vodka.

Háttér: a minap futás közben dobta be a Spotify a Tequila című számukat. A Vodka és a Beer Beer már megvolt régebbről, és miután hazaértem, a tecsőn fedeztem fel, hogy van a Jagerről is daluk. Itt jött az ihlet. Mellesleg a decemberi ecuadori expedícióra készülve most egy hónapig alkoholmentesen élek, úgyhogy tesztelni még nem tudtam. Gyanítom üt akkorát, mint egy Tereskova.

Lábjegyzet: a videókat csak a zene kedvéért, nem kell utánozni. Jagert üvegből inni vagy tequilát magadnak párolni nem feltétlen életbiztosítás…