Skip to content

Conversation

@dirien
Copy link

@dirien dirien commented Oct 1, 2025

This PR creates a Neo Task resource in the provider.

The idea is to have prompts also as IaC resource and be able to provide them as Component and Golden Path to users of a platform. Think about IDP.

Happy for any input.

package main

import (
	"github.com/pulumi/pulumi-pulumiservice/sdk/go/pulumiservice"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {

		config := config.New(ctx, "")
		organizationName := config.Require("organizationName")
		if organizationName == "" {
			organizationName = ctx.Organization()
		}

		task, err := pulumiservice.NewNeoTask(ctx, "exampleTask", &pulumiservice.NeoTaskArgs{
			Content:          pulumi.String("Hello Neo!"),
			OrganizationName: pulumi.String(organizationName),
		})
		if err != nil {
			return err
		}
		ctx.Export("taskId", task.ID())

		return nil
	})
}

And looks like this, when Pulumi is up and running.
image

@github-actions
Copy link

github-actions bot commented Oct 1, 2025

Does the PR have any schema changes?

Looking good! No breaking changes found.

New functions:

  • index.createTask

Maintainer note: consult the runbook for dealing with any breaking changes.

@rshade rshade force-pushed the dirien/neo-task-resource branch 2 times, most recently from 2c50620 to 328f707 Compare October 8, 2025 13:35
@rshade rshade requested a review from a team October 8, 2025 13:59
@dirien
Copy link
Author

dirien commented Oct 15, 2025

name: yaml-tasks
runtime: yaml
description: A minimal example of creating a Neo task via Pulumi YAML

config:
  organizationName:
    type: string

resources:
  neo-task:
    type: pulumiservice:index:NeoTask
    properties:
      organizationName: ${organizationName}
      content: "Hello Neo!"

outputs:
  taskId: ${neo-task.id}

@dirien dirien requested a review from rshade October 15, 2025 15:37
@rshade rshade force-pushed the dirien/neo-task-resource branch from d3ed198 to 8729325 Compare October 15, 2025 16:04
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need these binary files?

@nyobe
Copy link
Contributor

nyobe commented Oct 15, 2025

I think this should be modeled as an Invoke rather than a Resource, because the other half of the lifecycle (update/delete) does not apply here

@fnune fnune requested review from nyobe and removed request for a team October 20, 2025 10:17
@rshade rshade force-pushed the dirien/neo-task-resource branch 3 times, most recently from 0a1c889 to 852005a Compare October 28, 2025 17:09
@rshade rshade force-pushed the dirien/neo-task-resource branch from 852005a to 5733f7d Compare November 6, 2025 15:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants