---
# System prepended metadata

title: SPS Backend Devops - Current State

---

# SPS Backend Devops - Current State

## Variables

### Variables set through `*.bicep`

* Azure account info's (Required for Azure Stuff)
    * `AZURE_CLIENT_ID`
    * `AZURE_CLIENT_SECRET`
    * `AZURE_TENANT_ID`

* App insights
    * `APPINSIGHTS_INSTRUMENTATIONKEY`
        * Used in `Program.cs` to initiliase connection to the App insight.
    * `APPLICATIONINSIGHTS_CONNECTION_STRING`
        * Idk not used in the code.
        * Implicitly fetched in env, best practice ?? (JA speak)
            * idk, don't understand but it's a "Best practice".

* Zip stuff -> Not Necessary
    * `ZIP_SERVICE_FUNCTION_KEY_SECRET_NAME`
        * Not used anymore
    * `ZIP_SERVICE_URL`
        * Not used anymore

### Variables set in appsettings through the CI from a Keyvault

* `SqlConnectionString`
    * Connection to DB
* `StorageConnectionString`
    * Connection to Azure Storage
* `TokenSecretKey`
    * Authentification secret token
* `KeyVaultName`
    * Name of the keyvault in question

### Variables set in appsettings through the CI (written in clear in the CI)

* `BlobContainerName`
    * The name of the main Blob container used by sps
* `KeyVaultResourceGroupName`
    * Name of the resource group in which the keyvault is located, which is also the resource group of the backend.
* `ApplicationHostName` for `ApplicationDomainName`
    * Name of the host of the application.
* `PipelinesBranchRef`
    * Reference to the branch on witch to launch sdpm related pipelines.
        * Parametrized on the branch name from which th ci is launched.

### Variables set directly in the appsettings

*  Logging parameters
*  `DefaultRocketChatHook`
    *  Hook to push notifications on rocket chat
* Azure Devops parameters to launch pipelines.
    * Org Name and Project Name
    * Pipelines Ids to:
        * Deploy Collectors / Processors
        * Deploy Pipelines / Delete Pipeline RGs.

### Variables set directly in the code

* AuthToken
    * `Program.cs`, Token.Options.ExpiresInMinutes
    * `Program.cs`, Token.Options.ExpiresInDays

* SwaggerDoc
    * `Program.cs`, Api Version

* Default Accounts
    * Admin
    * Automation

* Zip Service
    * targetBlobDirectory
    * triggerContainerName

### Variables set directly in `*.csproj`

* Versions

### Directory Build Props

* Required by St-Aurel (JA - Speak)

# SPS Backend variables - Future State

### Environment Variables -> to set in the `*.bicep`

* ASPDOTNET_ENVIRONMENT

* Azure account info's
    * Required by azure libs to interact with Azure Services, such as Azure Keyvaults, Azure Devops.
        * `AZURE_CLIENT_ID`
        * `AZURE_CLIENT_SECRET`
        * `AZURE_TENANT_ID`

* Application Insight
    * Required to connect with app insights
    * `APPLICATIONINSIGHTS_CONNECTION_STRING`
    * Remove `Instrumentation key`
        * `sps-sdk-cs` to use CS
        * `sps-pipeline-iac` to use CS
        * `sps-backend` to use CS

* Sql Connection String

* Storage Connection String

* Token Secret Key as Param to bicep

* Application Domain Name

* KeyVaultResourceGroupName

* KeyVaultName

### App Settings

* Logging Params

* RocketChathook stays (but beware might have changes to come)

* Azure Devops Parameters

* Refacto Azure Devops Pipeline such that we have a couple { Id, Refs }

* `BlobContainerName`
    * The name of the main Blob container used by sps

* Zip Service
    * targetBlobDirectory
    * triggerContainerName

* AuthToken
    * Token.Options.ExpiresInMinutes
    * Token.Options.ExpiresInDays

### Code

* SwaggerDoc
    * Get Version through code.




