This manual covers the installation of Develocity on an Azure virtual machine instance.

Time to completion: 45 minutes

Develocity is a Kubernetes-based application distributed as a Helm chart that manages all Develocity components. Helm is a package manager for Kubernetes applications.

The installation of Develocity described in this manual involves installing the K3s lightweight Kubernetes distribution onto an Azure virtual machine host, then using Helm to install Develocity in the K3s instance on that host.

Prerequisites

1. An Azure Account

An Azure paid account is required. Note that a free account is not sufficient.

2. A Develocity License

If you have purchased Develocity or started a trial, you should already have a license file called develocity.license. Otherwise, you may request a Develocity trial license.

3. An Azure user

Your Azure user requires the Azure built-in role required for how you want to execute Azure CLI commands.

CLI Type

Required Role/Permission

Installed Azure CLI or Azure Portal

Contributor built-in Azure role

Azure Cloud Shell

Owner or the User Access Administrator built-in Azure role, or create a custom role with the MicrosoftAuthorization/roleAssignments/write permission and assign it to the user.

Host Requirements

This section outlines the Azure host requirements for the installation.

1. Operating System

Develocity supports Ubuntu 18.04/20.04/22.04, RHEL 8.4/8.5/8.6, and Debian 11.

Develocity is expected to work on most modern Linux systems.

2. K3s

K3s needs several ports to be accessible from the host.

Protocol Port

TCP

6443

HTTP

80

HTTPS

443

While these ports don’t need to be accessible from outside the host machine, K3s may access them using a different network interface or non-localhost IP.

3. CPU & Memory

The minimum installation requirements are:

  • Quad-core 2GHz or better (amd64 architecture)

  • 16 GB free RAM

The D4s_v3 instance size provides 4 vCPU / 16 GiB Memory.

4. Database

Develocity installations have two database options:

  1. An embedded database that is highly dependent on disk performance.

  2. A user-managed database that is compatible with PostgreSQL 12, 13, or 14, such as Azure Database for PostgreSQL.

By default, Develocity stores its data in an embedded PostgreSQL database that is run as part of the application itself, with data being stored in a directory mounted on the host machine.

See Appendix A for instructions on using Azure Database for PostgreSQL as a user-managed database. Using a cloud-based database can have a number of benefits, including easier resource scaling, backup management, and failover support.

5. Storage

In addition to the database, Develocity needs some storage capacity for configuration files, logs, and build cache artifacts. These storage requirements apply regardless of which type of database you use, although the necessary size varies based on the database type. For the embedded database, the majority of data is stored in the "installation directory", which defaults to /opt/gradle, unless otherwise specified in your Helm configuration file.

Capacity

The minimum capacity required for the installation directory for the embedded database case is 250 GB. The minimum capacity required for the installation directory for the user-managed database case is 30 GB.

It is recommended to create a specific volume for the installation directory to avoid consuming the space required for Develocity, and to ensure at least 10% of the volume’s space is free at all times.

The following are additional disk capacity requirements:

Location Storage Size

/tmp

1 GB

/var/lib/rancher/k3s

30 GB

Performance

For production workloads, storage volumes should exhibit SSD-class disk performance of at least 3000 IOPS (input/output operations per second). Most NFS-based storage or desktop-class, non-SSD disk drives do not provide this level of performance.

Object storage

Develocity can also be configured to store Build Scans in Azure Blob Storage. This can help performance in high-traffic installations by reducing the load on the database and reducing storage costs. See Appendix B for details.

6. Network Connectivity

Develocity requires network connectivity for periodic license validation.

An installation of Develocity will not start if it cannot connect to both registry.gradle.com and harbor.gradle.com.

It is strongly recommended that production installations of Develocity are configured to use HTTPS with a trusted certificate.

When installing Develocity, you will need to provide a hostname, such as ge.example.com.

Pre-Installation

1. Set up your Shell

If you decide to use Azure Cloud Shell or the Azure portal, skip to 3. Generate a Key Pair. Otherwise, follow steps A and B below:

A. Install the Azure CLI

B. Configure the Azure CLI

