Quick and dirty Consul + Registrator + Docker tutorial

Standard

A quick and dirty Consul + Registrator + Docker tutorial.

https://github.com/subokita/consul-docker-test

The example uses docker, consul, registrator and python’s flask framework to quickly create REST services.

The interesting files are the

  • call-server.py: which shows how to use python-consul to obtain available services (other flask REST service) from the consul node
  • And the docker-compose.yml that creates consul server, registrator container, and two REST service containers which are automatically registered using registrator.

Have fun.

 

Standard

In indefinite hiatus, which would probably last a very long time.

I want to focus on my work creating things I believe in.

Standard

If sure fire way to be happy is to lower your expectation. Then the obvious way to make others happy is to do something that exceeds their expectation when they are expecting nothing at all.

Standard

I’d probably be blacklisted by the government, but well, whatever.

Here’s the link to Bhinneka magazine which details the atrocity of 1965’s genocide in Indonesia. maskod.co.id/bhinneka-en/#p…

Here’s another link if the previous one is dead: https://archive.org/details/BhinnekaOct15English

 

Standard

I’ve updated 2015 todo list with post-mortem, and some 2016 and added 2017 list. Feel free to check it out (left hand bar, scroll down), if you care. It shouldn’t matter to anyone, honestly.

Flight around alps

Standard

My manager took me for a flight around Alps. Here are some photos:

Desc ...

DE-TCR

Desc ...

2 seater Cessna

Desc ...

View after takeoff

Desc ...

It was drizzling

Desc ...

Ammersee, if I recalled correctly

Desc ...

Cockpit view

Desc ...

Flight info

Desc ...

Town

Desc ...

Boringness

Desc ...

Part of the wing

Desc ...

Alps in the distant

Desc ...

Getting closer

Desc ...

… closer

Desc ...

…closer 

Desc ...

… bit more

Desc ...

just a bit more…

Desc ...

There we go

Desc ...

Breathtaking

Desc ...

Desc ...

Desc ...

Sun behind the clouds

Desc ...

Another pretty pic

Desc ...

Desc ...

Desc ...

Desc ...

Desc ...

My fave photo

Desc ...

Desc ...

Desc ...

Desc ...

Desc ...

Desc ...

Desc ...

Desc ...

From the back

Desc ...

Beautiful river

Desc ...

Neuschwanstein from bird eye’s view

Desc ...

Moar

Desc ...

Desc ...

Desc ...

The lake reflects the sky entirely

Desc ...

View before landing

Desc ...

I learned a lot about plane today.

Assorted pictures taken during a month span or so

Standard
SONY DSC

Ah Guan, one of my sister’s dogs

SONY DSC

You want to touch that nose don’t ya?

SONY DSC

Rena, the other dog

SONY DSC

Fake flower I believe

SONY DSC

Red sth sth

SONY DSC

Cessna (I think), my manager wanted to take me for a flight, but decided not to because the wind was too strong

SONY DSC

Fürstenfeldbrücken, the umlaut is at the wrong place

SONY DSC

Another plane. I think I am leading a weird but very interesting life.

SONY DSC

Another plane

SONY DSC

ESP Viper 7, 7 string guitar with EMG pickups. Probably the last guitar for me for the next couple of decades.

SONY DSC

Some random toy. Nice bokeh though

SONY DSC

Real flower

SONY DSC

Centuries ago, people can only see things in black and white.

SONY DSC

Modern art installation at my brother’s house

SONY DSC

Here I wake up to crows’ crowings. but back in Indonesia, the swallows actually chirp or sing gangsta rap early in the morning

SONY DSC

Molly

SONY DSC

Ah Guan in black and white

SONY DSC

Quaint typewriter.

SONY DSC

Yes, the keys jam

SONY DSC

SONY DSC

SONY DSC

SONY DSC

SONY DSC

This is the view from the back of the house that I grew up in (uncle’s house, I’ve never have a home in my whole life)

SONY DSC

On second thought, this is heaven on earth. It’s basically open ocean directly from the back of the house. I can feel the salty air, the gentle breeze, etc.

IMG_0550

View from brother’s house

IMG_0560

This is inside brother’s house.

IMG_0562

Padang food, basically a feast, featuring dishes with various colours, tastes, etc. It’s a delight

IMG_0570

Continuation from the previous one. One of the best foods on earth. Not even exaggerating

IMG_0572

Ox brain.

IMG_0574

Fish head

IMG_0579

Chili condiments, these are essential

IMG_0581

The Rodin don’t want to be bothered. Ich hab keinen Bock mehr

IMG_0608

Just in case you forget, we might kill you here.

IMG_0616

Vietnamese coffee press. I like it a lot

IMG_0627

Pho, a lesser version of Soto.

IMG_0632

This is actually a view from my walk to work. There’s a reason I still walk from train station to work.

輪郭

Standard

夢から
夢から夢へガラスの道へ
夢から涙さえ消え去って
夢から
夢から覚めたこの世界では
思い出さえ夢となり…

I need to get back to sleep…

Resources for learning [spoken] languages

Standard

Here are some resources that I constantly use to polish my foreign language skills. No, nothing beats going to language courses, but if you need some cheat sheets, or if you’re rusty with a particular language, you could use these:

  • German

One of the tougher languages out there, with its demanding grammar and genders in articles.

  1. ielanguages.com has 5 pages of grammar cheat sheet that you could use.
  2. dict.cc is one of the better online dictionaries out there, considering that it provides tables that shows the conjugations of the word
  3. JunkFoodTaster is a delightful YouTube channel, where a German guy tries out and reviews junk food in both English and German.
  • Spanish

