Renaming BOSH Jobs without Cloud Config

I recently had need to rename some BOSH jobs that were deployed with a BOSH v1 manifest, and no Cloud Config. Early in 2016, the bosh rename job command was replaced with the migrated_from feature of the manifest. It’s documented pretty well here so I won’t go into the details in this post.

However, if you try to add migrated_from to your v1 manifest, you’ll get the following error message:

Error 190014: Deployment manifest instance groups contain 'migrated_from', but it can only be used with cloud-config.

The far preferred solution would be to convert your deployments to make use of Cloud Config, but if that isn’t an option immediately and you’re pressed for time, you can do the following:

  1. Update your jobs: top level key, to be instance_groups:.
  2. For each of the instance_groups, convert its templates key to jobs.
  3. If you are using Spruce or Spiff to generate a manifest from templates, you
    will need to adjust references as needed for jobs.my_job.stuff to
    instance_groups.my_job.stuff. Also there may be a few files that need
    changing, so don’t forget to check them all!
  4. Beware of global search/replace. Some things may contain the word templates or
    jobs as part of their properties (e.g. UAA scopes). You don’t want to change those.

Spread the word

twitter icon facebook icon linkedin icon