Follow the Get started with Azure CLI guide and Configure settings using az init or Configure settings with az configure. Choose the region in which you wish to install Develocity. Azure provides a list of all available Azure regions.

Pick the region geographically closest to you or to any pre-existing compute resources, such as CI agents, to ensure the best performance.

2. Create a Resource Group

Create an Azure resource group to contain all the resources you create for Develocity.

Create a resource group using the Azure CLI

Use the following command to create a resource group:

$ az group create --name Develocity --location eastus
Create a resource group using the Azure portal

To create a resource group in the Azure portal:

  1. Navigate to the Resource groups service and click Create.

  2. In Resource group, enter a name for the resource group.

  3. In Region, enter the Azure region where the resource group will reside.

  4. Click Review + Create.

  5. Click Create.

azure resource group creation

3. Generate a Key Pair

You need an SSH key to access Azure resources. To create the SSH key in the Azure portal, see Generate and store SSH keys in the Azure portal. To create the SSH key with the Azure CLI, see Generate and store SSH keys with the Azure CLI. Although you can save the generated keys file with any name, this manual uses the name DevelocityKeyPair. If you choose another name, you’ll need to edit the shell commands in this section.

Generate a key pair using the Azure CLI

Enter the command:

$ az sshkey create --name DevelocityKeyPair --resource-group Develocity

You should see output similar to the following:

Private key is saved to "/Users/myname/.ssh/1698431396_112492".
Public key is saved to "/Users/myname/.ssh/1698431396_112492.pub".
Generate a key pair using the Azure portal

To create an SSH key in the Azure portal:

  1. Navigate to the SSH keys service and click Create.

  2. In Resource group, enter the name of your Azure resource group.

  3. In Name, enter a name for the SSH key.

  4. Click Review + Create.

  5. Click Create.

  6. Click Download private key and create resource and save the file to your local machine.

azure key pair creation

4. Change Key Pair Permissions

SSH requires that only your user has permission to read SSH key files.

Change permission using the terminal

Use the following command to change the permissions of the private key file.

$ chmod 400 /Users/myname/.ssh/<<key_name>>
Change permission using the OS file settings

Change the PEM file permissions so the current user has Read-Only permissions and everyone else has No Access. You can do that by using the terminal and running the following command:

$ chmod 400 path/to/DevelocityKeyPair.pem

Or by using the OS file settings. Here is an example in MacOS Finder:

azure key pair permission

5. Create a Security Group

Create a security group called develocity-nsg.

Create a security group using the Azure CLI

Use the following command to create the security group:

$ az network nsg create \
  --resource-group Develocity \
  --name develocity-nsg \
  --location eastus

Develocity requires port 443 for HTTPS access and port 80 for HTTP access. To expose ports 443 and 80, execute the following Azure CLI command from the shell:

$ az network nsg rule create \
  --resource-group Develocity \
  --nsg-name develocity-nsg \
  --name Allow-Web-All \
  --access Allow \
  --protocol Tcp \
  --direction Inbound \
  --priority 1010 \
  --source-port-range "*" \
  --destination-port-range 80 443

To be able to connect to the virtual machine, you need to open port 22 for SSH access. To open port 22, execute the following Azure CLI command from the shell:

$ az network nsg rule create \
  --resource-group Develocity \
  --nsg-name develocity-nsg \
  --name Allow-SSH-All \
  --access Allow \
  --protocol Tcp \
  --direction Inbound \
  --priority 1000 \
  --source-port-range "*" \
  --destination-port-range 22
Create a security group using the Azure portal

To create a network security group:

  1. Navigate to the Network security groups service and click Create.

  2. In Resource Group, enter the name of your Azure resource group.

  3. In Name, enter a name for the network security group.

  4. In Region, enter the Azure region where the network security group will reside (defaults to the resource group’s region).

  5. Click Review + Create.

  6. Click Create.

azure nsg review and create

Develocity requires port 443 for HTTPS access and port 80 for HTTP access.

To open ports 80 and 443:

  1. Double-click the new network security group.

  2. Click Inbound security rules.

  3. Click Add.

  4. In Destination port ranges, enter '80,443'.

  5. In Protocol, select TCP.

  6. In Action, select Allow.

  7. Click Add.

azure add inbound security rule web

Installation of Develocity requires port 22 for SSH access.

To open port 22:

  1. Double-click the new network security group.

  2. Click Inbound security rules.

  3. Click Add.

  4. In Service, select SSH.

  5. In Action, select Allow.

  6. Click Add.

azure add inbound security rule ssh

Creating an Azure virtual machine

The next step is to create an Azure virtual machine with a supported configuration.

1. Choose a Machine Image

Choose a server image appropriate for your environment. We focus our support efforts on Ubuntu 18.04/20.04/22.04, RHEL 8.4/8.5/8.6, and Debian 11. Develocity is expected to work on most modern Linux systems.

View the latest virtual machine images using the Azure CLI

You can use the Azure CLI to see the latest virtual machine images available in your region. The following command returns a list of all available machine images in the eastus region in a table:

$ az vm image list -f Ubuntu --location eastus --all --output table
View the latest virtual machine images using the Azure portal

To view the latest virtual machine images available in your region:

  1. In the Azure portal, navigate to Virtual machines.

  2. Click Create and select Azure Virtual Machine.

  3. Click the Image list to see the available machine images.

azure machine images

2. Specify virtual machine details

To specify virtual machine details:

  1. Continuing in Azure portal, enter a name for the virtual machine in Name.

  2. Enter previously created resource group name in Resource Group.

  3. Select a region from Region.

  4. Select an image from Image.

  5. Select an image size from Size.
    Develocity’s minimum requirement for an Azure instance is Standard_D4s_v3 with 4 vCPUs and 16 GB of memory.

  6. Select Use existing key stored in Azure from SSH public key source and select your key from Stored Keys.
    Alternatively, select Generate new key pair from SSH public key source and enter a name for the new key in Key pair name.

See General purpose virtual machine sizes for more information.

If you are using the Azure CLI, you will specify these details from the command line in 5. Create your instance.

3. Choose the Storage

For simplicity, we expand the OS disk volume to a minimum of 300 GB rather than mounting individual volumes. This is not advisable in a production instance. We recommend adding separate data volumes so that you can control their size, performance, and cost separately from the root volume.

To specify storage options:

  1. Click Next: Disks> in the Azure Create a virtual machine wizard.

  2. Specify a minimum of 300 GiB in OS disk size.

The Build Scan® service of Develocity can be configured to store the data in a Azure Blob Storage. This can help performance in high-traffic installations by taking the load off the database. See Appendix B for details.

If you are using the Azure CLI, you will specify these details from the command line in 5. Create your instance.
Instructions for using Azure Database for PostgreSQL as a user-managed database can be found in appendix.

4. Configure the Network

We need to configure the network settings for the virtual machine to use the security group we created in 5. Create a Security Group.

To configure the network settings:

  1. Click Next: Networking> in the Azure Create a virtual machine wizard.

  2. In NIC network security group, select Advanced.

  3. In Configure network security group, select the security group you created in 5. Create a Security Group.

If you are using the Azure CLI, you will specify these details from the command line in 5. Create your instance.

5. Create your instance

Now, you are ready to create your Azure virtual machine.

Create your virtual machine using the Azure CLI

To create your instance with the Azure CLI, run the following command:

$ az vm create -n develocity \(1)
  -g Develocity \(2)
  --nsg develocity-nsg \(3)
  --image Ubuntu2204 \(4)
  --size Standard_D4s_v3 \(5)
  --data-disk-sizes-gb 300 \
  --ssh-key-name DevelocityKeyPair \(6)
  --admin-username azureuser \
  --location eastus
1 The name of the virtual machine instance.
2 The resource group you created in 2. Create a Resource Group
3 The network security group you created in 5. Create a Security Group
4 The instance image from section 1. Choose a Machine Image.
5 The instance size from sections 2. Specify virtual machine details.
6 The name of the key pair you created in 3. Generate a Key Pair.

If you are using a user-managed database, consider reducing the size of the data disk to 50 GB.

Create your virtual machine using the Azure portal

