Git Product home page Git Product logo

pulumi.fsharp.extensions's Issues

Cannot create EKS cluster

Hello, I'm trying to create EKS cluster but it seems that there is not possible to set vpcConfig with the computation expression. The vpcConfig is mentioned in the comments of the ClustedBuilder but the function is missing and after running pulumi up I get an error:

 System.ArgumentNullException: [Input] Pulumi.Aws.Eks.ClusterArgs.VpcConfig is required but was not given a value (Parameter 'VpcConfig')

my code is:

    let rolePolicy = """{
        "Version": "2012-10-17",
        "Statement": [
            {
                "Action": "sts:AssumeRole",
                "Principal": {
                    "Service": "eks.amazonaws.com"
                },
                "Effect": "Allow",
                "Sid": ""
            }
        ]
    }"""

    let eksClusterRole = role {
        name "eksClusterRole"
        assumeRolePolicy rolePolicy
    }


    let myCluster = cluster {
        name "my-cluster"
        roleArn eksClusterRole.Arn
        //vpcConfig myVpc
    }

nuget packages used:

<ItemGroup>
        <PackageReference Include="Pulumi.FSharp" Version="2.*"/>
        <PackageReference Include="Pulumi.Aws" Version="3.*"/>
        <PackageReference Include="Pulumi.FSharp.Aws" Version="2.13.1.22"/>
        <PackageReference Include="Pulumi.FSharp.Core" Version="2.0.2"/>
</ItemGroup>

also as a side note, there seems to be some error with required nuget versions Pulumi.FSharp.Aws wants to use Pulumi.FSharp.Core of version 2.13.1.22 but this version doesn't exist.

Pulumi.FSharp.Kubernetes type mismatch

image

i receive that error on type mismatch, code was taken from readme as an example but had to adjust a bit on metadata, the other part i coudlnt' figure out

// create k8s deployment
module K8s =

    open Pulumi.FSharp.Kubernetes
    open Pulumi.FSharp.Kubernetes.Apps.V1
    open Pulumi.FSharp.Kubernetes.Apps.V1.Inputs
    open Pulumi.FSharp.Kubernetes.Meta.V1.Inputs
    open Pulumi.FSharp.Kubernetes.Core.V1.Inputs

    let test_k8s_dep () project_name = 
        deployment {
            objectMeta {
                name "application"
            }

            deploymentSpec {
                replicas 1

                labelSelector { 
                    matchLabels [ ("app", input "nginx") ]
                }

                podTemplateSpec {
                    objectMeta {
                        labels ([ "app", input "nginx" ])
                    }

                    podSpec {
                        containers [
                            container {
                                name  "nginx"
                                image "nginx"
                                ports [ containerPort { containerPortValue 80 } ]
                            }
                        ]
                    }
                }
            }
        }

Great job..

Once again, amazing job on this library!

Myriad is a steep learning curve, I know; but the fact that you are generating the CEs makes this library incredibly reliable and resilient. Also, the embedded computation expressions make it so clean and a joy to use.

I only had to fallback to the base Pulumi API once, and that was because I had a pre-existing resource group that I needed to import via pulumi import, so I needed to create it with the Protect = true option:

    let rgName = $"my-resourcegroup"
    let rg = 
        Pulumi.AzureNative.Resources.ResourceGroup(
            rgName, 
            Pulumi.AzureNative.Resources.ResourceGroupArgs(
                Location = pIn "northcentralus",
                ResourceGroupName = pIn rgName
            ), Pulumi.CustomResourceOptions(Protect = true))

But I was able to do everything else via your CEs. ๐ŸŽ‰๐ŸŽ‰

How to use CustomResourceOptions?

Hi,

I've been looking through the code and am really struggling to understand how to use CustomResourceOptions (e.g. to mark a resource as protected when importing).
Any pointers on how this can be done?

Happy to submit a PR with docs if you can point me in the right direction.

intellisense on types

maybe type intellisense could get an improvement somehow, the description of types and usage are quite complex and also seems wrong, so it's not easy to pass arguments to functions in the CE...

image

or another example...

image

e.g. container image is a standard string type

i think in many cases the type suggetion of intellisense are totally wrong / misleading, and could be much simplified

Some builders don't support all setter properties

VpcPeeringConnectionArgs has a R/W property Accepter: Input<Inputs.VpcPeeringConnectionAccepterArgs>
but vpcPeeringConnection { accepter ... } doesn't work (i.e. VpcPeeringConnectionBuilder lacks Accepter())

PeeringConnectionOptionsBuilder seems to have the same problem.

Might they be unique in that they take a single option object rather than InputList, InputMap?

Screenshot 2023-03-22 at 1 34 28 AM

Resource name overload

My issue is that Pulumi is appending generated characters to my resource names.
pulumi/pulumi#7368

Is it possible to specify resource names in such a way that generated characters are not appended?
According the the Pulumi docs, you must do this:

var role = new Aws.Iam.Role("my-role", new Aws.Iam.RoleArgs
{
    Name = "my-role-001",
});

It seems that name in the F# builder only takes a string. Would it be possible to overload it to take a resource name that will not be changed?

The future of this project

Hi there,

First of all I would like to thank you so much for this amazing project. We have been using the libraries quite heavily in our projects. I'd say that we strongly depend on them nowadays.

Unfortunately, looking at the commits history and the open issues it is obvious the you don't have much time for maintenance.
I was wondering what is the future of this project? Are you planning to put effort into it or you are going to abandon it completely?

If my team offers support on maintenance, how should we better do that? Would you have time to review our PRs?

Or maybe you can add me/us as collaborators so we can continue keeping the project up to date? In this case I would highly appreciate if you find time for an introduction call, just to go over the project structure and code style conventions. We don't want to spoil all the hard work you've done. We don't want to fork the project and create duplicates in the Nuget repository, we'd rather contribute to the original version.

Please let me know your thoughts. I'd be happy to discuss any details.

CI running for a long time

Hi,

I was wondering if you knew why sometimes the CI would just not complete running for certain packages? E.g. https://github.com/UnoSD/Pulumi.FSharp.Extensions/runs/5834434536 has been running for a while now, which I figured was normal until I looked further up the CI history and saw that some jobs had been queued for 60+ days. My previous MR's main purpose was to get the latest version of Pulumi.FSharp.Gcp, and I'm wondering if there's something missing to make that happen? Please LMK if I can help.

Edit: Example of 60+ queued job: https://github.com/UnoSD/Pulumi.FSharp.Extensions/runs/4941344244

namespaces issues

i think namespace usage of open is too complex and hard to troubleshoot, e.g. when using the simplest

Pulumi.FSharp.Kubernetes to just deploy an nginx pod in minikube, it's not really clear which namespaces are needed and what to use in open statements from the docs...

image

Support default values for resources

lt would be awesome if we could support something like:

let defaultK8sDeployment = deployment {
    ...
}

let k8sDeploy = deployment {
    withDefault defaultK8sDeployment
}

The k8s is just an example, we should be able to do that for everything. That will make it super easy to create small helpers that are reusable.

Pulumi.Fsharp.Gcp

image

was testing the result from fsx script but not sure it exactly working as expected, generated docs have many generic types 'a ...

doesnt seem completely right

How to set AppService Identity

I am trying to set a web AppService Identity property, but the appService computation expression doesn't have an identity custom operation.

I'm trying to set it to "SystemAssigned" per this example so that I can give it access to a KeyVault resource.

Is there a way to set the identity?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.