chore: Reduce deployment times by excluding Docker images (#1945)

* chore: Reduce deployment times by excluding Docker images

Only the Windows and Linux binaries are build during deploy, so we
can save many minutes by excluding Docker images.

* Stop docker image builds on snapshot

* Fix artifact upload

* Skip typecheck for release

* Flag deploy
This commit is contained in:
Kyle Carberry
2022-06-04 19:56:45 +00:00
committed by GitHub
parent c9a4642a12
commit 5edd086b69
5 changed files with 31 additions and 25 deletions
+13 -17
View File
@@ -355,10 +355,6 @@ jobs:
path: ${{ steps.go-cache-paths.outputs.go-mod }}
key: ${{ runner.os }}-release-go-mod-${{ hashFiles('**/go.sum') }}
- uses: goreleaser/goreleaser-action@v3
with:
install-only: true
- name: Cache Node
id: cache-node
uses: actions/cache@v3
@@ -366,10 +362,14 @@ jobs:
path: |
**/node_modules
.eslintcache
key: js-${{ runner.os }}-test-${{ hashFiles('**/yarn.lock') }}
key: js-${{ runner.os }}-release-node-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
js-${{ runner.os }}-
- uses: goreleaser/goreleaser-action@v3
with:
install-only: true
- name: Build site
run: make -B site/out/index.html
@@ -379,18 +379,6 @@ jobs:
version: latest
args: release --snapshot --rm-dist --skip-sign
- uses: actions/upload-artifact@v3
with:
name: coder_windows_amd64.zip
path: ./dist/coder_*_windows_amd64.zip
retention-days: 7
- uses: actions/upload-artifact@v3
with:
name: coder_linux_amd64.tar.gz
path: ./dist/coder_*_linux_amd64.tar.gz
retention-days: 7
- name: Install Release
run: |
gcloud config set project coder-dogfood
@@ -402,6 +390,14 @@ jobs:
- name: Start
run: gcloud compute ssh coder -- sudo service coder restart
- uses: actions/upload-artifact@v3
with:
name: coder
path: |
./dist/coder_*_linux_amd64.tar.gz
./dist/coder_*_windows_amd64.zip
retention-days: 7
test-js:
name: "test/js"
runs-on: ubuntu-latest