To create your virtual machine using the Azure portal:

  1. Click Review + create in the Azure Create a virtual machine wizard.

  2. Review your selections.

  3. Click Create.

6. Configure the Hostname

Azure virtual machines are provisioned with an external IP address, but no hostname. Develocity cannot use an IP address as a hostname, but there are services like nip.io that automatically map hostnames to IPs. You can start with a public DNS name based on the IP address and later reconfigure it to use a custom hostname if desired.

If you do not wish to set up a permanent DNS record at this time, you can instead use a service like nip.io to provide one based on the IP address. Any of the dash-based naming schemes on the nip.io web page should work, but the following commands generate a useful short name tied to that IP address:

$ DV_IP_ADDR=$(az vm show -d -g Develocity -n develocity --query publicIps -o tsv) && echo $DV_IP_ADDR (1)
1 Substitute the names of your resource group and virtual machine name.
$ DV_HOSTNAME="develocity-$(printf '%02x' $(echo ${DV_IP_ADDR//./ })).nip.io" && echo $DV_HOSTNAME
develocity-14732a69.nip.io

Use develocity-14732a69.nip.io as the hostname.

If you intend to use a custom hostname to access your Develocity instance, such as develocity.example.com, you must create the appropriate DNS record to route this name to the IP address of the Azure virtual machine instance. Add an A record for your hostname that points to your static IP address. For example:

develocity.example.com A 34.110.226.160

You should verify that your DNS record works correctly before installing Develocity, such as by using dig develocity.example.com.

View the IP address using the Azure CLI

You can find the generated IP address with the following Azure CLI command:

$  az vm show -d -g Develocity -n develocity --query publicIps -o tsv (1)
1 Substitute the names of your resource group and virtual machine name.
View the IP address using the Azure portal

To view the IP address in the Azure portal:

  1. In the Azure portal, go to Virtual machines.

  2. Click your virtual machine.

  3. Azure displays the IP address at Public IP address on the Networking pane of the Properties tab.

azure portal public ip address

You can run Develocity behind a cloud load balancer such as Azure Load Balancer. If you do this, you should generally use /ping to check the load balancer’s health. It will respond as healthy when Develocity is capable of handling requests, even if limited to the interactive starting page while the instance is starting.

This may be unwanted for highly available installations using the load balancer to manage fail-over. If you are installing Develocity in a highly available setup, we recommend submitting a ticket at support.gradle.com for assistance.

7. Set Up your Connection

Once your instance starts, SSH into your instance with the following command:

$ ssh -i path/to/DevelocityKeyPair azureuser@$DV_HOSTNAME (1)
1 The path to where you saved the private key that you created in section 3. Generate a Key Pair.

If you can’t find the IP address for your vm host, retrieve it with the following command:

az vm show -d -g Develocity -n develocity --query publicIps -o tsv

A successful response looks like the following:

52.170.239.155

Installing Develocity

In this section, you will install Develocity on your newly created instance.

1. Prepare a Helm values file

Use the values.yaml configuration file to configure Develocity during installation and for later configuration changes. You can find configuration details in the Helm configuration section of the Standalone Helm Chart Configuration Guide. To download an example configuration file, see Appendix A of the Standalone Helm Chart Configuration Guide. Then, create a copy named values.yaml and edit it as shown below:

values.yaml
global:
  hostname: develocity.example.com (1)
1 Use the hostname you decided on in 6. Configure the Hostname.
When adding things to your Helm values file, merge any duplicate blocks. Alternatively, you can use separate files and pass all of them with --values «file» when running Helm commands.
If you want to provide an SSL certificate instead of having Develocity generate a self-signed one, see HTTPS SSL Certificate in the Standalone Helm Chart Configuration Guide.
If you want to use Azure Database for PostgreSQL as your database instead of the embedded database, follow Using Azure Database for PostgreSQL.
If you want to use Azure Blob Storage for Build Scans, see Storing Build Scans in Azure Blob Storage.

2. Copy Files

Copy the Helm values file you created to the instance.

To copy the values.yaml file from your local machine to your instance, run the following command:

