Compare commits
12 commits
master
...
t0yv0/buil
Author | SHA1 | Date | |
---|---|---|---|
f4873b9560 | |||
487cbf87b2 | |||
33608ef2f5 | |||
12289325c5 | |||
c76075005b | |||
9a48902e1c | |||
10b9606ed7 | |||
17b49ed6fd | |||
e8c6f643a8 | |||
293b73be51 | |||
28db49b0cb | |||
59568580c1 |
213
.github/workflows/build.yml
vendored
Normal file
213
.github/workflows/build.yml
vendored
Normal file
|
@ -0,0 +1,213 @@
|
||||||
|
name: Builds CLI and SDK binaries.
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_call:
|
||||||
|
inputs:
|
||||||
|
go-version:
|
||||||
|
description: 'Version of the Go toolchain for the build'
|
||||||
|
default: '1.17.x'
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
python-version:
|
||||||
|
description: 'Version of the Python toolchain for the build'
|
||||||
|
default: '3.9.x'
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
node-version:
|
||||||
|
description: 'Version of the Node toolchain for the build'
|
||||||
|
default: '14.x'
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
dotnet-version:
|
||||||
|
description: 'Version of the .NET toolchain for the build'
|
||||||
|
default: '3.1.x'
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
goreleaser-flags:
|
||||||
|
description: 'Command-line flags to pass to goreleaser'
|
||||||
|
default: '-p 3 -f .goreleaser.build.yml --snapshot --skip-validate'
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
secrets: {}
|
||||||
|
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build_pulumi_go_binaries:
|
||||||
|
name: Build Pulumi Go binaries
|
||||||
|
|
||||||
|
# Due to the use of CGO in `pulumi` this cross-compilation step
|
||||||
|
# cannot proceed on `ubuntu-latest`, which would have been
|
||||||
|
# preferable.
|
||||||
|
runs-on: macos-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout Repo
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
ref: ${{ env.PR_COMMIT_SHA }}
|
||||||
|
- name: Fetch Tags
|
||||||
|
run: |
|
||||||
|
git fetch --quiet --prune --unshallow --tags
|
||||||
|
- name: Install pulumictl
|
||||||
|
uses: jaxxstorm/action-install-gh-release@v1.2.0
|
||||||
|
with:
|
||||||
|
repo: pulumi/pulumictl
|
||||||
|
- name: Set up Go ${{ inputs.go-version }}
|
||||||
|
uses: actions/setup-go@v1
|
||||||
|
with:
|
||||||
|
go-version: ${{ inputs.go-version }}
|
||||||
|
- name: Compute current version to inform GoReleaser
|
||||||
|
run: |
|
||||||
|
echo "GORELEASER_CURRENT_TAG=v$(pulumictl get version --language generic -o)" >> $GITHUB_ENV
|
||||||
|
- name: Run GoReleaser to build Go Pulumi binaries
|
||||||
|
uses: goreleaser/goreleaser-action@v2
|
||||||
|
with:
|
||||||
|
version: latest
|
||||||
|
args: ${{ inputs.goreleaser-flags }}
|
||||||
|
- name: Upload pulumi-darwin-arm64.tar.gz
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: pulumi-darwin-arm64.tar.gz
|
||||||
|
path: goreleaser/pulumi*-darwin-arm64.tar.gz
|
||||||
|
- name: Upload pulumi-darwin-x64.tar.gz
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: pulumi-darwin-x64.tar.gz
|
||||||
|
path: goreleaser/pulumi*-darwin-x64.tar.gz
|
||||||
|
- name: Upload pulumi-linux-arm64.tar.gz
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: pulumi-linux-arm64.tar.gz
|
||||||
|
path: goreleaser/pulumi*-linux-arm64.tar.gz
|
||||||
|
- name: Upload pulumi-linux-x64.tar.gz
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: pulumi-linux-x64.tar.gz
|
||||||
|
path: goreleaser/pulumi*-linux-x64.tar.gz
|
||||||
|
- name: Upload pulumi-windows-x64.zip
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: pulumi-windows-x64.zip
|
||||||
|
path: goreleaser/pulumi*-windows-x64.zip
|
||||||
|
|
||||||
|
build_python_sdk:
|
||||||
|
name: Build Pulumi Python SDK wheel
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout Repo
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
ref: ${{ env.PR_COMMIT_SHA }}
|
||||||
|
- name: Fetch Tags
|
||||||
|
run: |
|
||||||
|
git fetch --quiet --prune --unshallow --tags
|
||||||
|
- name: Install pulumictl
|
||||||
|
uses: jaxxstorm/action-install-gh-release@v1.2.0
|
||||||
|
with:
|
||||||
|
repo: pulumi/pulumictl
|
||||||
|
- name: Set up Python ${{ inputs.python-version }}
|
||||||
|
uses: actions/setup-python@v1
|
||||||
|
with:
|
||||||
|
python-version: ${{ inputs.python-version }}
|
||||||
|
- name: Compute current version to inform wheel build
|
||||||
|
run: |
|
||||||
|
echo "PYPY_VERSION=$(pulumictl get version --language python)" >> $GITHUB_ENV
|
||||||
|
- name: Build Pulumi Python SDK wheel
|
||||||
|
run: |
|
||||||
|
# TODO unify with sdk/python/Makefile once that does not use pipenv
|
||||||
|
cp README.md sdk/python/lib
|
||||||
|
cd sdk/python/lib
|
||||||
|
sed -i.bak "s/\${VERSION}/$PYPY_VERSION/g" setup.py
|
||||||
|
rm setup.py.bak
|
||||||
|
python3 -m venv venv
|
||||||
|
source venv/bin/activate
|
||||||
|
python -m pip install wheel
|
||||||
|
python setup.py build bdist_wheel --python-tag py3
|
||||||
|
- name: Upload pulumi.whl
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: pulumi.whl
|
||||||
|
path: sdk/python/lib/dist/*.whl
|
||||||
|
|
||||||
|
build_node_sdk:
|
||||||
|
name: Build Pulumi Node SDK tarball
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout Repo
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
ref: ${{ env.PR_COMMIT_SHA }}
|
||||||
|
- name: Fetch Tags
|
||||||
|
run: |
|
||||||
|
git fetch --quiet --prune --unshallow --tags
|
||||||
|
- name: Install pulumictl
|
||||||
|
uses: jaxxstorm/action-install-gh-release@v1.2.0
|
||||||
|
with:
|
||||||
|
repo: pulumi/pulumictl
|
||||||
|
- name: Set up Node ${{ inputs.node-version }}
|
||||||
|
uses: actions/setup-node@v1
|
||||||
|
with:
|
||||||
|
node-version: ${{ inputs.node-version }}
|
||||||
|
- name: Install yarn
|
||||||
|
run: |
|
||||||
|
npm install -g yarn
|
||||||
|
- name: Make no-op Go command to avoid Go builds
|
||||||
|
run: |
|
||||||
|
cd sdk/nodejs
|
||||||
|
mkdir -p bin
|
||||||
|
ln -s $(which echo) bin/go
|
||||||
|
- name: Ensure installed dependencies
|
||||||
|
run: |
|
||||||
|
cd sdk/nodejs
|
||||||
|
PATH=./bin:$PATH make ensure
|
||||||
|
- name: Build the Node SDK package
|
||||||
|
run: |
|
||||||
|
cd sdk/nodejs
|
||||||
|
PATH=./bin:$PATH make build_package
|
||||||
|
- name: Pack the Node SDK
|
||||||
|
run: |
|
||||||
|
cd sdk/nodejs/bin
|
||||||
|
npm pack
|
||||||
|
- name: Upload pulumi-node-sdk.tgz
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: pulumi-node-sdk.tgz
|
||||||
|
path: sdk/nodejs/bin/*.tgz
|
||||||
|
|
||||||
|
build_dotnet_sdk:
|
||||||
|
name: Build Pulumi .NET SDK NuGet packages
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout Repo
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
ref: ${{ env.PR_COMMIT_SHA }}
|
||||||
|
- name: Fetch Tags
|
||||||
|
run: |
|
||||||
|
git fetch --quiet --prune --unshallow --tags
|
||||||
|
- name: Install pulumictl
|
||||||
|
uses: jaxxstorm/action-install-gh-release@v1.2.0
|
||||||
|
with:
|
||||||
|
repo: pulumi/pulumictl
|
||||||
|
- name: Set up DotNet ${{ inputs.dotnet-version }}
|
||||||
|
uses: actions/setup-dotnet@v1
|
||||||
|
with:
|
||||||
|
dotnet-version: ${{ inputs.dotnet-version }}
|
||||||
|
- name: Compute current version to inform the NuGet package build
|
||||||
|
run: |
|
||||||
|
echo "DOTNET_VERSION=$(pulumictl get version --language dotnet)" >> $GITHUB_ENV
|
||||||
|
- name: Build the .NET SDK package
|
||||||
|
run: |
|
||||||
|
cd sdk/dotnet
|
||||||
|
dotnet build --configuration Release dotnet.sln /p:Version=$DOTNET_VERSION
|
||||||
|
- name: Pack the .NET SDK package
|
||||||
|
run: |
|
||||||
|
cd sdk/dotnet
|
||||||
|
dotnet pack --configuration Release --output nupkgs dotnet.sln /p:Version=$DOTNET_VERSION
|
||||||
|
- name: Upload the NuGet packages
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: pulumi-nuget-packages
|
||||||
|
path: sdk/dotnet/nupkgs/*.nupkg
|
|
@ -33,6 +33,7 @@ concurrency:
|
||||||
cancel-in-progress: true
|
cancel-in-progress: true
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
comment-notification:
|
comment-notification:
|
||||||
# We only care about adding the result to the PR if it's a repository_dispatch event
|
# We only care about adding the result to the PR if it's a repository_dispatch event
|
||||||
if: github.event_name == 'repository_dispatch'
|
if: github.event_name == 'repository_dispatch'
|
||||||
|
@ -51,6 +52,7 @@ jobs:
|
||||||
Please view the results of the PR Build + Acceptance Tests Run [Here][1]
|
Please view the results of the PR Build + Acceptance Tests Run [Here][1]
|
||||||
|
|
||||||
[1]: ${{ steps.vars.outputs.run-url }}
|
[1]: ${{ steps.vars.outputs.run-url }}
|
||||||
|
|
||||||
go-lint:
|
go-lint:
|
||||||
container: golangci/golangci-lint:latest
|
container: golangci/golangci-lint:latest
|
||||||
name: Lint ${{ matrix.directory }}
|
name: Lint ${{ matrix.directory }}
|
||||||
|
@ -66,6 +68,7 @@ jobs:
|
||||||
- name: Lint ${{ matrix.directory }}
|
- name: Lint ${{ matrix.directory }}
|
||||||
run: |
|
run: |
|
||||||
cd ${{ matrix.directory }} && golangci-lint run -c ../.golangci.yml
|
cd ${{ matrix.directory }} && golangci-lint run -c ../.golangci.yml
|
||||||
|
|
||||||
sdk-lint:
|
sdk-lint:
|
||||||
name: Lint SDKs
|
name: Lint SDKs
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
@ -124,8 +127,14 @@ jobs:
|
||||||
- name: Lint .NET
|
- name: Lint .NET
|
||||||
run: |
|
run: |
|
||||||
cd sdk/dotnet && make lint
|
cd sdk/dotnet && make lint
|
||||||
build_and_test:
|
|
||||||
name: Build & Test
|
build:
|
||||||
|
name: Build
|
||||||
|
uses: pulumi/pulumi/.github/workflows/build.yml@487cbf87b26496dc7f205eb85912689a36830d6c
|
||||||
|
|
||||||
|
test:
|
||||||
|
name: Test
|
||||||
|
needs: build
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
platform: [ ubuntu-latest, macos-latest ]
|
platform: [ ubuntu-latest, macos-latest ]
|
||||||
|
@ -174,9 +183,12 @@ jobs:
|
||||||
- run: mkdir -p ${{ runner.temp }}/opt/pulumi/nuget
|
- run: mkdir -p ${{ runner.temp }}/opt/pulumi/nuget
|
||||||
- run: dotnet nuget add source ${{ runner.temp }}/opt/pulumi/nuget
|
- run: dotnet nuget add source ${{ runner.temp }}/opt/pulumi/nuget
|
||||||
- name: Set up Node ${{ matrix.node-version }}
|
- name: Set up Node ${{ matrix.node-version }}
|
||||||
uses: actions/setup-node@v1
|
uses: actions/setup-node@v2
|
||||||
with:
|
with:
|
||||||
node-version: ${{ matrix.node-version }}
|
node-version: ${{ matrix.node-version }}
|
||||||
|
- name: Install yarn
|
||||||
|
run: |
|
||||||
|
npm install -g yarn
|
||||||
- name: Install pipenv
|
- name: Install pipenv
|
||||||
run: |
|
run: |
|
||||||
python -m pip install --upgrade pipenv pip requests wheel urllib3 chardet
|
python -m pip install --upgrade pipenv pip requests wheel urllib3 chardet
|
||||||
|
@ -210,26 +222,59 @@ jobs:
|
||||||
with:
|
with:
|
||||||
repo: t0yv0/goteststats
|
repo: t0yv0/goteststats
|
||||||
tag: v0.0.7
|
tag: v0.0.7
|
||||||
- name: Ensure
|
- name: Download Pulumi Go Binaries (linux-x64)
|
||||||
|
if: ${{ matrix.platform == 'ubuntu-latest' }}
|
||||||
|
uses: actions/download-artifact@v2
|
||||||
|
with:
|
||||||
|
name: pulumi-linux-x64.tar.gz
|
||||||
|
path: artifacts/go
|
||||||
|
- name: Download Pulumi Go Binaries (darwin-x64)
|
||||||
|
if: ${{ matrix.platform == 'macos-latest' }}
|
||||||
|
uses: actions/download-artifact@v2
|
||||||
|
with:
|
||||||
|
name: pulumi-darwin-x64.tar.gz
|
||||||
|
path: artifacts/go
|
||||||
|
- name: Install Pulumi Go Binaries
|
||||||
run: |
|
run: |
|
||||||
|
mkdir -p bin
|
||||||
|
tar -xf artifacts/go/*.tar.gz -C bin
|
||||||
|
echo "$PWD/bin/pulumi" >> $GITHUB_PATH
|
||||||
|
- name: Download Pulumi .NET NuGet packages
|
||||||
|
uses: actions/download-artifact@v2
|
||||||
|
with:
|
||||||
|
name: pulumi-nuget-packages
|
||||||
|
# path set to match PULUMI_LOCAL_NUGET
|
||||||
|
path: ${{ runner.temp }}/opt/pulumi/nuget
|
||||||
|
- name: Verify Pulumi Version
|
||||||
|
run: |
|
||||||
|
which pulumi
|
||||||
|
pulumi version
|
||||||
|
find ./bin
|
||||||
|
- name: Inspect downloaded artifacts
|
||||||
|
run: |
|
||||||
|
find artifacts
|
||||||
|
echo "PULUMI_LOCAL_NUGET=$PULUMI_LOCAL_NUGET"
|
||||||
|
ls $PULUMI_LOCAL_NUGET
|
||||||
|
env:
|
||||||
|
PULUMI_LOCAL_NUGET: ${{ runner.temp }}/opt/pulumi/nuget
|
||||||
|
- name: Ensure dependencies for the Node SDK
|
||||||
|
run: |
|
||||||
|
cd sdk/nodejs
|
||||||
make ensure
|
make ensure
|
||||||
- name: Dist
|
- name: Build the Node SDK
|
||||||
run: |
|
run: |
|
||||||
make dist
|
cd sdk/nodejs
|
||||||
env:
|
make build_package
|
||||||
PULUMI_NODE_MODULES: ${{ runner.temp }}/opt/pulumi/node_modules
|
cd bin
|
||||||
PULUMI_LOCAL_NUGET: ${{ runner.temp }}/opt/pulumi/nuget
|
yarn link
|
||||||
PULUMI_ROOT: ${{ runner.temp }}/opt/pulumi
|
- name: Ensure dependencies for the Python SDK
|
||||||
- name: Install
|
|
||||||
run: |
|
run: |
|
||||||
make install_all
|
cd sdk/python
|
||||||
# Install Pulumi Python SDK globally (on CI only) to workaround a
|
make ensure
|
||||||
# problem a sub-process in a test failing to find it.
|
- name: Install Python SDK
|
||||||
python -m pip install -e sdk/python/env/src
|
run: |
|
||||||
env:
|
cd sdk/python
|
||||||
PULUMI_NODE_MODULES: ${{ runner.temp }}/opt/pulumi/node_modules
|
make build_package
|
||||||
PULUMI_LOCAL_NUGET: ${{ runner.temp }}/opt/pulumi/nuget
|
|
||||||
PULUMI_ROOT: ${{ runner.temp }}/opt/pulumi
|
|
||||||
- name: Test
|
- name: Test
|
||||||
run: make TEST_ALL_DEPS= test_all
|
run: make TEST_ALL_DEPS= test_all
|
||||||
env:
|
env:
|
||||||
|
@ -245,7 +290,6 @@ jobs:
|
||||||
run: |
|
run: |
|
||||||
goteststats -statistic test-time test-results/*.json | head -n 100
|
goteststats -statistic test-time test-results/*.json | head -n 100
|
||||||
|
|
||||||
|
|
||||||
windows-build:
|
windows-build:
|
||||||
name: Windows Build + Test
|
name: Windows Build + Test
|
||||||
strategy:
|
strategy:
|
||||||
|
|
166
.goreleaser.build.yml
Normal file
166
.goreleaser.build.yml
Normal file
|
@ -0,0 +1,166 @@
|
||||||
|
dist: goreleaser
|
||||||
|
project_name: pulumi
|
||||||
|
before:
|
||||||
|
hooks:
|
||||||
|
- ./scripts/prep-for-goreleaser.sh
|
||||||
|
release:
|
||||||
|
disable: true
|
||||||
|
changelog:
|
||||||
|
skip: true
|
||||||
|
builds:
|
||||||
|
# Windows builds
|
||||||
|
- id: pulumi-windows
|
||||||
|
binary: pulumi
|
||||||
|
dir: pkg
|
||||||
|
goarch:
|
||||||
|
- amd64
|
||||||
|
goos:
|
||||||
|
- windows
|
||||||
|
ldflags:
|
||||||
|
- -X github.com/pulumi/pulumi/pkg/v3/version.Version={{.Tag}}
|
||||||
|
main: ./cmd/pulumi
|
||||||
|
- id: pulumi-language-nodejs-windows
|
||||||
|
binary: pulumi-language-nodejs
|
||||||
|
dir: sdk
|
||||||
|
goarch:
|
||||||
|
- amd64
|
||||||
|
goos:
|
||||||
|
- windows
|
||||||
|
ldflags:
|
||||||
|
- -X github.com/pulumi/pulumi/pkg/v3/version.Version={{.Tag}}
|
||||||
|
main: ./nodejs/cmd/pulumi-language-nodejs
|
||||||
|
- id: pulumi-language-python-windows
|
||||||
|
binary: pulumi-language-python
|
||||||
|
dir: sdk
|
||||||
|
goarch:
|
||||||
|
- amd64
|
||||||
|
goos:
|
||||||
|
- windows
|
||||||
|
ldflags:
|
||||||
|
- -X github.com/pulumi/pulumi/pkg/v3/version.Version={{.Tag}}
|
||||||
|
main: ./python/cmd/pulumi-language-python
|
||||||
|
- id: pulumi-language-dotnet-windows
|
||||||
|
binary: pulumi-language-dotnet
|
||||||
|
dir: sdk
|
||||||
|
goarch:
|
||||||
|
- amd64
|
||||||
|
goos:
|
||||||
|
- windows
|
||||||
|
ldflags:
|
||||||
|
- -X github.com/pulumi/pulumi/pkg/v3/version.Version={{.Tag}}
|
||||||
|
main: ./dotnet/cmd/pulumi-language-dotnet
|
||||||
|
- id: pulumi-language-go-windows
|
||||||
|
binary: pulumi-language-go
|
||||||
|
dir: sdk
|
||||||
|
goarch:
|
||||||
|
- amd64
|
||||||
|
goos:
|
||||||
|
- windows
|
||||||
|
ldflags:
|
||||||
|
- -X github.com/pulumi/pulumi/pkg/v3/version.Version={{.Tag}}
|
||||||
|
main: ./go/pulumi-language-go
|
||||||
|
# UNIX builds
|
||||||
|
- id: pulumi-unix
|
||||||
|
binary: pulumi
|
||||||
|
dir: pkg
|
||||||
|
goarch:
|
||||||
|
- amd64
|
||||||
|
- arm64
|
||||||
|
goos:
|
||||||
|
- linux
|
||||||
|
- darwin
|
||||||
|
ldflags:
|
||||||
|
- -X github.com/pulumi/pulumi/pkg/v3/version.Version={{.Tag}}
|
||||||
|
main: ./cmd/pulumi
|
||||||
|
- id: pulumi-language-nodejs-unix
|
||||||
|
binary: pulumi-language-nodejs
|
||||||
|
dir: sdk
|
||||||
|
goarch:
|
||||||
|
- amd64
|
||||||
|
- arm64
|
||||||
|
goos:
|
||||||
|
- linux
|
||||||
|
- darwin
|
||||||
|
ldflags:
|
||||||
|
- -X github.com/pulumi/pulumi/pkg/v3/version.Version={{.Tag}}
|
||||||
|
main: ./nodejs/cmd/pulumi-language-nodejs
|
||||||
|
- id: pulumi-language-python-unix
|
||||||
|
binary: pulumi-language-python
|
||||||
|
dir: sdk
|
||||||
|
goarch:
|
||||||
|
- amd64
|
||||||
|
- arm64
|
||||||
|
goos:
|
||||||
|
- linux
|
||||||
|
- darwin
|
||||||
|
ldflags:
|
||||||
|
- -X github.com/pulumi/pulumi/pkg/v3/version.Version={{.Tag}}
|
||||||
|
main: ./python/cmd/pulumi-language-python
|
||||||
|
- id: pulumi-language-dotnet-unix
|
||||||
|
binary: pulumi-language-dotnet
|
||||||
|
dir: sdk
|
||||||
|
goarch:
|
||||||
|
- amd64
|
||||||
|
- arm64
|
||||||
|
goos:
|
||||||
|
- linux
|
||||||
|
- darwin
|
||||||
|
ldflags:
|
||||||
|
- -X github.com/pulumi/pulumi/pkg/v3/version.Version={{.Tag}}
|
||||||
|
main: ./dotnet/cmd/pulumi-language-dotnet
|
||||||
|
- id: pulumi-language-go-unix
|
||||||
|
binary: pulumi-language-go
|
||||||
|
dir: sdk
|
||||||
|
goarch:
|
||||||
|
- amd64
|
||||||
|
- arm64
|
||||||
|
goos:
|
||||||
|
- linux
|
||||||
|
- darwin
|
||||||
|
ldflags:
|
||||||
|
- -X github.com/pulumi/pulumi/pkg/v3/version.Version={{.Tag}}
|
||||||
|
main: ./go/pulumi-language-go
|
||||||
|
|
||||||
|
|
||||||
|
archives:
|
||||||
|
- id: pulumi-unix
|
||||||
|
wrap_in_directory: pulumi
|
||||||
|
builds:
|
||||||
|
- pulumi-language-dotnet-unix
|
||||||
|
- pulumi-language-go-unix
|
||||||
|
- pulumi-language-python-unix
|
||||||
|
- pulumi-language-nodejs-unix
|
||||||
|
- pulumi-unix
|
||||||
|
replacements:
|
||||||
|
amd64: x64
|
||||||
|
files:
|
||||||
|
- pulumi-resource-pulumi-nodejs
|
||||||
|
- pulumi-resource-pulumi-python
|
||||||
|
- pulumi-analyzer-policy
|
||||||
|
- pulumi-analyzer-policy-python
|
||||||
|
- pulumi-language-python-exec
|
||||||
|
name_template: "{{ .ProjectName }}-{{ .Tag }}-{{ .Os }}-{{ .Arch }}"
|
||||||
|
- id: pulumi-windows
|
||||||
|
wrap_in_directory: pulumi/bin
|
||||||
|
builds:
|
||||||
|
- pulumi-language-dotnet-windows
|
||||||
|
- pulumi-language-go-windows
|
||||||
|
- pulumi-language-python-windows
|
||||||
|
- pulumi-language-nodejs-windows
|
||||||
|
- pulumi-windows
|
||||||
|
replacements:
|
||||||
|
amd64: x64
|
||||||
|
format: zip
|
||||||
|
files:
|
||||||
|
- pulumi-resource-pulumi-nodejs.cmd
|
||||||
|
- pulumi-resource-pulumi-python.cmd
|
||||||
|
- pulumi-python3-shim.cmd
|
||||||
|
- pulumi-python-shim.cmd
|
||||||
|
- pulumi-analyzer-policy.cmd
|
||||||
|
- pulumi-analyzer-policy-python.cmd
|
||||||
|
- pulumi-language-python-exec
|
||||||
|
name_template: "{{ .ProjectName }}-{{ .Tag }}-{{ .Os }}-{{ .Arch }}"
|
||||||
|
snapshot:
|
||||||
|
name_template: "{{ .Version }}-SNAPSHOT"
|
||||||
|
checksum:
|
||||||
|
name_template: "{{ .ProjectName }}-{{ .Version }}-checksums.txt"
|
|
@ -2015,12 +2015,17 @@ func (pt *ProgramTester) prepareDotNetProject(projinfo *engine.Projinfo) error {
|
||||||
for _, dep := range pt.opts.Dependencies {
|
for _, dep := range pt.opts.Dependencies {
|
||||||
|
|
||||||
// dotnet add package requires a specific version in case of a pre-release, so we have to look it up.
|
// dotnet add package requires a specific version in case of a pre-release, so we have to look it up.
|
||||||
matches, err := filepath.Glob(filepath.Join(localNuget, dep+".?.*.nupkg"))
|
globPattern := filepath.Join(localNuget, dep+".?.*.nupkg")
|
||||||
|
matches, err := filepath.Glob(globPattern)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return fmt.Errorf("failed to find a local Pulumi NuGet package: %w", err)
|
return fmt.Errorf("failed to find a local Pulumi NuGet package: %w", err)
|
||||||
}
|
}
|
||||||
if len(matches) != 1 {
|
if len(matches) != 1 {
|
||||||
return fmt.Errorf("attempting to find a local Pulumi NuGet package yielded %v results", matches)
|
return fmt.Errorf("attempting to find a local NuGet package %s by searching %s yielded %d results: %v",
|
||||||
|
dep,
|
||||||
|
globPattern,
|
||||||
|
len(matches),
|
||||||
|
matches)
|
||||||
}
|
}
|
||||||
file := filepath.Base(matches[0])
|
file := filepath.Base(matches[0])
|
||||||
r := strings.NewReplacer(dep+".", "", ".nupkg", "")
|
r := strings.NewReplacer(dep+".", "", ".nupkg", "")
|
||||||
|
|
Loading…
Reference in a new issue