Skip to content

Build and generate sdks

cguran-ionos edited this page Dec 6, 2024 · 4 revisions

Prerequisites

Ensure the following tools are installed and present in your $PATH:

Note: you don't need .net if you don't plan on generating it.

Commands to build and generate sdks

  • cd provider && go mod tidy && cd -

  • make tfgen

  • make build_sdks

To run locally

Go

Inside pulumi-ionoscloud directory

  • cd provider/
  • go mod tidy
  • go mod vendor
  • cd ..
  • make provider
  • use the binary (pulumi-resource-ionoscloud) created in the bin folder

Inside pulumi test directory

  • pulumi login --local
  • pulumi new go
  • add the module in go.mod as github.com/ionos-cloud/pulumi-ionoscloud/sdk and use replace to use the local version
  • go mod tidy
  • go mod vendor
  • pulumi stack
  • pulumi plugin install resource ionoscloud v0.1.0 -f bin/pulumi-resource-ionoscloud
  • pulumi up

After changes, you might need to re-install the plugin to get the new changes:

  • pulumi plugin ls
  • pulumi plugin rm resource ionoscloud
Clone this wiki locally