$ scp -i path/to/DevelocityKeyPair path/to/values.yaml azureuser@${DV_HOSTNAME}:~

Optionally copy the develocity.license file to your instance if you did not include it in your values.yaml file:

$ scp -i path/to/DevelocityKeyPair path/to/develocity.license azureuser@${DV_HOSTNAME}:~

If you are using a custom SSL certificate, copy the certificate and key files to the instance as well.

3. Install K3s

SSH into the instance by running the following command:

$ ssh -i path/to/DevelocityKeyPair azureuser@${DV_HOSTNAME}

K3s is a fully compliant Kubernetes distribution and must be installed on the instance.

Once you’re on the machine, install K3s and make it available to the current user:

$ curl -sfL https://get.k3s.io | sh -
$ sudo chown ${UID} /etc/rancher/k3s/k3s.yaml
$ mkdir -p "${HOME}/.kube"
$ ln -s /etc/rancher/k3s/k3s.yaml "${HOME}/.kube/config"

4. Install Helm

Then install Helm:

$ curl https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 | bash

5. Install the Helm Chart

First, add the https://helm.gradle.com/ helm repository and then update it:

$ helm repo add gradle https://helm.gradle.com/
$ helm repo update gradle

6. Install Develocity

Then run helm install with the following command:

$ helm install \
    --create-namespace --namespace develocity \
    develocity-standalone \
    gradle/gradle-enterprise-standalone \
    --values ./values.yaml \(1)
    --set-file global.license.file=./develocity.license (2)
1 The Helm values file you created in 1. Prepare a Helm values file and uploaded in 2. Copy Files.
2 The license you obtained in 2. A Develocity License and uploaded in 2. Copy Files.

The output should be similar to this:

NAME: develocity-standalone
LAST DEPLOYED: Thu Apr 18 11:22:10 2024
NAMESPACE: develocity
STATUS: deployed
REVISION: 1
TEST SUITE: None
NOTES:
Develocity has been installed.

7. Wait for Develocity to start

You can see the status of Develocity starting up by examining its pods.

$ kubectl --namespace develocity get pods
NAME                                              READY   STATUS              RESTARTS   AGE
gradle-enterprise-operator-76694c949d-md5dh       1/1     Running             0          39s
gradle-monitoring-5545d7d5d8-lpm9x                1/1     Running             0          39s
gradle-database-65d975cf8-dk7kw                   0/2     Init:0/2            0          39s
gradle-build-cache-node-57b9bdd46d-2txf5          0/1     Init:0/1            0          39s
gradle-proxy-0                                    0/1     ContainerCreating   0          39s
gradle-metrics-cfcd8f7f7-zqds9                    0/1     Running             0          39s
gradle-test-distribution-broker-6fd84c6988-x6jvw  0/1     Init:0/1            0          39s
gradle-keycloak-0                                 0/1     Pending             0          39s
gradle-enterprise-app-0                           0/1     Pending             0          39s

Eventually, the pods should all report as Running:

$ kubectl --namespace develocity get pods
NAME                                               READY   STATUS    RESTARTS   AGE
gradle-enterprise-operator-76694c949d-md5dh        1/1     Running   0          4m
gradle-monitoring-5545d7d5d8-lpm9x                 1/1     Running   0          4m
gradle-proxy-0                                     1/1     Running   0          3m
gradle-database-65d975cf8-dk7kw                    2/2     Running   0          3m
gradle-enterprise-app-0                            1/1     Running   0          3m
gradle-metrics-cfcd8f7f7-zqds9                     1/1     Running   0          3m
gradle-test-distribution-broker-6fd84c6988-x6jvw   1/1     Running   0          3m
gradle-build-cache-node-57b9bdd46d-2txf5           1/1     Running   0          4m
gradle-keycloak-0                                  1/1     Running   0          3m

Develocity has a /ping endpoint, which can be used to verify network connectivity with Develocity.

Connectivity to Develocity installation can be tested by running the following command on machines that need to connect to Develocity:

$ curl -sw \\n --fail-with-body --show-error https://«develocity-host»/ping

It should return SUCCESS.

