Compare commits

..

29 Commits

Author SHA1 Message Date
Joe Previte
8ed7498b3c fixup: include description ts-expect-error comment 2022-12-06 08:55:24 -07:00
Joe Previte
73b61ecfb6 feat(wrapper): add tests for isChild 2022-12-05 16:11:45 -07:00
Joe Previte
292a63dccd Merge branch 'main' into release/v4.9.0 2022-12-05 15:43:33 -07:00
Pfau, Sascha
f43082e142 fix installing code-server on manjaro image (#5834)
Co-authored-by: Joe Previte <jjprevite@gmail.com>
2022-12-05 15:43:22 -07:00
Geoffrey Huntley
b6adcf50c6 feat(securitytxt): add security.txt (#5827) 2022-12-05 15:43:00 -07:00
Joe Previte
60ab23f008 chore: pin all jobs in build to ubuntu 20.04 2022-12-05 15:41:08 -07:00
Joe Previte
40396cc810 chore: use ubuntu-22.04 for e2e 2022-12-02 15:20:36 -07:00
Joe Previte
0c7a60e407 chore: add notes to changelog 2022-12-02 13:56:17 -07:00
Joe Previte
e701b74952 chore: update prettierignore 2022-12-02 13:56:10 -07:00
Joe Previte
c761199923 chore: pin ubuntu runner in build code-server 2022-12-02 13:48:55 -07:00
Joe Previte
956ed96a2c Revert "fix: add +x to product.json in build-vscode"
This reverts commit fc4d2b532f.
2022-12-02 13:44:13 -07:00
Joe Previte
2b32b10e87 fixup!: fix: keep product.json file permissions in release 2022-12-02 13:42:37 -07:00
Joe Previte
ace09103a2 chore: update package.json bust cache 2022-12-02 11:31:53 -07:00
Joe Previte
f7db2a0dd8 trigger ci 2022-12-02 11:25:57 -07:00
Joe Previte
0f66360646 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`.
2022-12-02 11:03:20 -07:00
Joe Previte
130f52e6b7 chore: increase timeout 2022-12-01 12:28:58 -07:00
Joe Previte
c9279ccbe4 Merge branch 'main' into release/v4.9.0 2022-12-01 11:07:47 -07:00
Joe Previte
fc4d2b532f 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.
2022-12-01 10:19:47 -07:00
Joe Previte
df49838739 chore: add VERSION check in build-vscode.sh (#5823) 2022-12-01 11:51:07 -05:00
Joe Previte
9efbd2d59c Merge branch 'main' into release/v4.9.0 2022-11-30 12:36:16 -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
Geoffrey Huntley
43e8c439bf housekeeping(branding): update coder/coder branding (#5781) 2022-11-14 12:28:42 -06:00
Joe Previte
ccf882f830 Merge branch 'main' into release/v4.9.0 2022-11-10 13:49:07 -07:00
Joe Previte
74edfe7c43 chore: fix typo in release.yaml (#5774) 2022-11-10 13:48:56 -07:00
Joe Previte
96b3c3e024 Merge branch 'main' into release/v4.9.0 2022-11-10 12:46:39 -07:00
Joe Previte
69d469b714 chore: update Code to 1.73.1 (#5769) 2022-11-10 12:46:21 -07:00
Joe Previte
17d41135f3 fixup 2022-11-10 11:51:50 -07:00
Joe Previte
9694242b2f wip: changelog 2022-11-10 11:51:50 -07:00
Joe Previte
e2f585f368 docs: add --edge to install section (#5767)
This adds documentation for the flag `--edge` which we've had for a
while but forgot to document.

Fixes #5717

Co-authored-by: repo-ranger[bot] <39074581+repo-ranger[bot]@users.noreply.github.com>
2022-11-10 11:50:37 -07:00
16 changed files with 65 additions and 21 deletions

View File

@@ -24,7 +24,7 @@ concurrency:
jobs:
prettier:
name: Format with Prettier
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
timeout-minutes: 5
steps:
- name: Checkout repo
@@ -37,7 +37,7 @@ jobs:
doctoc:
name: Doctoc markdown files
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
timeout-minutes: 5
steps:
- name: Checkout repo
@@ -66,7 +66,7 @@ jobs:
lint-helm:
name: Lint Helm chart
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
timeout-minutes: 5
steps:
- name: Checkout repo
@@ -97,7 +97,7 @@ jobs:
lint-ts:
name: Lint TypeScript files
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
timeout-minutes: 5
steps:
- name: Checkout repo
@@ -141,7 +141,7 @@ jobs:
build:
name: Build code-server
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
timeout-minutes: 30
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
@@ -244,7 +244,7 @@ jobs:
# Only run if PR comes from base repo or event is not a PR
# Reason: forks cannot access secrets and this will always fail
if: github.event.pull_request.head.repo.full_name == github.repository || github.event_name != 'pull_request'
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
steps:
- name: Checkout repo
uses: actions/checkout@v3
@@ -295,8 +295,8 @@ jobs:
test-e2e:
name: Run e2e tests
needs: build
runs-on: ubuntu-latest
timeout-minutes: 15
runs-on: ubuntu-20.04
timeout-minutes: 25
steps:
- name: Checkout repo
uses: actions/checkout@v3
@@ -351,7 +351,7 @@ jobs:
test-e2e-proxy:
name: Run e2e tests behind proxy
needs: build
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
timeout-minutes: 25
steps:
- name: Checkout repo

View File

@@ -41,7 +41,7 @@ jobs:
alpine:
name: Test installer on Alpine
runs-on: ubuntu-latest
container: "alpine:3.16"
container: "alpine:3.17"
steps:
- name: Checkout repo
uses: actions/checkout@v3

View File

@@ -314,7 +314,7 @@ jobs:
- name: Modify version
env:
VERSION: ${{ env.VERSION )}}
VERSION: ${{ env.VERSION }}
run: |
echo "Updating version in root package.json"
npm version --prefix release "$VERSION"
@@ -322,6 +322,8 @@ jobs:
echo "Updating version in lib/vscode/product.json"
tmp=$(mktemp)
jq '.codeServerVersion = "$VERSION"' release/lib/vscode/product.json > "$tmp" && mv "$tmp" release/lib/vscode/product.json
# Ensure it has the same permissions as before
chmod 644 release/lib/vscode/product.json
- name: Compress release package
run: tar -czf package.tar.gz release

View File

@@ -38,7 +38,7 @@ jobs:
name: Run script unit tests
runs-on: ubuntu-latest
# This runs on Alpine to make sure we're testing with actual sh.
container: "alpine:3.16"
container: "alpine:3.17"
steps:
- name: Checkout repo
uses: actions/checkout@v3

View File

@@ -1,6 +1,7 @@
lib/vscode
lib/vscode-reh-web-linux-x64
release-standalone
release-packages
release
helm-chart
test/scripts

View File

@@ -26,6 +26,8 @@ Code v1.73.0
WIP
known issues: https://github.com/adobe/fetch/pull/318#issuecomment-1306070259
cert won't work for anyone using Ubuntu 22.04
## [4.8.3](https://github.com/coder/code-server/releases/tag/v4.8.3) - 2022-11-07

View File

@@ -42,6 +42,12 @@ main() {
pushd lib/vscode
if [[ ! ${VERSION-} ]]; then
echo "VERSION not set. Please set before running this script:"
echo "VERSION='0.0.0' yarn build:vscode"
exit 1
fi
# Set the commit Code will embed into the product.json. We need to do this
# since Code tries to get the commit from the `.git` directory which will fail
# as it is a submodule.

View File

@@ -59,6 +59,7 @@ following flags:
- `--prefix=/usr/local`: install a standalone release archive system-wide.
- `--version=X.X.X`: install version `X.X.X` instead of latest version.
- `--help`: see usage docs.
- `--edge`: install the latest edge version (i.e. pre-release)
When done, the install script prints out instructions for running and starting
code-server.

View File

@@ -387,7 +387,7 @@ install_aur() {
if [ ! "${DRY_RUN-}" ]; then
cd "$CACHE_DIR/code-server-aur"
fi
sh_c makepkg -si
sh_c makepkg -si --noconfirm
echo_systemd_postinstall AUR
}

View File

@@ -61,7 +61,7 @@
"eslint-import-resolver-typescript": "^3.5.2",
"eslint-plugin-import": "^2.26.0",
"eslint-plugin-prettier": "^4.2.1",
"prettier": "2.7.1",
"prettier": "2.8.0",
"prettier-plugin-sh": "^0.12.8",
"ts-node": "^10.0.0",
"typescript": "^4.6.2"
@@ -116,7 +116,8 @@
"ide",
"coder",
"vscode-remote",
"browser-ide"
"browser-ide",
"remote-development"
],
"engines": {
"node": "16"

View File

@@ -55,7 +55,7 @@ Index: code-server/lib/vscode/src/vs/workbench/contrib/welcomeGettingStarted/bro
+ 'font-size: 13px',
+ 'color: #dcdee2',
+ ].join(';'),
+ }, 'Provision remote development environments on your infrastructure with Coder.'),
+ }, 'Provision software development environments on your infrastructure with Coder.'),
+ $('p', {
+ style: [
+ 'margin-top: 8px',

6
src/browser/security.txt Normal file
View File

@@ -0,0 +1,6 @@
Contact: mailto:security@coder.com
Acknowledgments: https://coder.com/security/thanks
Preferred-Languages: en-US
Canonical: https://coder.com/.well-known/security.txt
Policy: https://coder.com/security/policy
Hiring: https://coder.com/careers

View File

@@ -81,6 +81,13 @@ export const register = async (app: App, args: DefaultedArgs): Promise<Disposabl
return res.redirect(`https://${req.headers.host}${req.originalUrl}`)
}
// Return security.txt.
if (req.originalUrl === "/security.txt" || req.originalUrl === "/.well-known/security.txt") {
const resourcePath = path.resolve(rootPath, "src/browser/security.txt")
res.set("Content-Type", getMediaMime(resourcePath))
return res.send(await fs.readFile(resourcePath))
}
// Return robots.txt.
if (req.originalUrl === "/robots.txt") {
const resourcePath = path.resolve(rootPath, "src/browser/robots.txt")

View File

@@ -0,0 +1,18 @@
import { ChildProcess } from "child_process"
import { ParentProcess, isChild } from "../../../src/node/wrapper"
describe("wrapper", () => {
describe("isChild", () => {
it("should return false for parent process", () => {
const p = new ParentProcess("1")
expect(isChild(p)).toBe(false)
})
})
it("should return false for parent process", () => {
const p = new ChildProcess()
// our ChildProcess isn't exported
// and shouldn't be for a test so surpressing TS error.
// @ts-expect-error - see above
expect(isChild(p)).toBe(false)
})
})

View File

@@ -2775,10 +2775,10 @@ prettier-plugin-sh@^0.12.8:
sh-syntax "^0.3.6"
synckit "^0.8.1"
prettier@2.7.1:
version "2.7.1"
resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.7.1.tgz#e235806850d057f97bb08368a4f7d899f7760c64"
integrity sha512-ujppO+MkdPqoVINuDFDRLClm7D78qbDt0/NR+wp5FqEZOoTNAjPHWj17QRhu7geIHJfcNhRk1XVQmF8Bp3ye+g==
prettier@2.8.0:
version "2.8.0"
resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.8.0.tgz#c7df58393c9ba77d6fba3921ae01faf994fb9dc9"
integrity sha512-9Lmg8hTFZKG0Asr/kW9Bp8tJjRVluO8EJQVfY2T7FMw9T5jy4I/Uvx0Rca/XWf50QQ1/SS48+6IJWnrb+2yemA==
proxy-addr@~2.0.5:
version "2.0.6"