Believe it or not, I tried to learn Spanish before taking German, because at the time I was also considering to study in US.

  1. Again, ielanguages.com has great grammar cheat sheets
  2. Coffee Break Spanish is one of the best language podcasts out there, if you are trying to pick up Spanish, this is a very valuable podcast.
  • Japanese

One of the more ambiguous language out there, but with fairly consistent grammar.

  1. Tae Kim’s Guide to Japanese is probably one of the best guide out there for Japanese grammar. Not only that, it also provides exercises for each chapter.
  2. Jisho.org is fairly useful online Japanese dictionary. I prefer the dictionary on my mac though
  3. Rikai.com is a very useful online tool that can annotate any Japanese article that you’re reading, and provide explanation for every word that you hovered your mouse cursor over.
  4. I watch Itte Q fairly regularly. It’s a funny Japanese variety show, showing different culture and festivals around the world. Probably only useful when you’re already confident enough in your Japanese.
  • Mandarin

Sadly, since I grew up with it, and my native language is a Chinese dialect, I just acquired it naturally. My accent is more of Taiwanese’s than Mainland Chinese’s though.

  1. MDBG.net is a fairly good online Mandarin dictionary. It shows you the pinyin, the Cantonese equivalent, the audio pronunciation, etc.
  2. I watch 美食大三通 (mei3 shi2 da4 san1 tong1) pretty often. It’s a Taiwanese foodie show, where the hosts travel around the world to try out different cuisines. It’s Taiwanese, so the subtitles are in traditional chinese, the accent is Taiwanese, and sometimes they’d interject some Hokkien into it. But it’s entertaining.
  • Indonesian

One of the easiest languages in the world, but it barely has any value, unless if you’re working there or in Malaysia.

  1. ielanguages.com has an okay page detailing the grammar. Hmm, can’t say much about the grammar, since we don’t even have the concept of paste tense.

Have fun picking up new language. It’d be probably easier if you could find friends who can speak in the language that you’d like to learn.

Abomination #04

Standard

Looks generic, tastes like an abomination. Maybe I should really stop learning how to bake. At least it’s green though.

I’m sorry, is there a reason why I am not supposed to whisk in washing powder?

SONY DSC SONY DSC SONY DSC

PS: I’m still very busy with master thesis.

Aside

PS: I’m still very busy with master thesis.

Trying to train cascade classifiers for my HoG based detector takes up the entire CPU resources and the whole day to train a sample version. Thus I ended up diverting my attention to University’s PC instead, however compiling OpenCV and making opencv_traincascade run without error is not a simple task. Let’s see how it goes.

The HoG detector works though, just that it’s too slow without using cascade classifier. Continue reading

Hamburg Steak

Standard

DSC01037

Ingredients for carrot:

  1. Carrot, chopped
  2. 1/2 tbs sugar
  3. 1/2 tbs salt
  4. 1 tbs butter
Instructions for carrot:
  1. In a small pot, boil some water with carrots in it
  2. Add in sugar, salt and butter, and let it boil, till there’s no more water left
  3. Serve

Ingredients for burger:

  1. Minced Beef
  2. Nutmeg
  3. 1 diced onion
  4. Milk
  5. Breadcrumbs
  6. 1 Egg
  7. Worcestershire sauce
  8. Soy sauce
  9. Olive oil
  10. Salt & Pepper
Instructions for burger:
  1. First, fry the diced onion using olive oil till it’s brown
  2. Let’s season the beef with salt, pepper, nutmeg, soy sauce, and worcestershire sauce
  3. Knead the beef till the season is spread thoroughly
  4. Add in diced onion, milk, breadcrumbs, and crack and egg in it, then knead it till everything is mixed evenly
  5. Wash your hand, and apply olive oil onto both of your hands.
  6. Now from kneaded beef, take out some of it till you can shape into an oval shape which can fit onto your palm.
  7. Shape it and toss it between your palms to release any trapped gas within the meat
  8. Now spread a bit of olive oil again on the pan, and start frying the burgers
  9. As soon as the bottom of burger starts to brown, or showing dark marks, flip it over
  10. Immediately after the other side starts to brown, pour in a bit of water, so that the steam and the water can both help to cook the inner part of the burgers
  11. Set them aside

Ingredients for the sauce:

  1. Worcestershire sauce
  2. Ketchup
Instructions for sauce:
  1. On the same pan where you fried the burgers, pour in bit of water, and add in worcestershire sauce and ketchup
  2. On medium heat, let the mixture simmers and thickens
  3. Pour the sauce on the burger.

Stir fried beef

Standard

DSC00842

Ingredients:
  1. Beef, normally I would choose packaged beef for stew, then slice them into stir-fry-size.
  2. 1 finger of ginger, chopped
  3. 2 cloves of garlic, diced
  4. 1 chili pepper (cabe), diced
  5. 1/4 of paprika
  6. Light soy sauce
  7. Sugar
  8. Sesame oil

Instructions:

  1. First, shred the beef and place it in a bowl
  2. Throw in the diced paprika, garlic, ginger, and chili into bowl
  3. Sprinkle bit of sugar into the bowl
  4. Pour in a bit of oil into the bowl, and start stirring / mixing them, so the whole mixture is coated nicely with oil
  5. Heat a pan (but without oil, we’ve already poured the oil into the mixture)
  6. As soon as the pan is hot enough, throw in the whole mixture onto the pan, and start frying, till the beef is brown
  7. When the beef shreds are almost brown, pour in a bit of sesame oil
  8. Voila ! Serve it with rice !