Permalink
Browse files

moved apps to /assets repo

Change-Id: I12820058ebf69a861e366f9883c5a3345d50dd2e
  • Loading branch information...
1 parent ef84d25 commit dec29b834e124150aeebda8e7a96c6c77df34b6c Winston Koh committed Oct 25, 2011
Showing with 24,325 additions and 0 deletions.
  1. +8 −0 django/simple_django_app/README.md
  2. 0 django/simple_django_app/__init__.py
  3. +14 −0 django/simple_django_app/manage.py
  4. +136 −0 django/simple_django_app/settings.py
  5. +1 −0 django/simple_django_app/templates/404.html
  6. +1 −0 django/simple_django_app/templates/500.html
  7. +8 −0 django/simple_django_app/templates/index.html
  8. +6 −0 django/simple_django_app/urls.py
  9. +8 −0 django/simple_wsgi_app/README.md
  10. +7 −0 django/simple_wsgi_app/wsgi.py
  11. +1 −0 django/wsgi_app_with_requirements/requirements.txt
  12. +9 −0 django/wsgi_app_with_requirements/wsgi.py
  13. +9 −0 mochiweb/mochiweb_test/.gitignore
  14. +35 −0 mochiweb/mochiweb_test/Makefile
  15. +22 −0 mochiweb/mochiweb_test/README
  16. +8 −0 mochiweb/mochiweb_test/priv/www/index.html
  17. BIN mochiweb/mochiweb_test/rebar
  18. +8 −0 mochiweb/mochiweb_test/rebar.config
  19. +10 −0 mochiweb/mochiweb_test/rel/files/app.config
  20. +34 −0 mochiweb/mochiweb_test/rel/files/erl
  21. +156 −0 mochiweb/mochiweb_test/rel/files/mochiweb_test
  22. +138 −0 mochiweb/mochiweb_test/rel/files/nodetool
  23. +19 −0 mochiweb/mochiweb_test/rel/files/vm.args
  24. +32 −0 mochiweb/mochiweb_test/rel/reltool.config
  25. +9 −0 mochiweb/mochiweb_test/src/mochiweb_test.app.src
  26. +30 −0 mochiweb/mochiweb_test/src/mochiweb_test.erl
  27. +22 −0 mochiweb/mochiweb_test/src/mochiweb_test_app.erl
  28. +84 −0 mochiweb/mochiweb_test/src/mochiweb_test_deps.erl
  29. +60 −0 mochiweb/mochiweb_test/src/mochiweb_test_sup.erl
  30. +70 −0 mochiweb/mochiweb_test/src/mochiweb_test_web.erl
  31. +6 −0 mochiweb/mochiweb_test/start-dev.sh
  32. +3 −0 php/simple_php_app/index.php
  33. +4 −0 rails3/dbrails_app/.gitignore
  34. +33 −0 rails3/dbrails_app/Gemfile
  35. +80 −0 rails3/dbrails_app/Gemfile.lock
  36. +256 −0 rails3/dbrails_app/README
  37. +7 −0 rails3/dbrails_app/Rakefile
  38. +3 −0 rails3/dbrails_app/app/controllers/application_controller.rb
  39. +78 −0 rails3/dbrails_app/app/controllers/db_controller.rb
  40. +2 −0 rails3/dbrails_app/app/helpers/application_helper.rb
  41. +2 −0 rails3/dbrails_app/app/helpers/db_helper.rb
  42. +2 −0 rails3/dbrails_app/app/models/spooge.rb
  43. +14 −0 rails3/dbrails_app/app/views/layouts/application.html.erb
  44. +4 −0 rails3/dbrails_app/config.ru
  45. +42 −0 rails3/dbrails_app/config/application.rb
  46. +6 −0 rails3/dbrails_app/config/boot.rb
  47. +22 −0 rails3/dbrails_app/config/database.yml
  48. +5 −0 rails3/dbrails_app/config/environment.rb
  49. +25 −0 rails3/dbrails_app/config/environments/development.rb
  50. +49 −0 rails3/dbrails_app/config/environments/production.rb
  51. +35 −0 rails3/dbrails_app/config/environments/test.rb
  52. +7 −0 rails3/dbrails_app/config/initializers/backtrace_silencers.rb
  53. +10 −0 rails3/dbrails_app/config/initializers/inflections.rb
  54. +5 −0 rails3/dbrails_app/config/initializers/mime_types.rb
  55. +7 −0 rails3/dbrails_app/config/initializers/secret_token.rb
  56. +8 −0 rails3/dbrails_app/config/initializers/session_store.rb
  57. +5 −0 rails3/dbrails_app/config/locales/en.yml
  58. +59 −0 rails3/dbrails_app/config/routes.rb
  59. +16 −0 rails3/dbrails_app/db/migrate/20110312235149_create_spooges.rb
  60. +8 −0 rails3/dbrails_app/db/migrate/20110313001757_rename_my_column_by_hand.rb
  61. +24 −0 rails3/dbrails_app/db/schema.rb
  62. +7 −0 rails3/dbrails_app/db/seeds.rb
  63. +2 −0 rails3/dbrails_app/doc/README_FOR_APP
  64. 0 rails3/dbrails_app/lib/tasks/.gitkeep
  65. +26 −0 rails3/dbrails_app/public/404.html
  66. +26 −0 rails3/dbrails_app/public/422.html
  67. +26 −0 rails3/dbrails_app/public/500.html
  68. 0 rails3/dbrails_app/public/favicon.ico
  69. BIN rails3/dbrails_app/public/images/rails.png
  70. +239 −0 rails3/dbrails_app/public/index.html
  71. +2 −0 rails3/dbrails_app/public/javascripts/application.js
  72. +965 −0 rails3/dbrails_app/public/javascripts/controls.js
  73. +974 −0 rails3/dbrails_app/public/javascripts/dragdrop.js
  74. +1,123 −0 rails3/dbrails_app/public/javascripts/effects.js
  75. +6,001 −0 rails3/dbrails_app/public/javascripts/prototype.js
  76. +191 −0 rails3/dbrails_app/public/javascripts/rails.js
  77. +5 −0 rails3/dbrails_app/public/robots.txt
  78. 0 rails3/dbrails_app/public/stylesheets/.gitkeep
  79. +6 −0 rails3/dbrails_app/script/rails
  80. +13 −0 rails3/dbrails_app/test/fixtures/spooges.yml
  81. +8 −0 rails3/dbrails_app/test/functional/db_controller_test.rb
  82. +9 −0 rails3/dbrails_app/test/performance/browsing_test.rb
  83. +13 −0 rails3/dbrails_app/test/test_helper.rb
  84. +4 −0 rails3/dbrails_app/test/unit/helpers/db_helper_test.rb
  85. +8 −0 rails3/dbrails_app/test/unit/spooge_test.rb
  86. BIN rails3/dbrails_app/vendor/cache/abstract-1.0.0.gem
  87. BIN rails3/dbrails_app/vendor/cache/actionmailer-3.0.5.gem
  88. BIN rails3/dbrails_app/vendor/cache/actionpack-3.0.5.gem
  89. BIN rails3/dbrails_app/vendor/cache/activemodel-3.0.5.gem
  90. BIN rails3/dbrails_app/vendor/cache/activerecord-3.0.5.gem
  91. BIN rails3/dbrails_app/vendor/cache/activeresource-3.0.5.gem
  92. BIN rails3/dbrails_app/vendor/cache/activesupport-3.0.5.gem
  93. BIN rails3/dbrails_app/vendor/cache/arel-2.0.9.gem
  94. BIN rails3/dbrails_app/vendor/cache/builder-2.1.2.gem
  95. BIN rails3/dbrails_app/vendor/cache/daemons-1.1.2.gem
  96. BIN rails3/dbrails_app/vendor/cache/erubis-2.6.6.gem
  97. BIN rails3/dbrails_app/vendor/cache/eventmachine-0.12.10.gem
  98. BIN rails3/dbrails_app/vendor/cache/i18n-0.5.0.gem
  99. BIN rails3/dbrails_app/vendor/cache/mail-2.2.15.gem
  100. BIN rails3/dbrails_app/vendor/cache/mime-types-1.16.gem
  101. BIN rails3/dbrails_app/vendor/cache/mysql2-0.2.7.gem
  102. BIN rails3/dbrails_app/vendor/cache/polyglot-0.3.1.gem
  103. BIN rails3/dbrails_app/vendor/cache/rack-1.2.1.gem
  104. BIN rails3/dbrails_app/vendor/cache/rack-mount-0.6.13.gem
  105. BIN rails3/dbrails_app/vendor/cache/rack-test-0.5.7.gem
  106. BIN rails3/dbrails_app/vendor/cache/rails-3.0.5.gem
  107. BIN rails3/dbrails_app/vendor/cache/railties-3.0.5.gem
  108. BIN rails3/dbrails_app/vendor/cache/rake-0.8.7.gem
  109. BIN rails3/dbrails_app/vendor/cache/thin-1.2.11.gem
  110. BIN rails3/dbrails_app/vendor/cache/thor-0.14.6.gem
  111. BIN rails3/dbrails_app/vendor/cache/treetop-1.4.9.gem
  112. BIN rails3/dbrails_app/vendor/cache/tzinfo-0.3.24.gem
  113. 0 rails3/dbrails_app/vendor/plugins/.gitkeep
  114. +4 −0 rails3/dbrails_broken_app/.gitignore
  115. +31 −0 rails3/dbrails_broken_app/Gemfile
  116. +78 −0 rails3/dbrails_broken_app/Gemfile.lock
  117. +256 −0 rails3/dbrails_broken_app/README
  118. +7 −0 rails3/dbrails_broken_app/Rakefile
  119. +3 −0 rails3/dbrails_broken_app/app/controllers/application_controller.rb
  120. +75 −0 rails3/dbrails_broken_app/app/controllers/db_controller.rb
  121. +2 −0 rails3/dbrails_broken_app/app/helpers/application_helper.rb
  122. +2 −0 rails3/dbrails_broken_app/app/helpers/db_helper.rb
  123. +2 −0 rails3/dbrails_broken_app/app/models/spooge.rb
  124. +14 −0 rails3/dbrails_broken_app/app/views/layouts/application.html.erb
  125. +4 −0 rails3/dbrails_broken_app/config.ru
  126. +42 −0 rails3/dbrails_broken_app/config/application.rb
  127. +6 −0 rails3/dbrails_broken_app/config/boot.rb
  128. +22 −0 rails3/dbrails_broken_app/config/database.yml
  129. +5 −0 rails3/dbrails_broken_app/config/environment.rb
  130. +25 −0 rails3/dbrails_broken_app/config/environments/development.rb
  131. +49 −0 rails3/dbrails_broken_app/config/environments/production.rb
  132. +35 −0 rails3/dbrails_broken_app/config/environments/test.rb
  133. +7 −0 rails3/dbrails_broken_app/config/initializers/backtrace_silencers.rb
  134. +10 −0 rails3/dbrails_broken_app/config/initializers/inflections.rb
  135. +5 −0 rails3/dbrails_broken_app/config/initializers/mime_types.rb
  136. +7 −0 rails3/dbrails_broken_app/config/initializers/secret_token.rb
  137. +8 −0 rails3/dbrails_broken_app/config/initializers/session_store.rb
  138. +5 −0 rails3/dbrails_broken_app/config/locales/en.yml
  139. +59 −0 rails3/dbrails_broken_app/config/routes.rb
  140. +1 −0 rails3/dbrails_broken_app/db/blah.rb
  141. +16 −0 rails3/dbrails_broken_app/db/migrate/20110312235149_create_spooges.rb
  142. +8 −0 rails3/dbrails_broken_app/db/migrate/20110313001757_rename_my_column_by_hand.rb
  143. +24 −0 rails3/dbrails_broken_app/db/schema.rb
  144. +7 −0 rails3/dbrails_broken_app/db/seeds.rb
  145. +2 −0 rails3/dbrails_broken_app/doc/README_FOR_APP
  146. 0 rails3/dbrails_broken_app/lib/tasks/.gitkeep
  147. +26 −0 rails3/dbrails_broken_app/public/404.html
  148. +26 −0 rails3/dbrails_broken_app/public/422.html
  149. +26 −0 rails3/dbrails_broken_app/public/500.html
  150. 0 rails3/dbrails_broken_app/public/favicon.ico
  151. BIN rails3/dbrails_broken_app/public/images/rails.png
  152. +239 −0 rails3/dbrails_broken_app/public/index.html
  153. +2 −0 rails3/dbrails_broken_app/public/javascripts/application.js
  154. +965 −0 rails3/dbrails_broken_app/public/javascripts/controls.js
  155. +974 −0 rails3/dbrails_broken_app/public/javascripts/dragdrop.js
  156. +1,123 −0 rails3/dbrails_broken_app/public/javascripts/effects.js
  157. +6,001 −0 rails3/dbrails_broken_app/public/javascripts/prototype.js
  158. +191 −0 rails3/dbrails_broken_app/public/javascripts/rails.js
  159. +5 −0 rails3/dbrails_broken_app/public/robots.txt
  160. 0 rails3/dbrails_broken_app/public/stylesheets/.gitkeep
  161. +6 −0 rails3/dbrails_broken_app/script/rails
  162. +13 −0 rails3/dbrails_broken_app/test/fixtures/spooges.yml
  163. +8 −0 rails3/dbrails_broken_app/test/functional/db_controller_test.rb
  164. +9 −0 rails3/dbrails_broken_app/test/performance/browsing_test.rb
  165. +13 −0 rails3/dbrails_broken_app/test/test_helper.rb
  166. +4 −0 rails3/dbrails_broken_app/test/unit/helpers/db_helper_test.rb
  167. +8 −0 rails3/dbrails_broken_app/test/unit/spooge_test.rb
  168. BIN rails3/dbrails_broken_app/vendor/cache/abstract-1.0.0.gem
  169. BIN rails3/dbrails_broken_app/vendor/cache/actionmailer-3.0.5.gem
  170. BIN rails3/dbrails_broken_app/vendor/cache/actionpack-3.0.5.gem
  171. BIN rails3/dbrails_broken_app/vendor/cache/activemodel-3.0.5.gem
  172. BIN rails3/dbrails_broken_app/vendor/cache/activerecord-3.0.5.gem
  173. BIN rails3/dbrails_broken_app/vendor/cache/activeresource-3.0.5.gem
  174. BIN rails3/dbrails_broken_app/vendor/cache/activesupport-3.0.5.gem
  175. BIN rails3/dbrails_broken_app/vendor/cache/arel-2.0.9.gem
  176. BIN rails3/dbrails_broken_app/vendor/cache/builder-2.1.2.gem
  177. BIN rails3/dbrails_broken_app/vendor/cache/daemons-1.1.2.gem
  178. BIN rails3/dbrails_broken_app/vendor/cache/erubis-2.6.6.gem
  179. BIN rails3/dbrails_broken_app/vendor/cache/eventmachine-0.12.10.gem
  180. BIN rails3/dbrails_broken_app/vendor/cache/i18n-0.5.0.gem
  181. BIN rails3/dbrails_broken_app/vendor/cache/mail-2.2.15.gem
  182. BIN rails3/dbrails_broken_app/vendor/cache/mime-types-1.16.gem
  183. BIN rails3/dbrails_broken_app/vendor/cache/polyglot-0.3.1.gem
  184. BIN rails3/dbrails_broken_app/vendor/cache/rack-1.2.1.gem
  185. BIN rails3/dbrails_broken_app/vendor/cache/rack-mount-0.6.13.gem
  186. BIN rails3/dbrails_broken_app/vendor/cache/rack-test-0.5.7.gem
  187. BIN rails3/dbrails_broken_app/vendor/cache/rails-3.0.5.gem
  188. BIN rails3/dbrails_broken_app/vendor/cache/railties-3.0.5.gem
  189. BIN rails3/dbrails_broken_app/vendor/cache/rake-0.8.7.gem
  190. BIN rails3/dbrails_broken_app/vendor/cache/thin-1.2.11.gem
  191. BIN rails3/dbrails_broken_app/vendor/cache/thor-0.14.6.gem
  192. BIN rails3/dbrails_broken_app/vendor/cache/treetop-1.4.9.gem
  193. BIN rails3/dbrails_broken_app/vendor/cache/tzinfo-0.3.24.gem
  194. 0 rails3/dbrails_broken_app/vendor/plugins/.gitkeep
  195. +4 −0 rails3/rails3_app/.gitignore
  196. +8 −0 rails3/rails3_app/Gemfile
  197. +85 −0 rails3/rails3_app/Gemfile.lock
  198. +256 −0 rails3/rails3_app/README
  199. +7 −0 rails3/rails3_app/Rakefile
  200. +3 −0 rails3/rails3_app/app/controllers/application_controller.rb
  201. +13 −0 rails3/rails3_app/app/controllers/root_controller.rb
  202. +2 −0 rails3/rails3_app/app/helpers/application_helper.rb
  203. +2 −0 rails3/rails3_app/app/helpers/root_helper.rb
  204. +2 −0 rails3/rails3_app/app/models/widget.rb
  205. +11 −0 rails3/rails3_app/app/views/layouts/application.html.erb
  206. +5 −0 rails3/rails3_app/app/views/root/index.html.erb
  207. +4 −0 rails3/rails3_app/config.ru
  208. +42 −0 rails3/rails3_app/config/application.rb
  209. +13 −0 rails3/rails3_app/config/boot.rb
  210. +12 −0 rails3/rails3_app/config/database.yml
  211. +5 −0 rails3/rails3_app/config/environment.rb
  212. +25 −0 rails3/rails3_app/config/environments/development.rb
  213. +49 −0 rails3/rails3_app/config/environments/production.rb
  214. +35 −0 rails3/rails3_app/config/environments/test.rb
  215. +7 −0 rails3/rails3_app/config/initializers/backtrace_silencers.rb
  216. +10 −0 rails3/rails3_app/config/initializers/inflections.rb
  217. +5 −0 rails3/rails3_app/config/initializers/mime_types.rb
  218. +7 −0 rails3/rails3_app/config/initializers/secret_token.rb
  219. +8 −0 rails3/rails3_app/config/initializers/session_store.rb
  220. +5 −0 rails3/rails3_app/config/locales/en.yml
  221. +61 −0 rails3/rails3_app/config/routes.rb
  222. +13 −0 rails3/rails3_app/db/migrate/20101108182500_create_widgets.rb
  223. +21 −0 rails3/rails3_app/db/schema.rb
  224. +7 −0 rails3/rails3_app/db/seeds.rb
  225. 0 rails3/rails3_app/lib/tasks/.gitkeep
  226. +26 −0 rails3/rails3_app/public/404.html
  227. +26 −0 rails3/rails3_app/public/422.html
  228. +26 −0 rails3/rails3_app/public/500.html
  229. 0 rails3/rails3_app/public/favicon.ico
  230. BIN rails3/rails3_app/public/images/rails.png
  231. 0 rails3/rails3_app/public/javascripts/.gitkeep
  232. 0 rails3/rails3_app/public/javascripts/application.js
  233. +5 −0 rails3/rails3_app/public/robots.txt
  234. 0 rails3/rails3_app/public/stylesheets/.gitkeep
  235. +6 −0 rails3/rails3_app/script/rails
  236. +14 −0 rails3/rails3_app/test/functional/root_controller_test.rb
  237. +9 −0 rails3/rails3_app/test/performance/browsing_test.rb
  238. +13 −0 rails3/rails3_app/test/test_helper.rb
  239. +4 −0 rails3/rails3_app/test/unit/helpers/root_helper_test.rb
  240. +12 −0 rails3/rails3_app/test/unit/widget_test.rb
  241. +9 −0 sinatra/broken_app/broken.rb
  242. +5 −0 sinatra/brokered_service_app/Gemfile
  243. +23 −0 sinatra/brokered_service_app/Gemfile.lock
  244. +34 −0 sinatra/brokered_service_app/server.rb
  245. +4 −0 sinatra/env_test_app/Gemfile
  246. +17 −0 sinatra/env_test_app/Gemfile.lock
  247. +57 −0 sinatra/env_test_app/env_test.rb
  248. BIN sinatra/env_test_app/vendor/cache/json-1.5.1.gem
  249. BIN sinatra/env_test_app/vendor/cache/rack-1.2.2.gem
  250. BIN sinatra/env_test_app/vendor/cache/sinatra-1.2.1.gem
  251. BIN sinatra/env_test_app/vendor/cache/tilt-1.2.2.gem
  252. +13 −0 sinatra/modified_simple_app/foo.rb
  253. +3 −0 sinatra/neo4j_app/Gemfile
  254. +22 −0 sinatra/neo4j_app/Gemfile.lock
  255. +94 −0 sinatra/neo4j_app/neo4j.rb
  256. BIN sinatra/neo4j_app/vendor/cache/crack-0.1.8.gem
  257. BIN sinatra/neo4j_app/vendor/cache/httparty-0.7.7.gem
  258. BIN sinatra/neo4j_app/vendor/cache/json-1.5.1.gem
  259. BIN sinatra/neo4j_app/vendor/cache/neography-0.0.13.gem
  260. BIN sinatra/neo4j_app/vendor/cache/rack-1.2.2.gem
  261. BIN sinatra/neo4j_app/vendor/cache/sinatra-1.2.6.gem
  262. BIN sinatra/neo4j_app/vendor/cache/tilt-1.3.gem
  263. +5 −0 sinatra/redis_lb_app/Gemfile
  264. +19 −0 sinatra/redis_lb_app/Gemfile.lock
  265. +92 −0 sinatra/redis_lb_app/redis_lb.rb
  266. BIN sinatra/redis_lb_app/vendor/cache/json-1.5.1.gem
  267. BIN sinatra/redis_lb_app/vendor/cache/rack-1.2.2.gem
  268. BIN sinatra/redis_lb_app/vendor/cache/redis-2.2.0.gem
  269. BIN sinatra/redis_lb_app/vendor/cache/sinatra-1.2.1.gem
  270. BIN sinatra/redis_lb_app/vendor/cache/tilt-1.2.2.gem
  271. +5 −0 sinatra/simple_db_app/config/simple_db_app.yml
  272. +9 −0 sinatra/simple_db_app/lib/models/user.rb
  273. +126 −0 sinatra/simple_db_app/simple_db_app.rb
  274. +4 −0 sinatra/simple_kv_app/Gemfile
  275. +21 −0 sinatra/simple_kv_app/Gemfile.lock
  276. +26 −0 sinatra/simple_kv_app/server.rb
  277. +51 −0 sinatra/speed/speed.rb
  278. +66 −0 sinatra/webapp/webapp.rb
  279. +13 −0 spring/hibernate-guestbook/README
  280. +204 −0 spring/hibernate-guestbook/pom.xml
  281. +38 −0 spring/hibernate-guestbook/src/main/java/com/vmware/appcloud/testapps/guestbook/Guest.java
  282. +32 −0 spring/hibernate-guestbook/src/main/java/com/vmware/appcloud/testapps/guestbook/GuestController.java
  283. +24 −0 spring/hibernate-guestbook/src/main/java/com/vmware/appcloud/testapps/guestbook/GuestDao.java
  284. +2 −0 spring/hibernate-guestbook/src/main/webapp/META-INF/MANIFEST.MF
  285. +66 −0 spring/hibernate-guestbook/src/main/webapp/WEB-INF/guest-servlet.xml
  286. +28 −0 spring/hibernate-guestbook/src/main/webapp/WEB-INF/guest.jsp
  287. +25 −0 spring/hibernate-guestbook/src/main/webapp/WEB-INF/web.xml
  288. +1 −0 spring/hibernate-guestbook/src/main/webapp/index.jsp
  289. +13 −0 spring/jpa-guestbook/README
  290. +210 −0 spring/jpa-guestbook/pom.xml
  291. +30 −0 spring/jpa-guestbook/src/main/java/com/vmware/appcloud/testapps/guestbook/Guest.java
  292. +27 −0 spring/jpa-guestbook/src/main/java/com/vmware/appcloud/testapps/guestbook/GuestController.java
  293. +27 −0 spring/jpa-guestbook/src/main/java/com/vmware/appcloud/testapps/guestbook/GuestDao.java
  294. +18 −0 spring/jpa-guestbook/src/main/resources/META-INF/persistence.xml
  295. +2 −0 spring/jpa-guestbook/src/main/webapp/META-INF/MANIFEST.MF
  296. +59 −0 spring/jpa-guestbook/src/main/webapp/WEB-INF/guest-servlet.xml
  297. +28 −0 spring/jpa-guestbook/src/main/webapp/WEB-INF/guest.jsp
  298. +24 −0 spring/jpa-guestbook/src/main/webapp/WEB-INF/web.xml
  299. +1 −0 spring/jpa-guestbook/src/main/webapp/index.jsp
@@ -0,0 +1,8 @@
+This is a simple Django application (no databases involved).
+
+Deployment
+----------
+
+To deploy this application:
+
+ vmc push simple_django_app
No changes.
@@ -0,0 +1,14 @@
+#!/usr/bin/env python
+from django.core.management import execute_manager
+import imp
+try:
+ imp.find_module('settings') # Assumed to be in the same directory.
+except ImportError:
+ import sys
+ sys.stderr.write("Error: Can't find the file 'settings.py' in the directory containing %r. It appears you've customized things.\nYou'll have to run django-admin.py, passing it your settings module.\n" % __file__)
+ sys.exit(1)
+
+import settings
+
+if __name__ == "__main__":
+ execute_manager(settings)
@@ -0,0 +1,136 @@
+import os
+
+SITE_ROOT = os.path.dirname(os.path.realpath(__file__))
+
+DEBUG = False
+TEMPLATE_DEBUG = DEBUG
+
+ADMINS = (
+ # ('Your Name', 'your_email@example.com'),
+)
+
+MANAGERS = ADMINS
+
+DATABASES = {}
+
+# Local time zone for this installation. Choices can be found here:
+# http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
+# although not all choices may be available on all operating systems.
+# On Unix systems, a value of None will cause Django to use the same
+# timezone as the operating system.
+# If running in a Windows environment this must be set to the same as your
+# system time zone.
+TIME_ZONE = 'America/Chicago'
+
+# Language code for this installation. All choices can be found here:
+# http://www.i18nguy.com/unicode/language-identifiers.html
+LANGUAGE_CODE = 'en-us'
+
+SITE_ID = 1
+
+# If you set this to False, Django will make some optimizations so as not
+# to load the internationalization machinery.
+USE_I18N = False
+
+# If you set this to False, Django will not format dates, numbers and
+# calendars according to the current locale
+USE_L10N = False
+
+# Absolute filesystem path to the directory that will hold user-uploaded files.
+# Example: "/home/media/media.lawrence.com/media/"
+MEDIA_ROOT = ''
+
+# URL that handles the media served from MEDIA_ROOT. Make sure to use a
+# trailing slash.
+# Examples: "http://media.lawrence.com/media/", "http://example.com/media/"
+MEDIA_URL = ''
+
+# Absolute path to the directory static files should be collected to.
+# Don't put anything in this directory yourself; store your static files
+# in apps' "static/" subdirectories and in STATICFILES_DIRS.
+# Example: "/home/media/media.lawrence.com/static/"
+STATIC_ROOT = ''
+
+# URL prefix for static files.
+# Example: "http://media.lawrence.com/static/"
+STATIC_URL = '/static/'
+
+# URL prefix for admin static files -- CSS, JavaScript and images.
+# Make sure to use a trailing slash.
+# Examples: "http://foo.com/static/admin/", "/static/admin/".
+ADMIN_MEDIA_PREFIX = '/static/admin/'
+
+# Additional locations of static files
+STATICFILES_DIRS = (
+ # Put strings here, like "/home/html/static" or "C:/www/django/static".
+ # Always use forward slashes, even on Windows.
+ # Don't forget to use absolute paths, not relative paths.
+)
+
+# List of finder classes that know how to find static files in
+# various locations.
+STATICFILES_FINDERS = (
+ 'django.contrib.staticfiles.finders.FileSystemFinder',
+ 'django.contrib.staticfiles.finders.AppDirectoriesFinder',
+# 'django.contrib.staticfiles.finders.DefaultStorageFinder',
+)
+
+# Make this unique, and don't share it with anybody.
+SECRET_KEY = '#=1z-r$%z2jju^*08rkp3u-!2k+-hwp4*-7pd-85-tvej1voy5'
+
+# List of callables that know how to import templates from various sources.
+TEMPLATE_LOADERS = (
+ 'django.template.loaders.filesystem.Loader',
+ 'django.template.loaders.app_directories.Loader',
+# 'django.template.loaders.eggs.Loader',
+)
+
+MIDDLEWARE_CLASSES = (
+ 'django.middleware.common.CommonMiddleware',
+ 'django.contrib.sessions.middleware.SessionMiddleware',
+ 'django.middleware.csrf.CsrfViewMiddleware',
+ 'django.contrib.auth.middleware.AuthenticationMiddleware',
+ 'django.contrib.messages.middleware.MessageMiddleware',
+)
+
+ROOT_URLCONF = 'urls'
+
+TEMPLATE_DIRS = (
+ os.path.join(SITE_ROOT, 'templates')
+)
+
+INSTALLED_APPS = (
+ 'django.contrib.auth',
+ 'django.contrib.contenttypes',
+ 'django.contrib.sessions',
+ 'django.contrib.sites',
+ 'django.contrib.messages',
+ 'django.contrib.staticfiles',
+ # Uncomment the next line to enable the admin:
+ # 'django.contrib.admin',
+ # Uncomment the next line to enable admin documentation:
+ # 'django.contrib.admindocs',
+)
+
+# A sample logging configuration. The only tangible logging
+# performed by this configuration is to send an email to
+# the site admins on every HTTP 500 error.
+# See http://docs.djangoproject.com/en/dev/topics/logging for
+# more details on how to customize your logging configuration.
+LOGGING = {
+ 'version': 1,
+ 'disable_existing_loggers': False,
+ 'handlers': {
+ 'mail_admins': {
+ 'level': 'ERROR',
+ 'class': 'django.utils.log.AdminEmailHandler'
+ }
+ },
+ 'loggers': {
+ 'django.request': {
+ 'handlers': ['mail_admins'],
+ 'level': 'ERROR',
+ 'propagate': True,
+ },
+ }
+}
@@ -0,0 +1 @@
+404
@@ -0,0 +1 @@
+500
@@ -0,0 +1,8 @@
+<html>
+ <head>
+ <title>Test</title>
+ </head>
+ <body>
+ iLorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.Hello from VCAP
+ </body>
+</html>
@@ -0,0 +1,6 @@
+from django.conf.urls.defaults import patterns, include, url
+from django.views.generic.simple import direct_to_template
+
+urlpatterns = patterns('',
+ url(r'^$', direct_to_template, {'template': 'index.html'}),
+)
@@ -0,0 +1,8 @@
+This is a simple Python WSGI application.
+
+Deployment
+----------
+
+To deploy this application:
+
+ vmc push simple_wsgi_app
@@ -0,0 +1,7 @@
+def application(environ, start_response):
+ data = "Hello from VCAP"
+ start_response("200 OK", [
+ ("Content-Type", "text/plain"),
+ ("Content-Length", str(len(data)))
+ ])
+ return iter([data])
@@ -0,0 +1 @@
+bottle
@@ -0,0 +1,9 @@
+import bottle
+
+def application(environ, start_response):
+ data = "Hello from VCAP"
+ start_response("200 OK", [
+ ("Content-Type", "text/plain"),
+ ("Content-Length", str(len(data)))
+ ])
+ return iter([data])
@@ -0,0 +1,9 @@
+/ebin
+/doc
+/_test
+/.eunit
+/docs
+.DS_Store
+/TEST-*.xml
+/rel/mochiweb_test
+/deps/mochiweb
@@ -0,0 +1,35 @@
+
+PREFIX:=../
+DEST:=$(PREFIX)$(PROJECT)
+
+REBAR=./rebar
+
+all:
+ @$(REBAR) get-deps compile
+
+edoc:
+ @$(REBAR) doc
+
+test:
+ @rm -rf .eunit
+ @mkdir -p .eunit
+ @$(REBAR) skip_deps=true eunit
+
+rel: all
+ ./rebar generate
+
+relclean:
+ rm -rf rel/mochiweb_test
+
+
+clean:
+ @$(REBAR) clean
+
+build_plt:
+ @$(REBAR) build-plt
+
+dialyzer:
+ @$(REBAR) dialyze
+
+app:
+ @$(REBAR) create template=mochiwebapp dest=$(DEST) appid=$(PROJECT)
@@ -0,0 +1,22 @@
+Erlang Support
+--------------
+
+This application demonstrates Erlang support from vcap. The application was generated
+using the Mochiweb "make app" command, and the only modification was to change:
+ Web = web_specs(mochiweb_test_web, 8080),
+to:
+ Web = web_specs(mochiweb_test_web,
+ case os:getenv("VMC_APP_PORT") of
+ false -> 9090;
+ P -> list_to_integer(P)
+ end),
+
+in mochiweb_test_sup:init, allowing for the VMC port to be injected.
+
+
+Deployment
+----------
+To deploy this application, execute:
+ vmc update erlang --url erlang.vcap.me
+
+Note that you'll need erlang-nox installed on the cloud host.
@@ -0,0 +1,8 @@
+<html>
+<head>
+<title>It Worked</title>
+</head>
+<body>
+mochiweb_test running.
+</body>
+</html>
Binary file not shown.
@@ -0,0 +1,8 @@
+%% -*- erlang -*-
+{erl_opts, [debug_info]}.
+{deps, [
+ {mochiweb, ".*",
+ {git, "git://github.com/mochi/mochiweb.git", "master"}}]}.
+{cover_enabled, true}.
+{eunit_opts, [verbose, {report,{eunit_surefire,[{dir,"."}]}}]}.
+{sub_dirs, ["rel"]}.
@@ -0,0 +1,10 @@
+[
+ %% SASL config
+ {sasl, [
+ {sasl_error_logger, {file, "log/sasl-error.log"}},
+ {errlog_type, error},
+ {error_logger_mf_dir, "log/sasl"}, % Log directory
+ {error_logger_mf_maxbytes, 10485760}, % 10 MB max file size
+ {error_logger_mf_maxfiles, 5} % 5 files max
+ ]}
+].
@@ -0,0 +1,34 @@
+#!/bin/bash
+
+## This script replaces the default "erl" in erts-VSN/bin. This is necessary
+## as escript depends on erl and in turn, erl depends on having access to a
+## bootscript (start.boot). Note that this script is ONLY invoked as a side-effect
+## of running escript -- the embedded node bypasses erl and uses erlexec directly
+## (as it should).
+##
+## Note that this script makes the assumption that there is a start_clean.boot
+## file available in $ROOTDIR/release/VSN.
+
+# Determine the abspath of where this script is executing from.
+ERTS_BIN_DIR=$(cd ${0%/*} && pwd)
+
+# Now determine the root directory -- this script runs from erts-VSN/bin,
+# so we simply need to strip off two dirs from the end of the ERTS_BIN_DIR
+# path.
+ROOTDIR=${ERTS_BIN_DIR%/*/*}
+
+# Parse out release and erts info
+START_ERL=`cat $ROOTDIR/releases/start_erl.data`
+ERTS_VSN=${START_ERL% *}
+APP_VSN=${START_ERL#* }
+
+BINDIR=$ROOTDIR/erts-$ERTS_VSN/bin
+EMU=beam
+PROGNAME=`echo $0 | sed 's/.*\\///'`
+CMD="$BINDIR/erlexec"
+export EMU
+export ROOTDIR
+export BINDIR
+export PROGNAME
+
+exec $CMD -boot $ROOTDIR/releases/$APP_VSN/start_clean ${1+"$@"}
Oops, something went wrong.

0 comments on commit dec29b8

Please sign in to comment.