Archived
1
0
Commit Graph

260 Commits

Author SHA1 Message Date
Joe Previte
06483bc59d
refactor: rm node_mods caching in release workflow (#5895) 2022-12-15 14:24:59 -07:00
Joe Previte
9012ddfe79
refactor: use separate cache key in release, run standalone after caching (#5859)
* refactor: remove keytar dep in cross-compile

* refactor: try other keytar package

* refactor: remove keytar step in cross-compile

* fix: manually remove keytar

* try this first

* I think this is it

* Revert "I think this is it"

This reverts commit 5c566b0c01.

* okay this is it

* fixup

* try legacy peer

* remove keytar before standalone

* wrong path

* maybe

* revert: change *npm* back to npm*

* revert: don't uninstall keytar

* fix: use npm run standalone-release

* fixup formatting

* Revert "refactor: remove yarn.lock steps (#5850)"

This reverts commit 907747d394.

* fixup: remove the --exclude

* refactor: remove yarn.lock check

* try ddd in postinstall

* refactor: cache before release:standalone

* refactor: add os to cache key in release

* chore: formatting

* Update ci/build/npm-postinstall.sh

* fixup: formatting
2022-12-12 22:03:07 +00:00
Joe Previte
1efc5f104e
fix: use npm and yarn consistently in build and release (#5852)
* refactor: remove keytar dep in cross-compile

* refactor: try other keytar package

* refactor: remove keytar step in cross-compile

* fix: manually remove keytar

* try this first

* I think this is it

* Revert "I think this is it"

This reverts commit 5c566b0c01.

* okay this is it

* fixup

* try legacy peer

* remove keytar before standalone

* wrong path

* maybe

* revert: change *npm* back to npm*

* revert: don't uninstall keytar

* fix: use npm run standalone-release

* fixup formatting

* Revert "refactor: remove yarn.lock steps (#5850)"

This reverts commit 907747d394.

* fixup: remove the --exclude

* refactor: remove yarn.lock check

Co-authored-by: repo-ranger[bot] <39074581+repo-ranger[bot]@users.noreply.github.com>
2022-12-12 21:41:29 +00:00
Joe Previte
ef5865f506
fix: add VERSION to env in publish.yaml (#5868)
When I did the last release, `VERSION` wasn't defined which lead to a
blank string in the PR title and the commit message here:

https://github.com/coder/code-server-aur/pull/24

This should fix that.
2022-12-12 21:24:06 +00:00
Joe Previte
48588ee542
chore: update download artifacts in release (#5841) 2022-12-12 17:47:27 +00:00
Geoffrey Huntley
ac6b5bd4e6
chore(nfpm): bump to latest version (#5860) 2022-12-12 08:52:33 -07:00
Joe Previte
0ca6620ee6
fix: add missing keytar deps (#5851)
* fix: add missing keytar deps

* fixup
2022-12-08 11:30:08 -07:00
Joe Previte
d8995ec0b8
refactor: use npm in build.yaml (#5849) 2022-12-08 10:37:42 -07:00
Joe Previte
83c3453f50
fix: quote VERSION in jq command in release (#5845) 2022-12-07 22:19:20 +00:00
Joe Previte
1484bee621
release: 4.9.0 (#5772)
* wip: changelog

* fixup

* fix: add +x to product.json in build-vscode

While testing a pre-release, there seems to be a bug with the file
permissions for `product.json`. Adding `chmod +x` to see if that fixes
it.

* chore: increase timeout

* fix: keep product.json file permissions in release

When we added the change to modify the `package.json` version using `mv`
and `jq` we didn't account for lost file permissions.

This caused a bug only happening in CI.

This should fix it by giving it 755 via `chmod`.

* trigger ci

* chore: update package.json bust cache

* fixup!: fix: keep product.json file permissions in release

* Revert "fix: add +x to product.json in build-vscode"

This reverts commit fc4d2b532f.

* chore: pin ubuntu runner in build code-server

* chore: update prettierignore

* chore: add notes to changelog

* chore: use ubuntu-22.04 for e2e

* chore: pin all jobs in build to ubuntu 20.04

* feat(wrapper): add tests for isChild

* fixup: include description ts-expect-error comment

* chore: update CHANGELOG

* chore: update Helm chart

* fixup: use our childProcess

* Update CHANGELOG.md

Co-authored-by: Asher <ash@coder.com>

Co-authored-by: Asher <ash@coder.com>
2022-12-06 13:28:27 -07:00
renovate[bot]
2cbb1135e1
chore(deps): update minor dependency updates (#5787)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-30 09:51:03 -07:00
Joe Previte
74edfe7c43
chore: fix typo in release.yaml (#5774) 2022-11-10 13:48:56 -07:00
renovate[bot]
c885c96644
chore(deps): update minor dependency updates (#5720)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-09 14:03:07 -07:00
Joe Previte
b978655c07
refactor: get version dynamically (#5753)
* refactor: get version dynamically

* chore: remove version

* fixup: missing quotes

* refactor: drop global VERSION

* wip: updating ersion in publish

* refactor: update publish.yaml with version changes

* refactor: release.yaml with new version changes

* refactor: update build.yaml with version changes

* chore: update maintainer

* fixup: update version in build-vscode

* fixup: fix github env version

* try macos only

* try again

* last resort

* joe again

* this oneee

* fixup: this should work

* try using inputs

* docs: update release notes

* fixup!: use env.VERSION in docker step

* fixup!: comment get and set version

* fixup!: remove compress release package comment

* fixup!: use $VERSION in npm-version

* refactor: set VERSION in build VS Code step

* refactor: use 0.0.0 in package.json version

* refactor: delete release-prep script

* Update ci/build/build-vscode.sh

* fixup!: remove extra VERSION set in aur
2022-11-08 22:45:01 +00:00
Joe Previte
505f07a9bc
fix: minor fixes related to release (#5732)
* fix: use * for test plugin engines

This removes the need to update this version with every version change.

* refactor: use npm-package in release assets

This adds a new job to `release.yaml` to upload the `npm-package` to the
release assets which will also allow us to download it in the
`publish.yaml` workflow.

* docs: update release instructions

* fixup!: use package.tar.gz
2022-11-01 10:16:30 -07:00
Joe Previte
ee47293cf6
Revert "Test branch (#5733)" (#5734)
This reverts commit 5c751f26ee.
2022-10-28 13:48:36 -07:00
Joe Previte
5c751f26ee
Test branch (#5733)
* fix: use * for test plugin engines

This removes the need to update this version with every version change.

* refactor: use npm-package in release assets

This adds a new job to `release.yaml` to upload the `npm-package` to the
release assets which will also allow us to download it in the
`publish.yaml` workflow.

* docs: update release instructions
2022-10-28 13:43:21 -07:00
Joe Previte
7c0c0b0c29
fix: merge in master from coder/code-server-aur (#5730)
This ensures that the branch is up-to-date with coder/code-server-aur
before opening a PR.
2022-10-28 10:44:00 -07:00
Joe Previte
ca182b9fb5
chore: prettierignore updates and setup-helm upgrade (#5721)
* chore: update prettierignore

* chore: upgrade setup-helm 3.4
2022-10-28 16:15:19 +00:00
Joe Previte
1134ee1c79
fix: pin helm to v3.10.1 (#5703)
Due to https://github.com/Azure/setup-helm/issues/99, this pins the
version to v3.10.1 as a temporary fix.
2022-10-25 16:24:53 +00:00
renovate[bot]
606811fbfd
chore(deps): update aquasecurity/trivy-action digest to e55de85 (#5702)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-25 08:32:55 -07:00
renovate[bot]
4a06d97f84
chore(deps): update dependency doctoc to v2.2.1 (#5648)
* chore(deps): update dependency doctoc to v2.2.1

* chore: update doctoc version in build.yaml

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Joe Previte <jjprevite@gmail.com>
2022-10-14 22:59:21 +00:00
Joe Previte
71a127a62b
refactor: update prettier and doctoc (#5605)
* docs: add toc to CODE OF CONDUCT

* chore: add prettier ignore blocks to docs

* chore: update styles for Dockerfile

* refactor: separate prettier, doctoc

This does a couple things:
- update `.prettierignore`
- split `prettier` and `doctoc` commands. you can still run with `yarn
  fmt`
- delete `fmt.sh` and add `doctoc.sh`

By doing so, we can run tasks in parallel in CI and we should also have
less false positives than before with `yarn fmt` locally.

* refactor: update prettier job, add doctoc

This modifies the prettier job to use actionsx/prettier. It also adds a
job for `doctoc`.

* chore: upgrade to prettier 2.7.1

* chore: pin doctoc to 2.0.0

* fixup!: add .pc to prettierignore

* feat: add --cache to prettier cmd
2022-10-13 22:16:55 +00:00
Joe Previte
3ac2307b5c
fix: add node to path (#5598)
* fix: remove deprecated symlink

* refactor: remove deprecation notice

* fixup! refactor: remove deprecation notice

* fix: add node to path

* fixup: shellcheck

* Update src/node/wrapper.ts

Co-authored-by: Asher <ash@coder.com>

* fixup!: fix: remove deprecated symlink

* Update ci/build/build-vscode.sh

Co-authored-by: Asher <ash@coder.com>

* Update ci/build/build-vscode.sh

Co-authored-by: Asher <ash@coder.com>

* fixup: use NODE_EXEC_PATh

* Update ci/build/build-vscode.sh

Co-authored-by: Asher <ash@coder.com>

Co-authored-by: Asher <ash@coder.com>
2022-09-29 18:02:53 -05:00
Joe Previte
8629d6a474
refactor: run security on package.json changes (#5602)
* refactor: run security on package.json changes

* fixup: add to main push too
2022-09-29 14:46:48 -05:00
Joe Previte
05289d3eb6
chore(ci): move platform steps to release (#5587)
* refactor: move platform steps build -> release

* fixup! refactor: move platform steps build -> release

* refactor: download npm package

* refactor: upload release-packages to draft

* refactor: remove draft step

* refactor: e2e rely on build now

* refactor: use npm package in e2e

* fix: update release workflow

* fixup: update cache key

* fixup: checkout submodules in e2e steps

* fixup: try install in release dir

* fix: copy node to release package

* docs: add notes about test for terminal

* fixup

* try cp instead

* try this

* fixup: clean it all up

* fixup: update names

* fixup: add proxy back

* fixup: add comment
2022-09-27 11:46:37 -07:00
Asher
7e98628167
fix: installer tests (#5578)
Also rename from yml to yaml.
2022-09-23 00:15:26 +00:00
renovate[bot]
42c21c9684
chore(deps): update tj-actions/changed-files action to v26 (#5579)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-22 19:57:54 +00:00
Joe Previte
51677f0819
feat(ci): refactor build workflow (#5572)
* refactor: remove stylelint

* refactor: move shellcheck to separate job

* refactor: add helm script and job

* refactor: add eslint job and yarn script

* fix(test/tsconfig): exclude test-plugin

* refactor: delete lint, add typecheck job

* refactor: remove prebuild

* wip: add notes about unit test refactor

* refactor: delete buggy socket test

This test was really added to in get cover specific lines but it's buggy
and only passes sometimes locally. I think it's okay to remove because:
- it's an implementation detail (not user facing)
- not preventing any specific regressions

* refactor: move test-plugin to integration suite

This seems more appropriate given this tests how a plugin might work
within code-server.

* wip

* wip: refactor vscode integration tests

* refactor: move unit tests to separate job

* fix: formatting

* Revert "wip: refactor vscode integration tests"

This reverts commit 13286bf4c9.

* Revert "refactor: move unit tests to separate job"

This reverts commit 6c87b540b4.

* feat: collect codecov integration tests

* fixup! feat: collect codecov integration tests

* fixup! feat: collect codecov integration tests

* fixup!: move helm step

* fixup!: update ids for caching

* trigger ci

* trigger ci

* chore: clean up names in security.yaml

* fixup!: remove .tsx

* fixup!: change to src/**"

* fixup!: move helm cmd to yaml

* fixup!: always build test plugin

* fixup!: fix plugin typings

* fixup! add back flakey test

* fixup!: only install helm deps if changes

* fixup!: revert node mod caching

* dont keep, test for asher

* fixup!: add make to centos

* refactor: add test:native

This adds a new script to run native tests (i.e. --help which should run
in ci on all platforms).

* try updating glibc

* try 2.25

* Revert "refactor: move test-plugin to integration suite"

This reverts commit bc02005dc0.

I couldn't get past some GLIBC errors in CI so moving back to unit
tests.

* Revert "try updating glibc"

This reverts commit 02ed560f22.

* fixup!

* asher: again

* try this for ts changes

* fixup

* refactor: scripts.yml -> scripts.yaml

* fixup!: move lint-sh to scripts.yaml

* fixup!: use apk for lint scripts

* fixup! fixup!: use apk for lint scripts

* fixup!: remove typecheck step

* fix: pattern for lint ts files

* test: lint should fail

* fixup! fixup!: use apk for lint scripts

* Revert "test: lint should fail"

This reverts commit 158c64db04.

* fixup!: skip cancel workflow on forks

Looks like the cancel action workflow can't run on forks due to secrets.

See https://github.com/andymckay/cancel-action/issues/4

* fixup: remove cancel-workflow

* fixup! fixup! fixup!: use apk for lint scripts

* fixup! fixup! fixup!: use apk for lint scripts

* fixup!: fix yarn key

* fixup!: add fetch-depth 0
2022-09-22 12:33:32 -07:00
Joe Previte
4223cf6e2b
refactor(ci): fix fetch-depth and add some caching (#5563)
* refactor: rename ci -> build.yaml

* feat: add build.yaml

* feat: add node caching to platform jobs

* trigger ci
2022-09-19 11:56:34 -05:00
Joe Previte
987c68a32a
feat: add release workflow (#5560)
* feat(ci): add draft release workflow

* refactor: delete old release-github workflows

* fixup! refactor: delete old release-github workflows

* fixup! refactor: delete old release-github workflows

* Update .github/workflows/release.yaml

* fixup!: remove release-notes.txt

* fixup!: change branch to current
2022-09-16 15:14:28 +00:00
Joe Previte
309a3b2c6e
chore: move security workflows (#5553)
* refactor: move security jobs to security.yaml

* fixup! refactor: move security jobs to security.yaml
2022-09-14 06:31:13 -07:00
Joe Previte
dbe87c5494
fix(ci): specify ref in aur publish job (#5550) 2022-09-09 22:50:21 +00:00
Florian Ritterhoff
b486354d6e
Update to 1.71 (#5535)
* chore: update upstream code

* update patches for vs 1.71.0

the cli fix seems to be fixed in upstream, the telemtry patch requires (again) some fixing and adjustments.

* add safari fix.

* increase ci timeout

Co-authored-by: Joe Previte <jjprevite@gmail.com>
2022-09-09 16:28:54 +00:00
renovate[bot]
74017ecc65
chore(deps): update robinraju/release-downloader action to v1.5 (#5538)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-06 13:34:04 -07:00
Joe Previte
f5a1e3a3fa
Update publish.yaml (#5490) 2022-08-23 08:29:22 -07:00
Joe Previte
6a7c3220b0
refactor(ci): combine publish workflows (#5471)
* refactor(ci): combine publish workflows

* fixup! refactor(ci): combine publish workflows
2022-08-19 08:40:00 -07:00
Joe Previte
9d8588b2ed
feat(ci): add aur job to npm-brew.yaml (#5462)
This adds a new job called aur which checkouts code-server-aur, updates
the files with the new version then opens a PR into the repo.

Co-authored-by: repo-ranger[bot] <39074581+repo-ranger[bot]@users.noreply.github.com>
2022-08-18 09:22:09 -07:00
renovate[bot]
61e2a9ac41
chore(deps): update aquasecurity/trivy-action digest to d63413b (#5473)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-18 01:38:36 +00:00
renovate[bot]
61673b5918
chore(deps): update aquasecurity/trivy-action digest to 1db49f5 (#5466)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-17 18:44:19 +00:00
renovate[bot]
bef78e6a41
chore(deps): update aquasecurity/trivy-action digest to 12814ff (#5460)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-16 00:17:22 +00:00
Joe Previte
3335d0a456
chore(ci): fix when npm job runs (#5440) 2022-08-10 11:43:28 -07:00
Joe Previte
f178f0400b
feat(e2e): add support running behind proxy (#5348)
* docs: update maintaining

* chore(e2e): add maxFailures to playwright

* fix(ci): skip submodule in e2e job

We don't need the submodules for the e2e job. This will speed up the
checkout step.

* feat(ci): add test-e2e-proxy job

This adds a new job to CI to run our tests behind Caddy and simulate
code-server running against a reverse-proxy.

* refactor: make e2e work with reverse proxy

This refactors the e2e test in a couple ways:
- remove setting cookie in localStorage (instead we pass --auth none)
- refactor address() method to account for reverse proxy logic

* Update test/e2e/models/CodeServer.ts

* Update test/playwright.config.ts

* Update test/utils/constants.ts

Co-authored-by: Asher <ash@coder.com>

* Update test/utils/helpers.ts

Co-authored-by: Asher <ash@coder.com>

Co-authored-by: Asher <ash@coder.com>
2022-08-09 18:24:37 +00:00
Joe Previte
45e222b3c1
chore(ci): run npm job on pr merge (#5429) 2022-08-09 10:31:23 -07:00
renovate[bot]
04ff8c355b
chore(deps): update dependency alpine to v3.16 (#5426)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-08 22:32:43 +00:00
Asher
9087e0c091
fix: invoking code-server in integrated terminal (#5360)
* Include bin scripts for all platforms

These will get symlinked as part of the postinstall.  These scripts
provide everything ours does inside the integrated terminal plus more.

* Improve OS detection

Specifically for Windows although we do not yet support Windows.

Also standardize the duplicate arch functions since they had drifted
from each other bit.

* Remove duplicate asar symlink

Since standalone releases run the postinstall they will get the asar
symlink there.  That means the symlink will not exist for the npm
package and we will not need to ignore it.

The symlink portion is split out so it can be re-used for other
symlinks (for example linking bin scripts).

* Add symlinks to bin scripts

* Add test for opening a file from the terminal

* Add global Playwright timeout

Otherwise it will exceed the Actions timeout and get rudely killed
without any output.

* Make sed work on macOS

* Fix Node path in bin scripts

* Disable shellcheck expansion error

* Make scripts executable

* Remove .bak files created by sed

* Include Code build script in cache hash

Otherwise if we change the script it will not rebuild Code.

* Make sure the terminal opens

The selector was timing out even though it matched more than one element
but matching on the focused one appears to work.

In addition add a loop so it can keep trying to open the terminal
if something goes wrong with the focus.
2022-08-04 16:03:28 +00:00
renovate[bot]
0022473744
chore(deps): update aquasecurity/trivy-action digest to 0d7cf2d (#5401)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-04 04:08:37 +00:00
renovate[bot]
f772d7bd13
chore(deps): update aquasecurity/trivy-action digest to 5144f05 (#5388)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-01 10:19:32 -05:00
renovate[bot]
23a84e156e
chore(deps): update minor dependency updates (#5377)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-27 12:44:52 -05:00
renovate[bot]
0e9ec02bef
chore(deps): update aquasecurity/trivy-action digest to 503d3ab (#5370)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-22 19:21:30 +00:00
Joe Previte
e79f6f3ad2
chore(ci): only run docs preview on docs changes (#5368) 2022-07-21 22:36:11 +00:00
renovate[bot]
40b650b7c7
chore(deps): update azure/setup-helm action to v3.1 (#5331)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-20 09:23:34 -07:00
Joe Previte
f4fc2ebecf
release: 4.5.1 (#5354)
* chore(release): bump version to 4.5.1

* chore: bump helm chart

* chore: update CHANGELOG

* Revert "chore: bump helm chart"

This reverts commit 703b03b665.

* chore: bump helm chart to 3.0.0

* revert: remove bad change to manifes.json icon

* fix(ci): add package.json.version to code cachekey

Before this, creating a release sometimes prevented vscode from
rebuilding and using the cache instead. Now we use the
package.json.version in the cache key to "bust" the cache if the
package.json version is updated (aka a release).

Fixes #5316

* Update .github/workflows/ci.yaml

Co-authored-by: Asher <ash@coder.com>

* fixup: formatting

* Revert "refactor: remove version check e2e test"

This reverts commit b23c398b7d.

Co-authored-by: Asher <ash@coder.com>
2022-07-19 12:34:01 -07:00
Joe Previte
23a18786de
refactor(ci): use release in branch release name (#5352) 2022-07-18 14:38:07 -07:00
renovate[bot]
55cfba8168
chore(deps): update aquasecurity/trivy-action digest to 0105373 (#5310)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-06-30 10:16:12 -07:00
renovate[bot]
79e96a99d3
chore(deps): update codecov/codecov-action action to v3 (#5305)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-06-29 08:55:44 -07:00
renovate[bot]
c99f4cef25
chore(deps): update azure/setup-helm action to v3 (#5302)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-06-28 12:57:29 -07:00
Joe Previte
1296848afc
refactor: switch to codecov-uploader GitHub Action (#5303)
* refactor: switch to codecov-uploader GitHub Action

codecov deprecated their Node wrapper for uploading coverage reports.

This removes that and uses their new uploaded along with the v2 GitHub
Action they maintain.

* fix: update broken integration test
2022-06-28 10:04:35 -07:00
Joe Previte
c51ff3bce1
refactor: move integration tests to Jest (#5275)
* feat: add installExtension integration test

This adds a new helper function called `runCodeServerCommand` along with
a test for `--install-extension`. We can use this approach for writing
integration tests (i.e. testing a real code-server build, CLI commands,
etc).

* refactor: s/ test:standalone with test:integration

This replaces our integration approach to use Jest instead of a single
bash script. By doing this, we will be able to easily maintain and add
to our integration test suite.

* refactor: filter unit tests

Now that our integration tests also use Jest, we need to update our unit
test script to ignore `test/integration`.

* refactor: add SKIP_SUBMODULE_DEPS to postinstall

* refactor: add SKIP_SUBMODULE_DEPS to postinstall

* fixup!: skip submod deps

* refactor: move runCodeServerCommand into sep. file

When Jest runs a test, it loads all the files and imports for that test.
This means you might be "requiring" code that's unrelated to your tests.

This leads to unexpected errors depending on where the code runs.

Moved this file to avoid GLIBC and other errors relaed to argon2 when
running integration tests in CI.

* fizup: formatting

* fizup: increase timeout

* refactor: use fixture in installExtension test

Instead of relying on a network to install an extension, we use a
fixture - vsix file in the repo. This is also faster.

* feat: add integration test for listExtensions

* chore: ignore integration fixtures

* fixup: formatting

* fixup: remove custom-hacks.css

* fixup: formatting

* Update test/integration/installExtension.test.ts

Co-authored-by: Asher <ash@coder.com>

* Update test/integration/listExtensions.test.ts

Co-authored-by: Asher <ash@coder.com>

* Update test/integration/installExtension.test.ts

Co-authored-by: Asher <ash@coder.com>

* Update test/integration/listExtensions.test.ts

Co-authored-by: Asher <ash@coder.com>

* fixup: contributing integration tests section

* fixup: update ci/readme

* fixup: use RELEASE_PATH in test-integration.sh

* refactor: unzip vsix for listExtensions

* refactor: use exec instead of spawn

* Update docs/CONTRIBUTING.md

Co-authored-by: Asher <ash@coder.com>

* Update test/integration/listExtensions.test.ts

Co-authored-by: Asher <ash@coder.com>

* Update test/integration/listExtensions.test.ts

Co-authored-by: Asher <ash@coder.com>

* Update test/integration/listExtensions.test.ts

Co-authored-by: Asher <ash@coder.com>

* refactor: use different default binary path

* fixup!: formatting

Co-authored-by: Asher <ash@coder.com>
2022-06-24 16:33:38 +00:00
renovate[bot]
a879844c2d
chore(deps): update aquasecurity/trivy-action digest to 7b7aa26 (#5289)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-06-22 20:05:22 +00:00
renovate[bot]
f2693d366c
chore(deps): update minor dependency updates (#5276)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Joe Previte <jjprevite@gmail.com>
2022-06-22 16:26:20 +00:00
Joe Previte
eb314ff727
chore: only download .deb in docker release (#5277)
* Update docker.yaml

* Update docker.yaml
2022-06-17 08:02:33 -07:00
renovate[bot]
113ad85b37
chore(deps): update minor dependency updates (#5244)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2022-06-15 13:29:52 -07:00
renovate[bot]
792e954937
chore(deps): update aquasecurity/trivy-action digest to df3fb7d (#5239)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2022-06-06 08:51:15 -07:00
Asher
5d47282ea5
fix: install nfpm straight from GitHub (#5214)
* fix: install nfpm straight from GitHub

install.goreleaser.com appears to no longer be available.

* Add -f to curl commands

This might have made it so we got the right error rather than erroring
on the envsubst step.
2022-05-20 12:39:54 -07:00
Devin Buhl
7a8d487729
chore: push code-server image to GHCR (#5187) 2022-05-10 16:11:06 -05:00
renovate[bot]
1788537cce
chore(deps): update minor dependency updates (#5181)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2022-05-10 21:01:13 +00:00
renovate[bot]
0155a12500
chore(deps): update docker/setup-qemu-action action to v2 (#5166)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Joe Previte <jjprevite@gmail.com>
2022-05-10 20:35:25 +00:00
renovate[bot]
53b5d41271
chore(deps): update docker/setup-buildx-action action to v2 (#5164)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Joe Previte <jjprevite@gmail.com>
2022-05-10 13:13:45 -07:00
renovate[bot]
55006ccb5a
chore(deps): update docker/login-action action to v2 (#5163)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2022-05-10 12:37:05 -07:00
Joe Previte
60dd8ab374
chore: configure git globally for brew publish (#5173) 2022-05-06 22:31:03 +00:00
Asher
6cf607eab9
fix: Docker push (#5175)
The action actually does not support wildcards but it does support * for
downloading all artifacts.
2022-05-06 16:57:22 -05:00
Joe Previte
7027ec7d60
chore: upgrade Code to 1.66 (#5135)
* chore: upgrade Code to 1.66

* docs: update docs for Code upgrades

* fixup!: docs

* chore: update vscode submodule

* chore: update integration patch

* chore: update node-version patch

* chore: update github-auth patch

They completely changed how auth is handled for GitHub in
https://github.com/microsoft/vscode/pull/145424 so our patch may not
work. Will need to test and revisit.

* refactor: remove postinstall patch

It appears they renamed postinstall.js to postinstall.mjs and removed
the use of `rimraf` which means our patch is no longer needed! 🎉

b0e8554cce

* chore: refresh local-storage patch

* chore: refresh service-worker patch

* chore: bulk refresh patches

* fixup!: docs formatting

* refactor: remove unused last-opened patch

* fixup!: formatting docs

* fixup!: formatting docs

* refactor: remove rsync postinstall

* Revert "refactor: remove rsync postinstall"

This reverts commit 8d6b613e9d.

* refactor: update postinstall.js to .mjs

* feat(patches): add parent-origin bypass

* docs(patches): add notes for testing store-socket

* docs(patches): update testing info for node-version

* refactor(patches): delete github-auth.diff patch

* docs(patches): add notes for testing connection-type

* fixup!: delete github-auth patch

* fixup!: update connection type testing

* docs(patches): add notes to insecure-notification.diff

* docs(patches): add nots for update-check.diff

* fixup!: remove comma in integration patch

* fix(e2e): disable workspace trust

* refactor: add --no-default-rc for yarn install

* feat(patches): remove yarnrc in presinstall

* fixup!: silly mistake

* docs: add note about KEEP_MODULES=1

* docs(patches): add testing notes for node-version

* refactor(patches): remove node-version

It appears this is no longer needed due to the `remote/package.json` now which
targets node rather than electron.

* fixup!: add cd ../.. to code upgrade instructions

* fixup!: add note to yarn --production flag

* fixup!: make parent-origin easier to upstream

* Revert "refactor(patches): delete github-auth.diff patch"

This reverts commit 31a354a343.

* Revert "fixup!: delete github-auth patch"

This reverts commit bdeb5212e8.

* Merge webview origin patch into webview patch

* Remove unused post-install patch

* Prevent builtin extensions from updating

* Refresh sourcemaps patch

* Update Node to v16

This matches the version in ./lib/vscode/remote/.yarnrc.

I changed the engine to exactly 16 since if you use any different
version it will just not work since the modules will have been built for
16 (due to the .yarnrc).

* Replace fs.rmdir with fs.rm

Node is showing a deprecation warning about it.

* Update github-auth patch

The local credentials provider is no longer used when there is a remote
so this code moved into the backend web credential provider.

* Prevent fs.rm from erroring about non-existent files

We were using fs.rmdir which presumably did not have the same behavior
in v14 (in v16 fs.rmdir also errors).

* Install Python 3 in CentOS CI container

Co-authored-by: Asher <ash@coder.com>
2022-05-04 21:58:49 +00:00
renovate[bot]
fc75db6edc
chore(deps): update azure/setup-helm action to v2 (#5088)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Joe Previte <jjprevite@gmail.com>
2022-04-26 21:48:39 +00:00
renovate[bot]
ed7bd2e65b
chore(deps): update github/codeql-action action to v2 (#5129)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2022-04-25 15:39:32 -07:00
renovate[bot]
7780a13cce
chore(deps): update aquasecurity/trivy-action digest to 2b30463 (#5098)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2022-04-19 11:37:47 -07:00
Joe Previte
dea6a40ea8
chore: attempt to fix docker (#5106)
* chore: attempt to fix docker

* Update .github/workflows/docker.yaml

Co-authored-by: Asher <ash@coder.com>

* chore: add publish:docker to scripts

Co-authored-by: Asher <ash@coder.com>
2022-04-15 00:02:03 +00:00
renovate[bot]
c05b727c61
chore(deps): update minor dependency updates (#5060)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Joe Previte <jjprevite@gmail.com>
2022-04-12 16:39:58 -07:00
neilnaveen
f4569f0b48
Set permissions for GitHub actions (#5090)
- Included permissions for the action. https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions

https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions

https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs

[Keeping your GitHub Actions and workflows secure Part 1: Preventing pwn requests](https://securitylab.github.com/research/github-actions-preventing-pwn-requests/)

 Restrict the GitHub token permissions only to the required ones; this way, even if the attackers will succeed in compromising your workflow, they won’t be able to do much.

Signed-off-by: neilnaveen <42328488+neilnaveen@users.noreply.github.com>

Co-authored-by: Joe Previte <jjprevite@gmail.com>
2022-04-12 18:59:11 +00:00
Joe Previte
7f884203f0
chore(ci): disable docs-preview on forks (#5046) 2022-03-30 13:45:35 -07:00
Joe Previte
5341294d2d
fix(workflows): docs-preview and npm job (#5042)
* fix(ci): add GITHUB_TOKEN to docs-preview workflow

* feat(ci): comment npm dev build instructions on PR
2022-03-30 10:47:46 -07:00
Joe Previte
8316a27da4
refactor(brew-bump): fix homebrew bump script (#5025)
* fix: source lib.sh in docker-buildx-push for tagging version

* chore: use ubuntu and update git config homebrew job

* refactor: simplify brew-bump.sh script

* Revert "fix: source lib.sh in docker-buildx-push for tagging version"

This reverts commit 2f7a3610cb.
2022-03-29 16:58:34 -07:00
Joe Previte
ba1ddbd181
fix: use -r with jq and add workflow for artifacts (#5016) 2022-03-22 16:45:59 -07:00
Asher
a1af9e2a56
chore: move to patches (#4997)
* Move integration types into code-server

This will be easier to maintain than to have it as a patch.

* Disable connection token

Using a flag means we will not need to patch it out.  I think this is
new from 1.64?

* Add product.json to build process

This way we do not have to patch it.

* Ship with remote agent package.json

Instead of the root one.  This contains fewer dependencies.

* Let Code handle errors

This way we will not have to patch Code to make this work and I think it
makes sense to let Code handle the request.

If we do want to handle errors we can do it cleanly by patching their
error handler to throw instead.

* Move manifest override into code-server

This way we will not have to patch it.

* Move to patches

- Switch submodule to track upstream
- Add quilt to the process
- Add patches

The node-* ignore was ignoring one of the diffs so I removed it.  This
was added when we were curling Node as node-v{version}-darwin-x64 for
the macOS build but this no longer happens (we use the Node action to
install a specific version now so we just use the system-wide Node).

* Use pre-packaged Code
2022-03-22 15:07:14 -05:00
Joe Previte
be727871f6
refactor: checkout homebrew-core in action instead of script (#4996)
* refactor: checkout homebrew-core in action instead of script

This moves the git clone step from the `brew-bump.sh` script into the
`npm-brew.yaml` as part of the job using actions/checkout instead.

* refactor: clean up brew-bump.sh script

* fixup

* fixup!: remove step to clean up homebrew repo

* fixup!: use correct ./ci path steps-lib.sh

* fixup!: add exit code 0 for duplicate PRs
2022-03-21 16:57:36 -07:00
renovate[bot]
815c4cf1f0
chore(deps): update actions/cache action to v3 (#5003)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2022-03-21 14:31:02 -07:00
Joe Previte
5afb26fb60
fix(ci): correctly download npm/docker artifacts (#4995)
* fix(ci): correctly download npm artifact

* fixup! fix(ci): correctly download npm artifact

* docs: update MAINTAINING

* fixup! docs: update MAINTAINING

* fixup! Merge branch 'main' into 4949-chore-fix-npm-workflow

* chore: get ci to run

* refactor: use vVERSION branch name instead of release

* refactor: use new download artifact in docker workflow

* refactor: clean up release-github-assets script

* fixup: remove extra v

* fixup! fixup: remove extra v
2022-03-17 11:52:39 -07:00
Asher
21c74802e8
chore: move Code to a submodule (#4990)
* Move Code to a submodule

Closes #4901.

* Base Code cache on hash and re-enable node_modules cache

The current setup appears to only rebuild VS Code if the dependencies
change but we need to rebuild it if anything changes.

I also re-enabled the commented out node_modules caches.  They look like
they should work to me with the submodule method.  I think the problem
occurred because Code itself was being installed in the yarn step.
2022-03-14 21:37:29 -05:00
Bruno Quaresma
52eaea9f7a
docs: update docs preview (#4968)
* docs: update docs preview

* Fix Ubuntu  deps

* Fix formatting
2022-03-10 13:44:27 -07:00
Joe Previte
03e0bdac03
chore: update vscode to 1.64 (#4902)
* chore: update vscode server files

* chore: update code to 1.64

* refactor: clean up code in constants.ts

* chore: keep package.json vscode cache

* fixup!: formatting

* feat(ci): add VSCODE_CACHE_VERSION

* fix(ci): add package.json for e2e tests

* fix: TS errors

* refactor: remove isConnected e2e tests
2022-03-09 14:28:52 -07:00
Joe Previte
3b93a86f25
chore: add permissions trivy-docker (#4957)
* chore: add permissions trivy-docker

* Update .github/workflows/trivy-docker.yaml
2022-03-08 13:19:57 -07:00
Joe Previte
3c6f85c282
fix: re-enable trivvy docker scan (#4943)
* fix: re-enable trivvy docker scan

* wip

* fixup

* fixup

* fixup
2022-03-04 15:59:29 -07:00
renovate[bot]
f0faa22ee9
chore(deps): update actions/upload-artifact action to v3 (#4944)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2022-03-04 09:25:12 -07:00
renovate[bot]
b0181120d4
chore(deps): update actions/download-artifact action to v3 (#4937)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2022-03-02 14:31:21 -07:00
renovate[bot]
3f3a489f33
chore(deps): update actions/checkout action to v3 (#4931)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Jonathan Yu <jonathan@coder.com>
2022-03-01 16:31:32 -07:00
Jonathan Yu
83269ba658
chore: limit concurrency for build jobs (#4929)
* Configure build jobs to cancel previous builds when new changes
  are pushed to a pull request branch, and serialize builds when
  running in a branch from a push event
* Reduce privileges of GitHub token for scripts workflow
2022-03-01 15:03:39 -08:00
renovate[bot]
a989e0c387
chore(deps): update aquasecurity/trivy-action commit hash to 2962126 (#4907)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2022-02-25 13:53:58 -07:00
renovate[bot]
769aceacc3
chore(deps): update actions/setup-node action to v3 (#4908)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2022-02-25 09:09:09 -07:00
Joe Previte
23734d356a
fix: skip docs/npm workflows on forks (#4875)
Co-authored-by: Asher <ash@coder.com>
2022-02-22 10:13:20 -07:00
Jonathan Yu
8135d2ecc3
chore: update Docker image publish workflow (#4847)
* Use official action to log in to Docker Hub
* Run using pinned ubuntu-20.04 environment
2022-02-10 17:40:41 -08:00