2015年11月15日 星期日

import AOSP to gitlab


AOSP have almost 700 repositories, it is failed to import them into gitlab.

Install from source, it introduced database (postgresql) and redis

Gitlab architecture:


unofficial gitlab docker:

detail description of parameters:

issue "500 error" after import lots of repositories:

It seems be fixed in this issue?

https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/raketasks/import.md
root@8395b04d4219:/home/git/gitlab# bundle exec rake gitlab:import:repos RAILS_ENV=production

The official docker image give me another issue:
Failed to create repository via gitlab-shell

2015年7月12日 星期日

snappy notes


Test snappy in docker:
http://andrea.corbellini.name/2015/03/25/running-ubuntu-snappy-inside-docker/

[ 小米換到 coolpad 大神 F2 ]

# 之前寫的忘記有沒有寫完 ... 就丟出來吧 XD

最近買了CP 值滿高的 Coolpad 大神 F2 今天剛拿到,感覺還不錯,但是要從原本的手機移過來也是個大問題,雖然很多資料都已經放到雲端,但還是有些是存在App 中,且要一個一個 App 去裝,也很麻煩,因此試了幾個方法。

1. 鈦備份:
這個應該是最好的選則,我之前也有買鈦備份專業版,但可惜的是,它一定要在 root 下使用,偏偏在 coolpad 大陸宣佈 root 後還是照樣有保固的同時,台灣就是沒有同步 (奇怪平常不是一直叫是一個國家,怎麼現在又不同國了?),所以,不能用。

2. adb backup[1]:
看起來也是滿可行的一個方法,但不知為何我的小米 2S 在執行 adb backup 後,device screen 上沒有出現任何訊息 ..... WTF!
adb shell 'pm list packages -f' 
adb backup -apk com.moneyqube -f mi2s-package.ab



[1]: http://android.stackexchange.com/questions/28296/full-backup-of-non-rooted-devices

Google Authenticator - lastpass


因為last pass 的 2-factors authentication show code 的地方沒有 link 常見的底線,容易被忽略 ...... 

接下來跳出的 QR code 用 QR droid 及 手機內建的相機可能辨識不出來,要裝 goggles 就可以了。

2015年4月11日 星期六

docker - 從 container 產生 dockerfile 行不行


最近剛摸 docker ,在學習的時後,就一直有一個問題困擾我。
那就是 docker 可以用 dockerfile 產生 image 也是可以用來作版本控管或分享的一個方式。但是我們在 run 一個 container 時,可能會為了創建環境,而在裡面安了很多 package ,而且應該都是缺什麼裝什麼,一個一個手動裝的。所以等環境建立完,可能自已也忘了裝了什麼 package。 這個時後又想要用 dockerfile 來控管版本或分享給別人,怎麼辨呢?
剛好在 "Docker —— 從入門到實踐" 中看到 "從映像檔產生 Dockerfile" 的說明,覺得應該有機會,因此我從了下面的嘗試。

1. 從在 container 中裝一些 package ex. vim
2. 透過 docker commit 將其 container commit 到某版 image.
3. 透過 command 將 dockerfile 導出。
docker run -v /var/run/docker.sock:/var/run/docker.sock \ centurylink/dockerfile-from-image <IMAGE_TAG_OR_ID> > Dockerfile.txt
4. 只看出導出之 dockerfile 只有一行
FROM ubuntu:vivid

所以,看來目前還是不行的 ....

2015年4月9日 星期四

µBlock - Android 手機看網頁不再有煩人廣告

朋友介紹 µBlock 這個在 PC 版的 Chrome/Firebox/Opera 上的plugin 可以擋廣告,因為 Firefox Android 版也可以裝 plugin (add-ons) 所以就想說應該可以支援囉。
但是從 Android 點入安裝卻出現目前版本不支援?!




原來是最新版還沒有放到首頁,所以可以從 All version 點進去,就看到 0.9.1.0 最新版,就可以安裝囉~






2015年2月26日 星期四