Skip to content

Commit

Permalink
Add local deploy check to CI
Browse files Browse the repository at this point in the history
Signed-off-by: Hasan Turken <turkenh@gmail.com>
  • Loading branch information
turkenh committed Nov 15, 2022
1 parent 3a3058b commit 3e63df7
Show file tree
Hide file tree
Showing 2 changed files with 44 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,49 @@ jobs:
flags: unittests
file: _output/tests/linux_amd64/coverage.txt

local-deploy:
runs-on: ubuntu-22.04
needs: detect-noop
if: needs.detect-noop.outputs.noop != 'true'

steps:
- name: Checkout
uses: actions/checkout@v2
with:
submodules: true

- name: Fetch History
run: git fetch --prune --unshallow

- name: Setup Go
uses: actions/setup-go@v2
with:
go-version: ${{ env.GO_VERSION }}

- name: Find the Go Build Cache
id: go
run: echo "::set-output name=cache::$(make go.cachedir)"

- name: Cache the Go Build Cache
uses: actions/cache@v2
with:
path: ${{ steps.go.outputs.cache }}
key: ${{ runner.os }}-build-unit-tests-${{ hashFiles('**/go.sum') }}
restore-keys: ${{ runner.os }}-build-unit-tests-

- name: Cache Go Dependencies
uses: actions/cache@v2
with:
path: .work/pkg
key: ${{ runner.os }}-pkg-${{ hashFiles('**/go.sum') }}
restore-keys: ${{ runner.os }}-pkg-

- name: Vendor Dependencies
run: make vendor vendor.check

- name: Deploying locally built provider package and ensuring it is running
run: make local-deploy

publish-artifacts:
runs-on: ubuntu-22.04
needs: detect-noop
Expand Down
1 change: 1 addition & 0 deletions examples/workspace-inline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ kind: Workspace
metadata:
name: example-inline
annotations:
meta.upbound.io/example-id: tf/v1alpha1/repository
# The terraform workspace will be named 'coolbucket'. If you omit this
# annotation it would be derived from metadata.name - e.g. 'example-inline'.
crossplane.io/external-name: coolbucket
Expand Down

0 comments on commit 3e63df7

Please sign in to comment.