https://pulumi.com logo
Join the conversationJoin Slack
Channels
announcements
automation-api
aws
azure
blog-posts
built-with-pulumi
cloudengineering
cloudengineering-support
content-share
contribex
contribute
docs
dotnet
finops
general
getting-started
gitlab
golang
google-cloud
hackathon-03-19-2020
hacktoberfest
install
java
jobs
kubernetes
learn-pulumi-events
linen
localstack
multi-language-hackathon
office-hours
oracle-cloud-infrastructure
plugin-framework
pulumi-cdk
pulumi-crosscode
pulumi-deployments
pulumi-kubernetes-operator
pulumi-service
pulumiverse
python
registry
status
testingtesting123
testingtesting321
typescript
welcome
workshops
yaml
Powered by Linen
azure
  • a

    adventurous-garage-59192

    01/10/2020, 10:55 AM
    I'm guessing your pulumi definition isn't in the root of the checked out code? If so, use the
    Working Directory
    setting to point it to the correct spot.
    r
    • 2
    • 3
  • p

    powerful-football-81694

    01/10/2020, 12:52 PM
    Hi folks! We need to create an Azure SQL Database of type “Serverless” with Pulumi, but I can’t figure out how to do it. More info on that here: https://docs.microsoft.com/en-us/azure/sql-database/sql-database-serverless In ARM terms, a serverless SQL database looks like this:
    {
      "type": "Microsoft.Sql/servers/databases",
      "apiVersion": "2019-06-01-preview",
      "name": "ideliverable-licensing/Licensing",
      "location": "northeurope",
      "sku": {
        "name": "GP_S_Gen5",
        "tier": "GeneralPurpose",
        "family": "Gen5",
        "capacity": 1
      },
      "kind": "v12.0,user,vcore,serverless",
      "properties": {
        "collation": "SQL_Latin1_General_CP1_CI_AS",
        "maxSizeBytes": 17179869184,
        "catalogCollation": "SQL_Latin1_General_CP1_CI_AS",
        "zoneRedundant": false,
        "readScale": "Disabled",
        "readReplicaCount": 0,
        "autoPauseDelay": 60,
        "storageAccountType": "GRS",
        "minCapacity": 0.5
      }
    }
    But a lot of these options are missing from the corresponding
    Pulumi.Azure
    classes. How do we specify the “Gen5" SKU, the “serverless” kind, the minimum/maximum number of vcores, and the auto-pause delay?
    Pulumi.Azure.Sql.DatabaseArgs
    don’t include any of these as far as I can tell. Thankful for any and all guidance!
    a
    • 2
    • 10
  • r

    rhythmic-vegetable-87369

    01/11/2020, 4:23 PM
    Hi all, I get the following error when I try to use the Pulumi Task in the pipeline
  • r

    rhythmic-vegetable-87369

    01/11/2020, 4:23 PM
    I get the following error now, any help would be appreciated [7:10 AM] ##[error]Error: There was an error when attempting to execute the process 'd:\a\_temp\425ce36a-f50c-48af-99c5-5559867ad702\pulumi\bin\pulumi.exe'. This may indicate the process failed to start. Error: spawn d:\a\_temp\425ce36a-f50c-48af-99c5-5559867ad702\pulumi\bin\pulumi.exe ENOENT
  • r

    rhythmic-vegetable-87369

    01/11/2020, 4:23 PM
    Any ideas as to how I might solve this?
    c
    c
    • 3
    • 12
  • p

    powerful-football-81694

    01/12/2020, 8:54 PM
    Gettings this stubborn error during
    pulumi up
    from my Azure Pipeline:
    Diagnostics:
      azure:core:ResourceGroup (licensing-dev-rg):
        error: Error building account: Error getting authenticated object ID: Error listing Service Principals: autorest.DetailedError{Original:adal.tokenRefreshError{message:"adal: Refresh request failed. Status Code = '401'. Response body: {\"error\":\"invalid_client\",\"error_description\":\"AADSTS7000215: Invalid client secret is provided.\\r\\nTrace ID: d537fece-7902-4d0b-8696-debcc5b85900\\r\\nCorrelation ID: 62a70c31-1c5d-4de2-9503-b6c6ba7f555c\\r\\nTimestamp: 2020-01-12 20:48:44Z\",\"error_codes\":[7000215],\"timestamp\":\"2020-01-12 20:48:44Z\",\"trace_id\":\"d537fece-7902-4d0b-8696-debcc5b85900\",\"correlation_id\":\"62a70c31-1c5d-4de2-9503-b6c6ba7f555c\",\"error_uri\":\"<https://login.microsoftonline.com/error?code=7000215>\"}", resp:(*http.Response)(0xc00014c120)}, PackageType:"azure.BearerAuthorizer", Method:"WithAuthorization", StatusCode:401, Message:"Failed to refresh the Token for request to <https://graph.windows.net/***/servicePrincipals?%24filter=appId+eq+%27***%27&api-version=1.6>", ServiceError:[]uint8(nil), Response:(*http.Response)(0xc00014c120)}
    Using the Pulumi Task Extension for Azure Pipeline. My task YAML looks like this:
    - task: Pulumi@1
        displayName: Create/update Azure resources
        inputs:
          azureSubscription: 'IDeliverable Azure Subscription'
          command: 'up'
          args: '--skip-preview --yes'
          cwd: 'infra/'
          stack: 'dev'
        env:
          PULUMI_ACCESS_TOKEN: $(PulumiAccessToken)
      - script: |
          echo "##vso[task.setvariable variable=appName;isOutput=true]$(pulumi stack output appName)"
        displayName: Set stack outputs as variables
        name: stackVariables
    The service connection
    IDeliverable Azure Subscription
    exists and validates fine. The same service connection is also used successfully from other non-Pulumi tasks. I triple-checked the client secrets, even generated new ones and updated and verified, but still Pulumi fails with this. Any ideas?
    t
    c
    • 3
    • 16
  • s

    sticky-lighter-73941

    01/14/2020, 4:26 PM
    Guys , I have a K8s cluster configured via Pulumi running on Aks. Now I have to change some settings in the cluster like roleBasedAccessControl . The problem is when I do Pulumi preview , it’s telling me that is gonna replace my complete cluster and recreate . This is something that I don’t want because there are some applications running there . Is there a way to avoid this or what are the options in this case ? Any ideas ?
    b
    • 2
    • 3
  • r

    rhythmic-vegetable-87369

    01/15/2020, 6:17 AM
    Hi,
  • r

    rhythmic-vegetable-87369

    01/15/2020, 6:17 AM
    I'm trying to create a azure function and assign it a service identity, then give it a blobcontributer role on my storage.
  • r

    rhythmic-vegetable-87369

    01/15/2020, 6:17 AM
    I can acheive the expected results when I run the up command locally
  • r

    rhythmic-vegetable-87369

    01/15/2020, 6:17 AM
    but in the pipeline it fails
  • r

    rhythmic-vegetable-87369

    01/15/2020, 6:17 AM
    Looks like I don't have some permission
  • r

    rhythmic-vegetable-87369

    01/15/2020, 6:17 AM
    could anyone please shed some light on this? How does it work for me through my console if I dont have permissions?
  • r

    rhythmic-vegetable-87369

    01/15/2020, 6:18 AM
    Untitled
    b
    p
    c
    • 4
    • 5
  • b

    better-rainbow-14549

    01/16/2020, 4:42 PM
    i changed the pulumi name of an NS record which led to the expected preview of create / delete - but it did the create first which succeeded despite there being a clash, then it deleted "the old one" which left the DNS without the NS record at all - yet the stack had still had the resource in it so a second 'pulumi up' didnt fix it. a 'pulumi refresh' noticed it was missing and then i could recreate it. is it worth filing an issue for? is it likely to be fixable?
  • n

    nice-guitar-97142

    01/16/2020, 7:44 PM
    how do i import an existing key in Azure Key Vault? i have attempted each of these with an error that it is an invalid URI
    subscriptions/{subscriptionId}/resourceGroups/{rgName}/providers/Microsoft.KeyVault/vaults/{kvName}/keys
    subscriptions/{subscriptionId}/resourceGroups/{rgName}/providers/Microsoft.KeyVault/vaults/{kvName}/keys/{keyName}
    subscriptions/{subscriptionId}/resourceGroups/{rgName}/providers/Microsoft.KeyVault/vaults/{kvName}/keys/{keyName}/{keyVersion}
  • j

    jolly-wire-61915

    01/16/2020, 11:33 PM
    Does
    azure.cosmosdb.SqlContainer
    support the new autopilot throughput feature?
    t
    • 2
    • 1
  • r

    rhythmic-vegetable-87369

    01/17/2020, 2:35 PM
    Hi All
  • r

    rhythmic-vegetable-87369

    01/17/2020, 2:47 PM
    I would like to use the name or id of the pull request as a suffix while naming my resources during deployment. What would be the best way to achieve this?
    p
    t
    • 3
    • 5
  • a

    ambitious-ram-5811

    01/17/2020, 5:47 PM
    Many CI services dump a bunch of information into environment variables, check with whatever CI platform you're using but that's usually where you find it
    👍 2
  • p

    powerful-football-81694

    01/18/2020, 2:43 PM
    The TF provider 1.39.0 supports specifying the minimum TLS version for an Azure Functions App: https://github.com/terraform-providers/terraform-provider-azurerm/pull/5074 However it’s not available in the
    Pulumi.Azure.AppService.Inputs.FunctionAppSiteConfigArgs
    class. Is Pulumi using an older version of the TF provider? How can I find out which provider version is being used?
    b
    • 2
    • 8
  • a

    adamant-postman-86832

    01/19/2020, 6:53 AM
    anyone tried to enable azure devspaces on an aks cluster using pulumi? The kubeconfigraw in base64 is giving me a headache...
  • n

    nutritious-judge-27316

    01/19/2020, 3:54 PM
    Anyone got any notes on Azure DevOps working with Azure storage account state backend. Added Env Variables, but still just getting a error like this
    b
    c
    c
    • 4
    • 12
  • n

    nutritious-judge-27316

    01/19/2020, 3:56 PM
    b
  • p

    plain-eye-9759

    01/20/2020, 3:17 PM
    Pulumi does not seem to locate a resource group outside of the current stack's subscription. While trying to set up access policies for an existing KeyVault with Pulumi, I get an error that says
    resource group not found
    . despite that the keyVault id contains the full resource id (with the subscription)
    t
    • 2
    • 4
  • g

    great-analyst-59265

    01/20/2020, 10:13 PM
    I am trying to setup an Azure CosmosDB GremlinGraph as documented here: https://www.pulumi.com/docs/reference/pkg/nodejs/pulumi/azure/cosmosdb/#GremlinGraph However the TS property "GremlinGraph" does not exist. I am using Pulumi v1.8.1 My package.json:
    {
        "name": "azure-typescript",
        "devDependencies": {
            "@types/node": "^8.0.0"
        },
        "dependencies": {
            "@pulumi/pulumi": "^1.0.0",
            "@pulumi/azure": "^1.0.0",
            "@pulumi/kubernetes": "^1.0.0",
            "@pulumi/azuread": "^1.0.0"
        }
    }
    b
    • 2
    • 6
  • a

    ambitious-crayon-56788

    01/23/2020, 2:48 PM
    Hey. I'm trying to output the host key for an Azure Function App after deployment, but I can't seem to get it to work. I've been referencing the documentation, which shows that the
    getHostKeys()
    method is available for the FunctionApp resource. I'm using the ArchiveFunctionApp resource, which doesn't specifically list the method, but I'm hoping that I can still access the keys somehow? • Documentation: https://www.pulumi.com/docs/reference/pkg/nodejs/pulumi/azure/appservice/#FunctionApp-getHostKeys
    "use strict";
    const pulumi = require("@pulumi/pulumi");
    const azure = require("@pulumi/azure");
    
    // Create Storage Account (and container) and App Service Plan.
    /// Removed to shorted example.
    
    // Create a Function App and deploy code to it.
    const functionApp = new azure.appservice.ArchiveFunctionApp("archiveFunctionApp", {
    	name: "my-function-app",
    	resourceGroupName: resourceGroup.name,
    	archive: new pulumi.asset.FileArchive("MyFunctionApp"),
    	plan: appServicePlan,
    	account: storageAccount,
    	container: storageContainer,
    	version: "~2",
    	appSettings: {
    		FUNCTIONS_WORKER_RUNTIME: "powershell"
    	}
    });
    
    exports.FunctionAppHostKeys = functionApp.getHostKeys();
    t
    • 2
    • 2
  • a

    ambitious-crayon-56788

    01/28/2020, 1:57 PM
    Hey. I'm attempting to control the name of the blob that is used with
    azure.appservice.ArchiveFunctionApp
    , but when I add the
    zipBlob
    property and remove the
    archive
    property, I'm met with an error -
    Error: Deployment [archive] must be provided.
    The docs describe
    zipBlob
    as "The blob containing all the code for this FunctionApp". If I leave the
    archive
    property in place, two blobs are uploaded to Storage - one is my
    zipBlob
    and the other is the randomly named blob created by the
    ArchiveFunctionApp
    . I'm guessing that there is a way to do this, but the docs seem pretty light on details (in fact they don't seem to mention
    archive
    at all), so I'm not too sure where to go from here? • Documentation: https://www.pulumi.com/docs/reference/pkg/nodejs/pulumi/azure/appservice/#ArchiveFunctionApp
    const functionApp = new azure.appservice.ArchiveFunctionApp("archiveFunctionApp", {
    	name: "my-function-app",
    	resourceGroupName: resourceGroup.name,
    	archive: new pulumi.asset.FileArchive("./MyArchive"),
    	plan: appServicePlan,
    	account: storageAccount,
    	container: storageContainer,
    	zipBlob: zipBlob,
    	version: "~2",
    	appSettings: {
    		FUNCTIONS_WORKER_RUNTIME: "powershell"
    	}
    });
    t
    • 2
    • 11
  • n

    nice-guitar-97142

    01/28/2020, 4:42 PM
    i upgraded to
    @pulumi/pulumi
    to 1.9.1 and
    @pulumi/azure
    to 1.11.0 and now get a lot of debug messages around registering resources and data sources for azure in the
    Diagnostics
    section of stdout every time i run
    up
    or
    pre
    . i am not running these commands with a
    --debug
    arg. is this expected behavior, or is it possible i have something mis-configured? (see image in thread)
    ✔️ 1
    w
    b
    • 3
    • 14
  • b

    best-jordan-23853

    01/28/2020, 9:49 PM
    Hi, I’m a newbie for Pulumi. I’d like to create a Azure Policy and following the sample at https://www.pulumi.com/docs/reference/pkg/nodejs/pulumi/azure/policy/#Assignment I didn’t find any sample setting the Subscription even Resource Group. I’ve tried core.GetSubscriptionResult and core.GetClientConfigResult to get the SubscriptionId but those values are always None. I’m using Python.
    t
    • 2
    • 4
Powered by Linen
Title
b

best-jordan-23853

01/28/2020, 9:49 PM
Hi, I’m a newbie for Pulumi. I’d like to create a Azure Policy and following the sample at https://www.pulumi.com/docs/reference/pkg/nodejs/pulumi/azure/policy/#Assignment I didn’t find any sample setting the Subscription even Resource Group. I’ve tried core.GetSubscriptionResult and core.GetClientConfigResult to get the SubscriptionId but those values are always None. I’m using Python.
t

tall-librarian-49374

01/29/2020, 7:35 AM
Hi, the example there shows how to assign to a resource group — setting
scope
to
exampleResourceGroup.id
.
You can get the subscription ID from
azure.core.getClientConfig().subscriptionId
That’s TypeScript, but should be almost the same in Python
b

best-jordan-23853

01/29/2020, 3:14 PM
Hi @tall-librarian-49374! Thanks a lot! It’s work 🙂
🎉 1
View count: 3