Skip to content

Latest commit

 

History

History
52 lines (35 loc) · 1.97 KB

CONTRIBUTING.md

File metadata and controls

52 lines (35 loc) · 1.97 KB

Contributing

Build & test the Defang provider

  1. Run make provider to build the provider
  2. Run make sdks to build the sdks
  3. Run make build to build the provider and the sdks
  4. Run make install to install the provider
  5. Run make examples to generate the example programs in examples/ off of the source examples/yaml example program.
  6. Run make up to run the example program in examples/yaml.
  7. Run make down to tear down the example program.

Build the provider and install the plugin

$ make build install

This will:

  1. Create the SDK codegen binary and place it in a ./bin folder (gitignored)
  2. Create the provider binary and place it in the ./bin folder (gitignored)
  3. Generate the dotnet, Go, Node, and Python SDKs and place them in the ./sdk folder
  4. Install the provider on your machine.

A brief repository overview

  1. A provider/ folder containing the building and implementation logic
    1. cmd/pulumi-resource-defang/main.go - holds the provider's implementation.
  2. sdk - holds the generated code libraries.
  3. examples a folder of Pulumi programs to try locally and/or use in CI.

Additional Details

This repository depends on the pulumi-go-provider library. For more details on building providers, please check the Pulumi Go Provider docs.

Build Examples

Create an example program using the resources defined in your provider, and place it in the examples/ folder.

You can now repeat the steps for build, install, and test.

Configuring CI and releases

  1. Follow the instructions laid out in the deployment templates.

References

Other resources/examples for implementing providers: