Skip to content

Commit

Permalink
Update GitHub Actions workflows. (#128)
Browse files Browse the repository at this point in the history
This PR was automatically generated by the
update-workflows-ecosystem-providers workflow in the pulumi/ci-mgmt
repo, from commit ceeb0e7bc29c241d9d6a02b75866e423dc0a473b.
  • Loading branch information
pulumi-bot authored Oct 6, 2023
1 parent 7202ddd commit 3cd4fa7
Show file tree
Hide file tree
Showing 12 changed files with 46 additions and 105 deletions.
10 changes: 10 additions & 0 deletions .ci-mgmt.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
provider: nomad
major-version: 2
setup-script: "testing/setup.sh"
env:
VAULT_ADDR: "http://127.0.0.1:4646"
makeTemplate: bridged
plugins:
- name: random
version: "4.2.0"
team: ecosystem
2 changes: 1 addition & 1 deletion .github/workflows/command-dispatch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ env:
GOVERSION: 1.21.x
JAVAVERSION: "11"
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NODEVERSION: 16.x
NODEVERSION: 20.x
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NUGET_PUBLISH_KEY: ${{ secrets.NUGET_PUBLISH_KEY }}
PUBLISH_REPO_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ env:
GOVERSION: 1.21.x
JAVAVERSION: "11"
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NODEVERSION: 16.x
NODEVERSION: 20.x
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NUGET_PUBLISH_KEY: ${{ secrets.NUGET_PUBLISH_KEY }}
PUBLISH_REPO_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ env:
GOVERSION: 1.21.x
JAVAVERSION: "11"
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NODEVERSION: 16.x
NODEVERSION: 20.x
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NUGET_PUBLISH_KEY: ${{ secrets.NUGET_PUBLISH_KEY }}
PUBLISH_REPO_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/prerelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ env:
GOVERSION: 1.21.x
JAVAVERSION: "11"
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NODEVERSION: 16.x
NODEVERSION: 20.x
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NUGET_PUBLISH_KEY: ${{ secrets.NUGET_PUBLISH_KEY }}
PUBLISH_REPO_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ env:
GOVERSION: 1.21.x
JAVAVERSION: "11"
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NODEVERSION: 16.x
NODEVERSION: 20.x
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NUGET_PUBLISH_KEY: ${{ secrets.NUGET_PUBLISH_KEY }}
PUBLISH_REPO_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ env:
GOVERSION: 1.21.x
JAVAVERSION: "11"
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NODEVERSION: 16.x
NODEVERSION: 20.x
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NUGET_PUBLISH_KEY: ${{ secrets.NUGET_PUBLISH_KEY }}
PUBLISH_REPO_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/resync-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ env:
GOVERSION: 1.21.x
JAVAVERSION: "11"
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NODEVERSION: 16.x
NODEVERSION: 20.x
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NUGET_PUBLISH_KEY: ${{ secrets.NUGET_PUBLISH_KEY }}
PUBLISH_REPO_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/run-acceptance-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ env:
GOVERSION: 1.21.x
JAVAVERSION: "11"
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NODEVERSION: 16.x
NODEVERSION: 20.x
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NUGET_PUBLISH_KEY: ${{ secrets.NUGET_PUBLISH_KEY }}
PUBLISH_REPO_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
Expand Down
91 changes: 0 additions & 91 deletions .github/workflows/update-bridge.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/upgrade-provider.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
upgrade_provider:
if: ${{ contains(github.event.issue.title, 'Upgrade terraform-provider-') }}
if: ${{ contains(github.event.issue.title, 'Upgrade terraform-provider-') || github.event_name == 'workflow_dispatch' }}
name: upgrade-provider
runs-on: ubuntu-latest
steps:
Expand Down
32 changes: 27 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ JAVA_GEN := pulumi-java-gen
JAVA_GEN_VERSION := v0.5.4
TESTPARALLELISM := 10
WORKING_DIR := $(shell pwd)
PULUMI_CONVERT := 0

development: install_plugins provider build_sdks install_sdks

Expand Down Expand Up @@ -93,9 +94,8 @@ install_dotnet_sdk:
install_nodejs_sdk:
yarn link --cwd $(WORKING_DIR)/sdk/nodejs/bin

install_plugins:
[ -x "$(shell command -v pulumi 2>/dev/null)" ] || curl -fsSL https://get.pulumi.com | sh
pulumi plugin install resource random 4.2.0
install_plugins: .pulumi/bin/pulumi
.pulumi/bin/pulumi plugin install resource random 4.2.0

lint_provider: provider
cd provider && golangci-lint run -c ../.golangci.yml
Expand All @@ -108,7 +108,7 @@ test:

tfgen: install_plugins upstream
(cd provider && go build $(PULUMI_PROVIDER_BUILD_PARALLELISM) -o $(WORKING_DIR)/bin/$(TFGEN) -ldflags "-X $(PROJECT)/$(VERSION_PATH)=$(VERSION)" $(PROJECT)/$(PROVIDER_PATH)/cmd/$(TFGEN))
$(WORKING_DIR)/bin/$(TFGEN) schema --out provider/cmd/$(PROVIDER)
PATH=${PWD}/.pulumi/bin:$$PATH PULUMI_CONVERT=$(PULUMI_CONVERT) $(WORKING_DIR)/bin/$(TFGEN) schema --out provider/cmd/$(PROVIDER)
(cd provider && VERSION=$(VERSION) go generate cmd/$(PROVIDER)/main.go)

upstream:
Expand All @@ -125,4 +125,26 @@ upstream.rebase:
bin/pulumi-java-gen:
$(shell pulumictl download-binary -n pulumi-language-java -v $(JAVA_GEN_VERSION) -r pulumi/pulumi-java)

.PHONY: development build build_sdks install_go_sdk install_java_sdk install_python_sdk install_sdks only_build build_dotnet build_go build_java build_nodejs build_python clean cleanup help install_dotnet_sdk install_nodejs_sdk install_plugins lint_provider provider test tfgen upstream upstream.finalize upstream.rebase
# To make an immediately observable change to .ci-mgmt.yaml:
#
# - Edit .ci-mgmt.yaml
# - Run make ci-mgmt to apply the change locally.
#
ci-mgmt: .ci-mgmt.yaml
rm .github/workflows/*.yml # Copied from update-workflows.yml
go run github.com/pulumi/ci-mgmt/provider-ci@master generate \
--name pulumi/pulumi-$(PACK) \
--out . \
--template bridged-provider \
--config $<

.pulumi/bin/pulumi: HOME := $(WORKING_DIR)
.pulumi/bin/pulumi: .pulumi/version
curl -fsSL https://get.pulumi.com | sh -s -- --version $(cat .pulumi/version)

# Compute the version of Pulumi to use by inspecting the Go dependencies of the provider.
.pulumi/version:
@mkdir -p .pulumi
@cd provider && go list -f "{{slice .Version 1}}" -m github.com/pulumi/pulumi/pkg/v3 | tee ../$@

.PHONY: development build build_sdks install_go_sdk install_java_sdk install_python_sdk install_sdks only_build build_dotnet build_go build_java build_nodejs build_python clean cleanup help install_dotnet_sdk install_nodejs_sdk install_plugins lint_provider provider test tfgen upstream upstream.finalize upstream.rebase ci-mgmt

0 comments on commit 3cd4fa7

Please sign in to comment.