-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
21ef7d5
commit 7375a2e
Showing
4 changed files
with
50 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,82 +29,79 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repo | ||
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # tag=v3.5.3 | ||
uses: actions/checkout@v3 | ||
|
||
- name: Unshallow clone for tags | ||
run: git fetch --prune --unshallow --tags | ||
|
||
- name: Install Go | ||
uses: actions/setup-go@fac708d6674e30b6ba41289acaab6d4b75aa0753 # tag=v4.0.1 | ||
uses: actions/setup-go@v3 | ||
with: | ||
go-version: ${{matrix.goversion}} | ||
go-version: ${{ matrix.goversion }} | ||
|
||
- name: Install pulumictl | ||
run: | | ||
wget https://github.com/pulumi/pulumictl/releases/download/v0.0.42/pulumictl-v0.0.42-linux-amd64.tar.gz -O /tmp/pulumictl-v0.0.42-linux-amd64.tar.gz | ||
tar -xvf /tmp/pulumictl-v0.0.42-linux-amd64.tar.gz -C /tmp | ||
mv /tmp/pulumictl /usr/local/bin | ||
# - name: Install pulumictl | ||
# uses: jaxxstorm/action-install-gh-release@c5ead9a448b4660cf1e7866ee22e4dc56538031a # tag=v1.10.0 | ||
# env: | ||
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
# with: | ||
# repo: pulumi/pulumictl | ||
uses: jaxxstorm/[email protected] | ||
with: | ||
repo: pulumi/pulumictl | ||
|
||
- name: Set PreRelease Version | ||
run: echo "GORELEASER_CURRENT_TAG=v$(pulumictl get version --language generic)" >> $GITHUB_ENV | ||
- uses: sigstore/cosign-installer@6e04d228eb30da1757ee4e1dd75a0ec73a653e06 # v3.1.1 | ||
- uses: anchore/sbom-action/download-syft@78fc58e266e87a38d4194b2137a3d4e9bcaf7ca1 # v0.14.3 | ||
|
||
- name: Run GoReleaser | ||
uses: goreleaser/goreleaser-action@336e29918d653399e599bfca99fadc1d7ffbc9f7 # tag=v4.3.0 | ||
uses: goreleaser/goreleaser-action@v2 | ||
with: | ||
args: -p 3 release --rm-dist | ||
version: latest | ||
- name: Create tag | ||
uses: actions/github-script@d7906e4ad0b1822421a7e6a35d5ca353c962f410 # tag=v6.4.1 | ||
with: | ||
script: | | ||
github.rest.git.createRef({ | ||
owner: context.repo.owner, | ||
repo: context.repo.repo, | ||
ref: 'refs/tags/sdk/${{ github.ref_name }}', | ||
sha: context.sha | ||
}) | ||
|
||
strategy: | ||
fail-fast: true | ||
matrix: | ||
goversion: | ||
- 1.20.x | ||
|
||
publish_sdk: | ||
name: Publish SDKs | ||
runs-on: ubuntu-latest | ||
needs: publish_binary | ||
steps: | ||
- name: Checkout Repo | ||
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # tag=v3.5.3 | ||
uses: actions/checkout@v3 | ||
|
||
- name: Unshallow clone for tags | ||
run: git fetch --prune --unshallow --tags | ||
|
||
- name: Install Go | ||
uses: actions/setup-go@fac708d6674e30b6ba41289acaab6d4b75aa0753 # tag=v4.0.1 | ||
uses: actions/setup-go@v3 | ||
with: | ||
go-version: ${{ matrix.goversion }} | ||
|
||
- name: Install pulumictl | ||
uses: jaxxstorm/action-install-gh-release@c5ead9a448b4660cf1e7866ee22e4dc56538031a # tag=v1.10.0 | ||
uses: jaxxstorm/action-install-gh-release@v1.5.0 | ||
with: | ||
repo: pulumi/pulumictl | ||
|
||
- name: Install Pulumi CLI | ||
uses: pulumi/action-install-pulumi-cli@b374ceb6168550de27c6eba92e01c1a774040e11 # tag=v2.0.0 | ||
uses: pulumi/[email protected] | ||
|
||
- name: Setup Node | ||
uses: actions/setup-node@e33196f7422957bea03ed53f6fbb155025ffc7b8 # tag=v3.7.0 | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: ${{matrix.nodeversion}} | ||
registry-url: ${{env.NPM_REGISTRY_URL}} | ||
node-version: ${{ matrix.nodeversion }} | ||
registry-url: ${{ env.NPM_REGISTRY_URL }} | ||
|
||
- name: Setup DotNet | ||
uses: actions/setup-dotnet@3447fd6a9f9e57506b15f895c5b76d3b197dc7c2 # tag=v2.1.0 | ||
uses: actions/setup-dotnet@v1 | ||
with: | ||
dotnet-version: ${{matrix.dotnetverson}} | ||
dotnet-version: ${{ matrix.dotnetverson }} | ||
|
||
- name: Setup Python | ||
uses: actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # tag=v4.2.0 | ||
uses: actions/setup-python@v3 | ||
with: | ||
python-version: ${{matrix.pythonversion}} | ||
python-version: ${{ matrix.pythonversion }} | ||
|
||
- name: Generate SDK | ||
run: make ${{ matrix.language }}_sdk | ||
|
||
- name: Check worktree clean | ||
run: | | ||
git update-index -q --refresh | ||
|
@@ -114,25 +111,30 @@ jobs: | |
git diff | ||
exit 1 | ||
fi | ||
- if: ${{ matrix.language == 'python' && env.PUBLISH_PYPI == 'true' }} | ||
name: Publish package to PyPI | ||
uses: pypa/gh-action-pypi-publish@f8c70e705ffc13c3b4d1221169b84f12a75d6ca8 # tag=v1.8.8 | ||
- name: Publish package to PyPI | ||
if: ${{ matrix.language == 'python' && env.PUBLISH_PYPI == 'true' }} | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
user: ${{ env.PYPI_USERNAME }} | ||
password: ${{ env.PYPI_PASSWORD }} | ||
packages_dir: ${{github.workspace}}/sdk/python/bin/dist | ||
- if: ${{ matrix.language == 'nodejs' && env.PUBLISH_NPM == 'true' }} | ||
uses: JS-DevTools/npm-publish@5a85faf05d2ade2d5b6682bfe5359915d5159c6c # tag=v2.2.1 | ||
|
||
- name: Publish package to NPM | ||
if: ${{ matrix.language == 'nodejs' && env.PUBLISH_NPM == 'true' }} | ||
uses: JS-DevTools/npm-publish@v1 | ||
with: | ||
access: "public" | ||
token: ${{ env.NPM_TOKEN }} | ||
package: ${{github.workspace}}/sdk/nodejs/bin/package.json | ||
provenance: true | ||
- if: ${{ matrix.language == 'dotnet' && env.PUBLISH_NUGET == 'true' }} | ||
name: publish nuget package | ||
|
||
- name: Publish package to Nuget | ||
if: ${{ matrix.language == 'dotnet' && env.PUBLISH_NUGET == 'true' }} | ||
run: | | ||
dotnet nuget push ${{github.workspace}}/sdk/dotnet/bin/Debug/*.nupkg -s ${{ env.NUGET_FEED_URL }} -k ${{ env.NUGET_PUBLISH_KEY }} | ||
echo "done publishing packages" | ||
strategy: | ||
fail-fast: true | ||
matrix: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
0.0.2-alpha.1691081005+a9c7ed06.dirty | ||
0.0.2-alpha.1691101684+21ef7d57.dirty |