Skip to content

Instantly share code, notes, and snippets.

@weberstephanhd
Created April 22, 2015 07:34
Show Gist options
  • Select an option

  • Save weberstephanhd/1d49e20532738d6141f4 to your computer and use it in GitHub Desktop.

Select an option

Save weberstephanhd/1d49e20532738d6141f4 to your computer and use it in GitHub Desktop.
cf-boshworkspace
<%
require_relative "./lib/helper"
# the cloudfoundry release version e.g. 195
cf_release_version = ENV["JB_CF_RELEASE_VERSION"] || "207"
# the stemcell version NOTE: latest does not work
warden_stemcell_version = ENV["JB_WARDEN_STEMCELL_VERSION"] || "389"
# the director uuid of your bosh system
director_uuid = ENV["JB_DIRECTOR_UUID"] || "current"
# templates/cf is a link to .releases/cf/templates
%>
---
name: cf-warden
director_uuid: <%= director_uuid %>
releases:
- name: cf
version: <%= cf_release_version %>
git: https://github.com/cloudfoundry/cf-release.git
stemcells:
- name: bosh-warden-boshlite-ubuntu-trusty-go_agent
version: <%= warden_stemcell_version %>
templates:
- cf/cf-deployment.yml
- cf/cf-jobs.yml
- cf/cf-properties.yml
- cf/cf-lamb.yml
- cf/cf-infrastructure-warden.yml
- cf/cf-minimal-dev.yml
<% stubs("cf-warden").each do |stub| %>
- <%= stub %>
<% end %>
meta:
default_quota_definitions:
default:
memory_limit: 102400 # Increased limit for demonstration purposes
ROOT = File.join(File.dirname(__FILE__), "..")
TEMPLATES_DIR = File.join(ROOT, "templates")
def stubs(deployment)
last = Dir.pwd
Dir.chdir TEMPLATES_DIR
templates = Dir.glob(File.join("templates.d", deployment, "*.yml"))
Dir.chdir last
return templates.sort
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment