Skip to content

Instantly share code, notes, and snippets.

@alexandreroman
Created October 26, 2018 12:28
Show Gist options
  • Save alexandreroman/1ae63509067317fc07a0263d5fbbd903 to your computer and use it in GitHub Desktop.
Save alexandreroman/1ae63509067317fc07a0263d5fbbd903 to your computer and use it in GitHub Desktop.
Install Azure Open Service Broker for PCF

Installing Azure Open Service Broker for PCF

Import the tile

Download the tile from Pivotal Network. Import the tile using your Ops Manager instance.

Create a Redis database instance

The Azure Open Service Broker stores information in a Redis database.

Check if Redis Cache is enabled for your subscription:

$ az provider show -n Microsoft.Cache -o table
Namespace        RegistrationState
---------------  -------------------
Microsoft.Cache  NotRegistered

If the service is not registered, use the CLI to enable it:

$ az provider register --namespace Microsoft.Cache
Registering is still on-going. You can monitor using 'az provider show -n Microsoft.Cache'

Wait for the service to be registered:

$ az provider show -n Microsoft.Cache -o table
Namespace        RegistrationState
---------------  -------------------
Microsoft.Cache  Registered

Create a resource group for Azure services:

$ RESOURCE_GROUP=cfdemo-services
$ LOCATION=northeurope
$ az group create --location $LOCATION --name $RESOURCE_GROUP

Create a cache instance:

$ REDIS_CACHE=osba-cache-north-europe
$ az redis create -n $REDIS_CACHE -g $RESOURCE_GROUP -l $LOCATION --sku Basic --vm-size C1

Caution: this is not a production ready installation!

Record the hostname of your Redis database:

$ az redis list -g $RESOURCE_GROUP | jq --arg REDIS_CACHE $REDIS_CACHE -r '.[] | select(.name==$REDIS_CACHE) | .hostName'
osba-cache-north-europe.redis.cache.windows.net

Record the password as well:

$ az redis list-keys -n $REDIS_CACHE -g $RESOURCE_GROUP | jq -r '.primaryKey'
t3VnaxaZ38bEam+NBDKoa7z8C4ZYMKKUSoLRxxxxxxxx

Configure the tile

Go to the tile configuration on Ops Manager. Enter these values:

  • Network Assignments: Network = Services
  • Azure Config: enter your subscription / tenant / client from your Azure installation
  • Broker Config:
  • Minimum Module Stability: select EXPERIMENTAL to get access to all Azure services
  • Storage Redis Host = recorded hostname
  • Storage Redis Password = recorded password (primaryKey)
  • Storage AES256 KEY = use a 32-character string (keep it somewhere in case it is needed in the future)
  • Async Redis Host = recorded hostname
  • Async Redis Password = recorded password

Apply changes to install the service broker.

When the installation is done, have a look at the Marketplace on Apps Manager. Azure services should appear:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment