Skip to content

Commit

Permalink
Merge pull request #1114 from JohnDuprey/dev
Browse files Browse the repository at this point in the history
Bugfixes
  • Loading branch information
JohnDuprey authored Sep 7, 2024
2 parents 5f35efe + 577e7b4 commit 9d489ed
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 7 deletions.
5 changes: 3 additions & 2 deletions CIPPTimers.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,10 @@
{
"Command": "Start-CIPPGraphSubscriptionRenewalTimer",
"Description": "Orchestrator to renew Graph subscriptions",
"Cron": "0 10 * * * *",
"Cron": "0 15 * * * *",
"Priority": 8,
"RunOnProcessor": true
"RunOnProcessor": true,
"IsSystem": true
},
{
"Command": "Start-DomainOrchestrator",
Expand Down
3 changes: 2 additions & 1 deletion Modules/CippExtensions/Public/Gradient/Get-GradientToken.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ function Get-GradientToken {
)
if ($Configuration.vendorKey) {
$null = Connect-AzAccount -Identity
$partnerApiKey = (Get-AzKeyVaultSecret -VaultName $ENV:WEBSITE_DEPLOYMENT_ID -Name 'Gradient' -AsPlainText)
$keyvaultname = $ENV:WEBSITE_DEPLOYMENT_ID -replace '-proc$', ''
$partnerApiKey = (Get-AzKeyVaultSecret -VaultName $keyvaultname -Name 'Gradient' -AsPlainText)
$authorizationToken = [Convert]::ToBase64String([Text.Encoding]::UTF8.GetBytes("$($configuration.vendorKey):$($partnerApiKey)"))

$headers = [hashtable]@{
Expand Down
5 changes: 3 additions & 2 deletions Modules/CippExtensions/Public/Hudu/Connect-HuduAPI.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@ function Connect-HuduAPI {
$DevSecretsTable = Get-CIPPTable -tablename 'DevSecrets'
$APIKey = (Get-CIPPAzDataTableEntity @DevSecretsTable -Filter "PartitionKey eq 'Hudu' and RowKey eq 'Hudu'").APIKey
} else {
$keyvaultname = $ENV:WEBSITE_DEPLOYMENT_ID -replace '-proc$', ''
$null = Connect-AzAccount -Identity
$APIKey = (Get-AzKeyVaultSecret -VaultName $ENV:WEBSITE_DEPLOYMENT_ID -Name 'Hudu' -AsPlainText)
$APIKey = (Get-AzKeyVaultSecret -VaultName $keyvaultname -Name 'Hudu' -AsPlainText)
}
New-HuduBaseURL -BaseURL $Configuration.BaseURL
New-HuduAPIKey -ApiKey $APIKey
}
}
5 changes: 3 additions & 2 deletions Modules/CippExtensions/Public/NinjaOne/Get-NinjaOneToken.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ function Get-NinjaOneToken {
$ClientSecret = (Get-CIPPAzDataTableEntity @DevSecretsTable -Filter "PartitionKey eq 'NinjaOne' and RowKey eq 'NinjaOne'").APIKey
} else {
$null = Connect-AzAccount -Identity
$ClientSecret = (Get-AzKeyVaultSecret -VaultName $ENV:WEBSITE_DEPLOYMENT_ID -Name 'NinjaOne' -AsPlainText)
$keyvaultname = $ENV:WEBSITE_DEPLOYMENT_ID -replace '-proc$', ''
$ClientSecret = (Get-AzKeyVaultSecret -VaultName $keyvaultname -Name 'NinjaOne' -AsPlainText)
}
} else {
$ClientSecret = $ENV:NinjaClientSecret
Expand All @@ -37,4 +38,4 @@ function Get-NinjaOneToken {
}
return $token

}
}

0 comments on commit 9d489ed

Please sign in to comment.