Once all pods have a status of Running and the system is up and connected, you can interact with it by visiting its URL and hostname in a web browser.

gradle enterprise

Develocity is installed and running.

Post-Installation

Many features of Develocity, including access control, database backups, and Build Scan retention, can be configured in Develocity once it is running. Consult the Develocity Administration guide to learn more.

For instructions on how to start using Develocity in your builds, consult the Getting Started with Develocity guide.

Appendix A: Using Azure Database for PostgreSQL

This appendix will walk you through using Azure Database for PostgreSQL flexible server as your user-managed database. This appendix is expecting you to have already created an Azure virtual machine following the guide above - See 5. Create your instance.

1. Obtain the Required Permissions

You need permission to create and manage an Azure Database for PostgreSQL and a resource group. The Contributor Azure built-in role contains the necessary permissions.

2. Set up an Azure Database for PostgreSQL Instance

Before starting, review the supported Postgres versions and storage requirements.

A. Create a root username and password for your database

Create a root username and password for the database instance, referred to below as «db-root-username» and «db-root-password», respectively. You will use these credentials to configure your database connection. Save them in a secure place.

B. Create a resource group

Before creating the database, you must create an Azure resource group.

To create an Azure resource group, see 2. Create a Resource Group.

C. Create the Azure Database for PostgresSQL instance

Now, you’re ready to create your database instance. The example in this guide creates an instance in flexible server deployment mode.

Create the Azure Database for PostgreSQL instance:

$ az postgres flexible-server create \
  --location eastus \
  --name develocity-db \
  --resource-group Develocity \(1)
  --admin-user <db-root-username> \
  --admin-password <db-root-password> \(2)
  --sku-name Standard_B4ms \
  --tier Burstable \
  --public-access <dv_ip_address> \(3)
  --storage-size 256 \(4)
  -o json
1 The resource group you created earlier
2 The username and password for the administrator of the database.
3 IP address of the Develocity virtual machine created in 5. Create your instance.
4 Develocity should be installed with 250GB of database storage.

A successful response looks like the following:

{
  "connectionString": "postgresql://dbadmin:dbpassword@develocity-db.postgres.database.azure.com/flexibleserverdb?sslmode=require",
  "databaseName": "flexibleserverdb",
  "firewallName": "FirewallIPAddress_2024-4-19_12-55-12",
  "host": "develocity-db.postgres.database.azure.com", (1)
  "id": "/subscriptions/11ce99bf-de1c-42ed-bfe8-46ba938836ef/resourceGroups/Develocity/providers/Microsoft.DBforPostgreSQL/flexibleServers/develocity-db", (2)
  "location": "East US",
  "password": "dbpassword",
  "resourceGroup": "Develocity",
  "skuname": "Standard_B4ms",
  "username": "dbadmin",
  "version": "13"
}
1 The hostname for the database server. You will use this value as the database-address in a later section.
2 You can parse the subcription-id used in the later sections from the id field as /subscriptions/<subscription-id>/resourceGroup/…​.

To find the hostname and service id of the database server later, run the following command:

$ az postgres flexible-server show \
  --resource-group Develocity \
  --name develocity-db \
  -o json
  1. The fullyQualifiedDomainName field contains the hostname of the database server.

  2. The id field contains the service id of the database server and can be parsed as described above.

D. Set required server parameters

Develocity requires the following Azure database server extensions:

  • amcheck

  • intarray

  • pg_trgm

  • pgcrypto

  • pgstattuple

To install the extensions, run the following command:

$ az postgres flexible-server parameter set \
  --resource-group Develocity \
  --server-name develocity-db \
  --subscription <<subscription-id>> \
  --name azure.extensions \
  --value amcheck,intarray,pg_trgm,pgcrypto,pgstattuple \
  -o json

A successful response looks like the following:

