{"id":327,"date":"2012-11-29T04:28:30","date_gmt":"2012-11-29T04:28:30","guid":{"rendered":"http:\/\/corneliadavis.com\/blog\/?p=327"},"modified":"2012-11-29T04:28:30","modified_gmt":"2012-11-29T04:28:30","slug":"customizing-micro-cloud-foundry","status":"publish","type":"post","link":"https:\/\/corneliadavis.com\/blog\/2012\/11\/29\/customizing-micro-cloud-foundry\/","title":{"rendered":"Customizing Micro Cloud Foundry?"},"content":{"rendered":"<p>I love <a href=\"http:\/\/micro.cloudfoundry.com\">micro cloud foundry<\/a>.\u00a0 I spend a fair bit of time on airplanes, and I hate not being able to work because my internet connection is flaky in some hotel room so being self sufficient when I am doing dev is critical. So good thinking, and thanks Cloud Foundry team.<\/p>\n<p>Micro cloud foundry is designed to be the self-standing companion to cloudfoundry.com and <a href=\"http:\/\/blog.cloudfoundry.com\/2012\/11\/08\/new-release-of-micro-cloud-foundry\/\">this recent blog post<\/a> indicates that the team is working to keep micro-cloud in synch with cloudfoundry.com. Coolness.\u00a0 But what happens when I want a self-standing &#8220;micro&#8221; version of cloud foundry that doesn&#8217;t match up with cloudfoundry.com, but rather a customized cloud &#8211; one that, say, has additional services available?\u00a0 Off the top of my head I can think of two basic approaches &#8211; 1) Customize micro cloud foundry or 2) <a href=\"https:\/\/github.com\/cloudfoundry\/vcap\/blob\/master\/README.md\">Create a single node cloud foundry<\/a> to run locally and install your customizations in there.\u00a0 I&#8217;ll explore #2 a bit more in another post, right now I want to poke on #1 a bit.<\/p>\n<p>I have spent many afternoons over the last couple of weeks perusing my micro cloud VM including reading a lot of ruby code and from that have reached a few conclusions (please speak up if you think I&#8217;m misguided on any of these):<\/p>\n<ul>\n<li>Micro cloud foundry is created by the folks at VMWare as a BOSH release that puts all the components on a single node.<\/li>\n<li>In addition to the cloud foundry components it also has a few bits specific to micro cloud foundry like the code for the console and offline mode.<\/li>\n<li>The directory structure that contains all of the bits is complex &#8211; lots of links from parts of the tree to other parts of the tree.<\/li>\n<li>On first startup entries are created in the embedded sql-lite DB &#8211; these are essentially installing, or better put, enabling certain parts of cloud foundry &#8211; for example, the available services have entries placed into the database.<\/li>\n<li>Hacking micro cloud foundry to add additional services (i.e. for <a href=\"http:\/\/cassandra.apache.org\/\">Cassandra<\/a>) is pretty much a no go &#8211; I tried.\u00a0 This is why the cloud foundry team created <a href=\"https:\/\/github.com\/cloudfoundry\/bosh\">BOSH<\/a> &#8211; doing these types of things by hand is awful. And I don&#8217;t even know all of the steps that need to be taken even if I was crazy enough to try it anyway.<\/li>\n<li>I should point out that existing <a href=\"http:\/\/support.cloudfoundry.com\/entries\/20485171-how-to-add-a-system-service-to-oss-cloud-foundry-step-by-step-guide\">documentation for how to create custom services<\/a> basically hacks into an existing deployment &#8211; none of those instructions match up with micro-cloud and the <a href=\"https:\/\/github.com\/cloudfoundry\/vcap-services-sample-release\">docs for adding services to BOSH-based deployments<\/a> starts with &#8220;get the cf-release&#8221; &#8211; more on this in a second.<\/li>\n<\/ul>\n<p>I&#8217;m convinced the right approach to creating a new version of micro cloud foundry is to get the micro cloud foundry bosh release, add my new service in there, do a bosh deploy and then take the resultant VM as my micro cloud.\u00a0 In other words, pretty much what that doc for adding services to a BOSH-based deployment prescribes.\u00a0 I&#8217;ve been digging around github, found repositories for <a href=\"https:\/\/github.com\/cloudfoundry\/micro\">micro<\/a>, <a href=\"https:\/\/github.com\/cloudfoundry\/vcap-services-base\">services-base<\/a> and <a href=\"https:\/\/github.com\/cloudfoundry\/vcap-services\">services <\/a>but haven&#8217;t been able to find anything like mcf-release (a version of <a href=\"https:\/\/github.com\/cloudfoundry\/cf-release\">cf-release<\/a> specifically for micro).<\/p>\n<p>What I am trying to do here is an important part of the whole PaaS development paradigm &#8211; anyone else interested?<\/p>\n<p>I&#8217;ve posted a short question <a href=\"http:\/\/stackoverflow.com\/questions\/13618900\/customizing-micro-cloud-foundry\">here<\/a> &#8211; keep an eye there for any responses.\u00a0 I&#8217;ll keep posting on the subject as well.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I love micro cloud foundry.\u00a0 I spend a fair bit of time on airplanes, and I hate not being able to work because my internet connection is flaky in some hotel room so being self sufficient when I am doing dev is critical. So good thinking, and thanks Cloud Foundry team. Micro cloud foundry is [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"nf_dc_page":"","_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[13,21],"tags":[53],"class_list":["post-327","post","type-post","status-publish","format-standard","hentry","category-howto","category-paas","tag-cloudfoundry"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/corneliadavis.com\/blog\/wp-json\/wp\/v2\/posts\/327","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/corneliadavis.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/corneliadavis.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/corneliadavis.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/corneliadavis.com\/blog\/wp-json\/wp\/v2\/comments?post=327"}],"version-history":[{"count":0,"href":"https:\/\/corneliadavis.com\/blog\/wp-json\/wp\/v2\/posts\/327\/revisions"}],"wp:attachment":[{"href":"https:\/\/corneliadavis.com\/blog\/wp-json\/wp\/v2\/media?parent=327"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/corneliadavis.com\/blog\/wp-json\/wp\/v2\/categories?post=327"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/corneliadavis.com\/blog\/wp-json\/wp\/v2\/tags?post=327"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}