allow insecure SSL with behat, mink, selenium

this was annoying and hard to find on the internet, so here it is

replacing FX-101B board in a Haier HVTEC12DABS

The Haier HVTEC12DABS is a 12-bottle wine fridge with a 2-zone thermoelectric (peltier) cooling setup.

My fridge started acting up. Beeping on start, front panel dead, no cooling. From what I read in a very useful thread at All About Circuits it’s possible to replace commonly blown capacitors, fuses, and transistors. But I am not that handy and I’d probably mess something else up in the process.

So I looked for replacement boards. This unit has two FX-101B boards, manufactured by “Foshan Hanyi Computer”:

The board is labelled as “FX-101B 10.5V PCB120606F1”. There is another marking “SH14611” with a date of “12.07.12”.

I wanted to replace both boards but the FX-101B is impossible to find. The “B” variant must have been made specifically for Haier, as other wine fridges have an FX-101 or FX-102 board. The differences I found:

  • the TEC (thermo-electric cooler) plug is a spade terminal rather than pins
  • there is an additional NTC (thermristor) connector for temperature control

I found that they sell these boards on Aliexpress in all different varieties (search for “FX-101 board”). But I could not find an FX-101B board, only the FX-101 and FX-102 which is apparently compatible. So I took a shot – $72.10 shipped for two FX-101 boards, from China. Now I’m thinking the FX-102 might have been a new board with better components but I didn’t really know much at the time and just went with the part I thought was the most compatible.

Note: Stock image because I forgot to take a picture before I put them in. When they arrived, they were marked 110v and 10.5v as requested. I found out later that if you find a 110v 12.5v board, that should work as well. 220v will obviously not work if your previous board is 110v and vice versa. Notice the different connector for the TEC power and the new NTC connector in the upper right.

First I had to cut off the existing TEC connector in the fridge and crimp spade disconnects to them which was a $4 purchase from Home Depot. Note: the FAN1 and FAN2 are different! One is hot side and one is cool side. The cool side (inside) should always spin, the hot side (outside) will only spin if the board is cooling. Switch your fan connectors if this happens. I plugged everything back in and started the wine cooler up.

Joy! The front panel was no longer blinking and chirping and it looked like it was cooling. But alas, the red lights on the back of the boards were lit up. This means that the unit has power but has not been requested to cool. The cool side (inside) fans were spinning. The hot side (outside) fans were not spinning. Multimeter showed no power to the TEC. I figured this had something to do with the new NTC connector and that maybe the board was expecting to be turned on via a thermristor instead of the control from the front panel.

I used a jumper to short the NTC pins together and the cooler came alive. The green LED lit up and the back fans started spinning. It then cooled down the set temperature.

I confirmed against my suspicions, even with the NTC pins jumped, the front panel temperature was still controlling cooling activation. I had thought that this would have made the fridge cool infinitely as it thought it was too warm (a thermristor will increase resistance as it gets hotter). Why this is, I don’t know. I guess the remote control overrides the thermristor, or, if it detects very low resistance it assumes there is no thermristor. Now the fridge cools to the requested temperature and turns off when not needed. Working like brand new!

replacing the haproxy error page in openshift origin

first, create a configmap secret which will contain the 503 page

then create it

now you need to add it as a volume

and patch the router config (see https://github.com/openshift/origin/issues/16275 for why this is necessary)

selinux also has to be disabled on the router box (for now)

stop behat on 500 errors with mink

I had some issues diagnosing 500 errors that were happening with Mink. The main issue being that a page would 500, but then the test would proceed and fail a later step. Unfortunately the HTML/screenshot that was captured does not capture the error, but instead captures the assertion which doesn’t help debug.

It’s possible to react after a step and check if the last Mink request was a 500 or not. This way, we fail on the 500, and not on the subsequent assertions.

 

PHP commandline OAuth authorization for JIRA

I needed to get a user’s OAuth credentials from the commandline, for some commandline tools to work (Drush).

You will need OAuth installed from PECL for this, and have an OAuth link set up in JIRA (or whatever OAuth provider you are using).

 

launch a jenkins slave via drush

If you already have Drush aliases set up for your live machines, deploy those aliases to your CI server, and use them to launch your nodes (instead of copying the SSH info).

Create a new “Dumb slave” but instead of “SSH slave”, select “Launch slave via execution”

This is the command to use:

Jenkins will run the command which sets up the remoting capabiliity.