{
  "allowedValues": ",address_standardizer,address_standardizer_data_us,amcheck,anon,azure_ai,azure_storage,bloom,btree_gin,btree_gist,citext,cube,dblink,dict_int,dict_xsyn,earthdistance,fuzzystrmatch,hstore,hypopg,intagg,intarray,isn,lo,login_hook,ltree,orafce,pageinspect,pg_buffercache,pg_cron,pg_freespacemap,pg_hint_plan,pg_partman,pg_prewarm,pg_repack,pg_squeeze,pg_stat_statements,pg_trgm,pg_visibility,pgaudit,pgcrypto,pglogical,pgrouting,pgrowlocks,pgstattuple,plpgsql,plv8,postgis,postgis_raster,postgis_sfcgal,postgis_tiger_geocoder,postgis_topology,postgres_fdw,semver,session_variable,sslinfo,tablefunc,tds_fdw,timescaledb,tsm_system_rows,tsm_system_time,unaccent,uuid-ossp,vector",
  "dataType": "Set",
  "defaultValue": "",
  "description": "Specifies which extensions are allowed to be created in the server.",
  "documentationLink": "https://docs.microsoft.com/azure/postgresql/flexible-server/concepts-extensions#postgres-13-extensions",
  "id": "/subscriptions/11ce99bf-de1c-42ed-bfe8-46ba938836ef/resourceGroups/Develocity/providers/Microsoft.DBforPostgreSQL/flexibleServers/develocity-db/configurations/azure.extensions",
  "isConfigPendingRestart": false,
  "isDynamicConfig": true,
  "isReadOnly": false,
  "name": "azure.extensions",
  "resourceGroup": "Develocity",
  "source": "user-override",
  "systemData": null,
  "type": "Microsoft.DBforPostgreSQL/flexibleServers/configurations",
  "unit": null,
  "value": "amcheck,intarray,pg_trgm,pgcrypto,pgstattuple"
}

E. Create a database on your database server

Run the following command to create a database on your database server:

$ az postgres flexible-server db create \
  --resource-group Develocity \
  --server-name develocity-db \
  --database-name develocity-db \
  -o json

A successful response looks like the following:

{
  "charset": "UTF8",
  "collation": "en_US.utf8",
  "id": "/subscriptions/11ce99bf-de1c-42ed-bfe8-46ba938836ef/resourceGroups/Develocity/providers/Microsoft.DBforPostgreSQL/flexibleServers/develocity-db/databases/develocity-db",
  "name": "develocity-db",
  "resourceGroup": "Develocity",
  "systemData": null,
  "type": "Microsoft.DBforPostgreSQL/flexibleServers/databases"
}

You can view the status of your instance with the following command:

$ az postgres flexible-server db show \
  --resource-group Develocity \
  --server-name develocity-db \
  --database-name develocity-db \
  -o json

A successful response looks like the following:

{
  "charset": "UTF8",
  "collation": "en_US.utf8",
  "id": "/subscriptions/11ce99bf-de1c-42ed-bfe8-46ba938836ef/resourceGroups/Develocity/providers/Microsoft.DBforPostgreSQL/flexibleServers/develocity-db/databases/develocity-db",
  "name": "develocity-db",
  "resourceGroup": "Develocity",
  "systemData": null,
  "type": "Microsoft.DBforPostgreSQL/flexibleServers/databases"
}

3. Configure Develocity with Azure Database for PostgreSQL

Add the following configuration snippet to your Helm values file:

values.yaml
database:
  location: user-managed
  connection:
    host: «database-address» (1)
    databaseName: «database-name» (2)
  credentials:
    superuser:
      username: «db-root-username»
      password: «db-root-password» (3)
1 The database hostname you received during step C. Create the Azure Database for PostgresSQL instance.
2 The database name you set during step E. Create a database on your database server.
3 The root username and password you set during step A. Create a root username and password for your database.
The superuser is only used to set up the database and create migrator and application users. You can avoid using the superuser by setting up the database yourself, as described in the Database options section of Kubernetes Helm Chart Configuration Guide. Please contact Gradle support for help with this.

This action embeds your database superuser credentials in your Helm values file. It must be kept secure. If you prefer to provide the credentials as a Kubernetes secret, consult the Database options section of the Kubernetes Helm Chart Configuration Guide.

4. Upgrade Develocity with your updated configuration file

If you created the Azure Database for PostgreSQL instance as part of the initial installation, you can continue with the installation process in Installing Develocity.

See Changing configuration values in the Develocity Upgrade Guide for instructions on how to upgrade your Develocity instance with updated configuration values.

Return to this procedure after the installation/upgrade is finished.

Appendix B: Storing Build Scans in Azure Blob Storage

This appendix will walk you through using an Azure Blob Storage to store Build Scans®. This appendix is expecting you to have already created an Azure virtual machine following the guide above - See 5. Create your instance.

1. Obtain the required permissions

You need permission to create and manage an Azure storage account and container. The Contributor Azure built-in role contains the necessary permissions.

2. Create an Azure storage account

To create an Azure storage account, run the following command:

$ az storage account create --name develocitystorageacc --resource-group Develocity -l eastus

See az storage account create Azure CLI documentation for more information about this command.

3. Create an Azure container

Next, create an Azure container for your storage account. You will need the connection string to your storage container. To find your connection string using the Azure CLI, run the following command:

az storage account show-connection-string --name develocitystorageacc -o json

To create an Azure container, run the following command:

$ az storage container create --name dv-build-scans \(1)
  -o json \
  --connection-string "<MyConnectionString>" (2)
1 Azure container names must be unique across your Azure account. We recommend using your account ID as a suffix.
2 The connection string you obtained earlier.

A successful response looks like the following:

{
  "created": true
}
If you want to store build scans for multiple installations of Develocity in Azure storage, either add a suffix or use the same container with a different scans object prefix.

See az storage container create in the Azure CLI documentation for more information about this command.

4. Create a shared access signature (SAS) for your Azure container

To create a shared access signature (SAS) for your Azure container, run the following command:

$ az storage account generate-sas \
    --account-name develocitystorageacc \(1)
    --services bfqt \
    --resource-types sco \
    --permissions acdfilprtuwxy \
    --expiry 2124-03-09T00:00:00Z \(2)
    -o json
1 The name of the container that you created earlier in your storage account.
2 The expiration date and time for the SAS token.

Copy the SAS token and safely store it.

5. Configure Develocity to store Build Scans in Azure

Update your values.yaml file to configure Develocity to store build scans in Azure Blob Storage.

objectStorage:
  type: "azure"
  azure:
    container: "dv-build-scans" (1)
    credentials:
      source: "sas"
      sas: "sv=2022-11-02&ss=bfqt&srt=sco&sp=rwdlacupiytfx&se=2025-03-09 ..." (2)
      endpoint: "https://develocitystorageacc.blob.core.windows.net/dv-build-scans" (3)
1 The name of the container that you created earlier in your storage account.
2 The SAS token that you created earlier.
3 The URL for the container. It is constructed as https://«storage-account-name».blob.core.windows.net/«container-name».

6. Upgrade Develocity with the new configuration

If you created the Azure Blob Storage instance as part of the initial installation, you can continue with the installation process in Installing Develocity.

If you have previously installed Develocity, you must upgrade your instance to use the new configuration in your updated `values.yaml' file. See Changing configuration values in the Develocity Upgrade Guide for instructions.

Return to this procedure after the installation/upgrade is finished.

7. Update the Develocity Admin UI

The next step is to update the Admin UI to use the new object storage configuration. Follow the procedure at Build Scan storage configuration in the Develocity Administration Manual to use the new configuration. Develocity prompts you to restart as part of the procedure.

8. Verify Azure Blob Storage is Used

Develocity will start even if your object storage configuration is incorrect. Once Develocity has started, you can verify that the Azure configuration is correct by examining the contents of your Azure container.

Alternatively, run the following Azure CLI command to view the number of build scans stored in your Azure container:

$ az storage blob list \
  --account-name develocitystorageacc \(1)
  --container-name dv-build-scans \(2)
  --connection-string "<ConnectionString>" \ (3)
  --query "length(@)"
1 The name of the storage account you created earlier in step 2. Create an Azure storage account.
2 The name of the container you created earlier in step 3. Create an Azure container.
3 The connection string you obtained earlier in step 3. Create an Azure container.

The following successful response indicates that there are currently 572372 build scans in the container:

572372