Skip to content

Instantly share code, notes, and snippets.

View mingder78's full-sized avatar
🌴
On vacation

Ming-der Wang mingder78

🌴
On vacation
  • Tone Leader Technology Corp.
  • Taipei, Taiwan
View GitHub Profile
@mingder78
mingder78 / script boxen
Created April 11, 2013 11:40
script boxen
Ming-Mac-mini-2$ script/boxen
--> Hey, I need your current GitHub credentials to continue.
GitHub login: |mingderwang|
GitHub password: *************
Password for sudo:
Notice: /Stage[main]/Boxen::Config/File[/Users/ming/src]/ensure: created
Notice: /Stage[main]/Boxen::Config/File[/opt/boxen/bin]/ensure: created
Notice: /Stage[main]/Boxen::Config/File[/opt/boxen/data]/ensure: created
Notice: /Stage[main]/Boxen::Config/File[/opt/boxen/data/project-sockets]/ensure: created
@mingder78
mingder78 / gist:5419003
Last active December 16, 2015 10:19
facebook for iOS using Cocoapod
0. install cocoapod, refer to URL: http://cocoapods.org/
1. create a new iOS xcode project.
2. create a Pofile (filename is Podfile) in that project home directory with following content.
platform :ios, "5.0"
pod do |s|
s.name = 'Facebook-iOS-SDK'
s.version = '3.5.0'
s.platform = :ios
@mingder78
mingder78 / gist:10253375
Created April 9, 2014 10:42
rhc app create mycamelwiki jbossews-2.0 --from-code=http://github.com/hawtio/hawtio-camel-wiki.git
Application Options
-------------------
Domain: facebook
Cartridges: jbossews-2.0
Source Code: http://github.com/hawtio/hawtio-camel-wiki.git
Gear Size: default
Scaling: no
Creating application 'mycamelwiki' ...
The initial build for the application failed: Shell command '/sbin/runuser -s /bin/sh 5345210b5973cab95d000a23 -c "exec /usr/bin/runcon 'unconfined_u:system_r:openshift_t:s0:c6,c563' /bin/sh -c
@mingder78
mingder78 / gist:10253544
Created April 9, 2014 10:44
hawtio-camel-wiki, same error when running jetty on local.
mvn jetty:run [18:30:39]
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building hawtio-camel-wiki 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] >>> jetty-maven-plugin:7.6.9.v20130131:run (default-cli) @ hawtio-camel-wiki >>>
Downloading: https://repository.jboss.org/nexus/content/groups/ea/io/hawt/hawtio-default/1.2.1/hawtio-default-1.2.1.pom
Downloading: http://repo.maven.apache.org/maven2/io/hawt/hawtio-default/1.2.1/hawtio-default-1.2.1.pom
@mingder78
mingder78 / gist:10347383
Created April 10, 2014 06:20
$rhc cartridge list
jbossas-7 JBoss Application Server 7 web
jboss-dv-6.0.0 (!) JBoss Data Virtualization 6 web
jbosseap-6 (*) JBoss Enterprise Application Platform 6 web
jenkins-1 Jenkins Server web
nodejs-0.10 Node.js 0.10 web
nodejs-0.6 Node.js 0.6 web
perl-5.10 Perl 5.10 web
php-5.3 PHP 5.3 web
zend-5.6 PHP 5.3 with Zend Server 5.6 web
php-5.4 PHP 5.4 web
@mingder78
mingder78 / gist:10481584
Created April 11, 2014 16:20
install hawtio plugin
osgi:install -s mvn:io.hawt/custom-perspective/1.3-SNAPSHOT/war
@mingder78
mingder78 / set-server-time-to-ROC.sh
Created May 26, 2014 15:41
set server timer to ROC time zone
# set the server time to ROC
sudo mv /etc/localtime /etc/localtime.bak
sudo ln -s /usr/share/zoneinfo/ROC /etc/localtime
sudo service ntpd restart
# sync to ntpd server time
sudo ntpd -q
# start ntpd after reboot
sudo chkconfig ntpd on
@mingder78
mingder78 / index.html
Created July 5, 2014 03:49
A Pen by Ming-der Wang.
<html ng-app>
<head>
<script src="//cdnjs.cloudflare.com/ajax/libs/angular.js/1.1.5/angular.min.js"></script>
<link href="//cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/2.3.2/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
<script src="//cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/2.3.2/js/bootstrap.min.js"></script>
<meta charset=utf-8 />
<title>Angular JS Demo</title>
</head>
<body>
@mingder78
mingder78 / gist:ef7128e0303164394ef2
Created July 12, 2014 10:12
trouble to get node.js starting?
iptables -t nat -D PREROUTING -p tcp --dport 80 -j REDIRECT --to 8080.
Your public key has been saved in /Users/ming/.ssh/id_boot2docker.pub.
The key fingerprint is:
dd:40:e1:48:87:d8:81:62:e8:4d:77:cd:b0:a5:4d:3c ming@ming-desktop
The key's randomart image is:
+--[ RSA 2048]----+
| . ++B*. |
| . + +.+@E |
| . + o .+ +. |
| . . . o |
| S . . |