-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #465 from nocalhost/dev
Release v0.6.16
- Loading branch information
Showing
178 changed files
with
13,341 additions
and
25,267 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,33 +12,41 @@ jobs: | |
name: build test plugin | ||
runs-on: macos-10.15 | ||
steps: | ||
- name: Set up Node 1.x | ||
uses: actions/[email protected] | ||
- uses: actions/setup-node@v2 | ||
with: | ||
node-version: 12.x | ||
node-version: ^14 | ||
|
||
- uses: pnpm/[email protected] | ||
with: | ||
version: 6 | ||
run_install: false | ||
|
||
- name: Check out code into the project's root directory | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- uses: actions/cache@v2 | ||
id: yarn-cache | ||
id: pnpm-cache | ||
with: | ||
path: "**/node_modules" | ||
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-yarn- | ||
key: ${{ runner.os }}-build-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: ${{ runner.os }}-build | ||
|
||
- name: Install project dependencies | ||
if: steps.yarn-cache.outputs.cache-hit != 'true' | ||
run: yarn | ||
- uses: pnpm/[email protected] | ||
if: steps.pnpm-cache.outputs.cache-hit != 'true' | ||
with: | ||
version: 6 | ||
run_install: | | ||
- recursive: true | ||
args: [--frozen-lockfile] | ||
- args: [--no-optional] | ||
- name: Build | ||
env: | ||
MINIMUNM_VERSION_REQUIREMENT: ${{ secrets.MINIMUNM_VERSION_REQUIREMENT }} | ||
run: | | ||
yarn build | ||
mv nocalhost-*.vsix nocalhost.vsix | ||
run: pnpm build | ||
|
||
- name: Push to Coding Artifacts | ||
if: ${{ github.ref != 'refs/heads/dev' }} | ||
run: | | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,6 +4,7 @@ on: | |
push: | ||
tags: | ||
- "v*" | ||
workflow_dispatch: | ||
|
||
jobs: | ||
release-plugin: | ||
|
@@ -12,25 +13,42 @@ jobs: | |
environment: | ||
name: release | ||
steps: | ||
- name: Set up Node 1.x | ||
uses: actions/[email protected] | ||
- uses: actions/setup-node@v2 | ||
with: | ||
node-version: 12.x | ||
node-version: ^14 | ||
|
||
- uses: pnpm/[email protected] | ||
with: | ||
version: 6 | ||
run_install: false | ||
|
||
- name: Check out code into the project's root directory | ||
uses: actions/checkout@v2 | ||
|
||
- uses: actions/cache@v2 | ||
id: pnpm-cache | ||
with: | ||
path: "**/node_modules" | ||
key: ${{ runner.os }}-build-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: ${{ runner.os }}-build | ||
|
||
- uses: pnpm/[email protected] | ||
if: steps.pnpm-cache.outputs.cache-hit != 'true' | ||
with: | ||
version: 6 | ||
run_install: | | ||
- recursive: true | ||
args: [--frozen-lockfile] | ||
- args: [--no-optional] | ||
- name: Get tag | ||
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV | ||
|
||
- name: build | ||
env: | ||
VERSION: ${{ env.RELEASE_VERSION }} | ||
MINIMUNM_VERSION_REQUIREMENT: ${{ secrets.MINIMUNM_VERSION_REQUIREMENT }} | ||
run: | | ||
yarn install | ||
yarn build | ||
mv nocalhost-*.vsix nocalhost.vsix | ||
run: pnpm build | ||
|
||
- name: Create nocalhost-vscode-plugin Release | ||
id: create_release | ||
|
@@ -54,7 +72,7 @@ jobs: | |
asset_content_type: application/octet-stream | ||
|
||
- name: Publish To VS Code Extension Marketplace | ||
run: yarn run vsce publish -p ${{ secrets.VSCE_TOKEN }} | ||
run: pnpm vsce publish -p ${{ secrets.VSCE_TOKEN }} --no-dependencies | ||
|
||
- name: Publish openVSX | ||
run: yarn run ovsx publish nocalhost.vsix -p ${{ secrets.OPEN_VSX_ACCESS_TOKEN }} | ||
run: pnpm dlx ovsx publish nocalhost.vsix -p ${{ secrets.OPEN_VSX_ACCESS_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,17 +12,28 @@ jobs: | |
strategy: | ||
matrix: | ||
os: [ubuntu-latest] | ||
node: [12] | ||
steps: | ||
- name: Install node.js | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: ${{ matrix.node }} | ||
- name: Check out the repository | ||
uses: actions/checkout@v2 | ||
- name: Install node modules | ||
run: | | ||
npm i -g yarn | ||
yarn install | ||
|
||
- uses: actions/setup-node@v2 | ||
with: | ||
node-version: ^14 | ||
|
||
- uses: actions/cache@v2 | ||
id: pnpm-cache | ||
with: | ||
path: "**/node_modules" | ||
key: ${{ runner.os }}-ui-test-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: ${{ runner.os }}-ui-test | ||
|
||
- uses: pnpm/[email protected] | ||
if: steps.pnpm-cache.outputs.cache-hit != 'true' | ||
with: | ||
version: 6 | ||
run_install: | | ||
- recursive: true | ||
args: [--frozen-lockfile] | ||
- name: Run tests | ||
run: npm run test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ on: | |
pull_request: | ||
branches: [dev, main] | ||
push: | ||
branches: [test/vscode-puppeteer] | ||
branches: [test/vcluster] | ||
jobs: | ||
test: | ||
strategy: | ||
|
@@ -16,32 +16,32 @@ jobs: | |
name: Run UI Tests | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- name: Create cluster | ||
env: | ||
TKE_SECRET_ID: ${{ secrets.TKE_SECRET_ID }} | ||
TKE_SECRET_KEY: ${{ secrets.TKE_SECRET_KEY }} | ||
run: | | ||
curl -fL "https://nocalhost-generic.pkg.coding.net/nocalhost-test/binary/tketools?version=latest" -o ~/cluster | ||
chmod +x ~/cluster | ||
~/cluster create &> ~/cluster.log & | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- uses: actions/setup-node@v2 | ||
with: | ||
node-version: ^14 | ||
|
||
- uses: pnpm/[email protected] | ||
with: | ||
version: 6 | ||
run_install: false | ||
|
||
- uses: actions/cache@v2 | ||
id: yarn-cache | ||
id: pnpm-cache | ||
with: | ||
path: "**/node_modules" | ||
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-yarn- | ||
key: ${{ runner.os }}-ui-test-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: ${{ runner.os }}-ui-test | ||
|
||
- name: Install project dependencies | ||
if: steps.yarn-cache.outputs.cache-hit != 'true' | ||
run: yarn | ||
- uses: pnpm/[email protected] | ||
if: steps.pnpm-cache.outputs.cache-hit != 'true' | ||
with: | ||
version: 6 | ||
run_install: | | ||
- args: [--frozen-lockfile] | ||
# - name: Run tests | ||
# uses: GabrielBB/[email protected] | ||
|
@@ -55,59 +55,48 @@ jobs: | |
MINIMUNM_VERSION_REQUIREMENT: ${{ secrets.MINIMUNM_VERSION_REQUIREMENT }} | ||
NHCTL_VERSION: dev | ||
run: | | ||
yarn run build:ext | ||
pnpm run build:test | ||
rm -rf .vscode-test | ||
ls -al | ||
- name: Wait cluster ready | ||
timeout-minutes: 30 | ||
run: >- | ||
while [ ! -f "${HOME}/config" ];do | ||
tail -n 3 ~/cluster.log | ||
sleep 10s; | ||
done | ||
- name: Set kubeconfig | ||
run: | | ||
NOCALHOST_KUBECONFIG=$(cat ~/config) | ||
echo "NOCALHOST_KUBECONFIG<<EOF" >> $GITHUB_ENV | ||
echo "$NOCALHOST_KUBECONFIG" >> $GITHUB_ENV | ||
echo "EOF" >> $GITHUB_ENV | ||
echo "::add-mask::$NOCALHOST_KUBECONFIG" | ||
- name: Create cluster | ||
uses: zhangjian10/nocalhost-server-cli@latest | ||
with: | ||
host: ${{ secrets.NOCALHOST_VCLUSTER_HOST_FOR_TEST }} | ||
email: ${{ secrets.NOCALHOST_VCLUSTER_EMAIL_FOR_TEST }} | ||
password: ${{ secrets.NOCALHOST_VCLUSTER_PASSWORD_FOR_TEST }} | ||
action: devSpace.create | ||
|
||
- name: Run tests | ||
timeout-minutes: 20 | ||
env: | ||
CYPRESS_EVERY_NTH_FRAME: 1 | ||
# LOGGER_LEVEL: DEBUG | ||
run: yarn run test:ext | ||
|
||
# - name: Destroy cluster | ||
# if: ${{ always() }} failure | ||
# env: | ||
# TKE_SECRET_ID: ${{ secrets.TKE_SECRET_ID }} | ||
# TKE_SECRET_KEY: ${{ secrets.TKE_SECRET_KEY }} | ||
# run: ~/cluster destroy | ||
VIDEO_CAPTURE: 1 | ||
run: pnpm run test:ext | ||
|
||
- name: Artifact screenshot | ||
if: ${{ always() }} | ||
run: mv .screenshot ~/.nh/screenshot | ||
run: | | ||
mkdir -p ~/.nh/screenshot | ||
mv .screenshot/*.jpeg ~/.nh/screenshot | ||
cp ~/.kube/config ~/.nh | ||
- uses: actions/upload-artifact@v2 | ||
if: ${{ always() }} | ||
with: | ||
name: artifact-${{ runner.os }}-${{ github.run_id }} | ||
path: | | ||
~/.nh/screenshot | ||
~/.nh/nhctl/ns | ||
~/.nh/nhctl/logs/nhctl.log | ||
~/.nh/vscode-plugin/vsc_log | ||
- name: Artifact dependency | ||
if: ${{ failure() }} | ||
run: | | ||
mkdir .dependency | ||
mv .screenshot/*.mp4 .dependency/ | ||
cp ~/.nh/bin/nhctl .dependency/ | ||
cp nocalhost.vsix .dependency/ | ||
cp ~/config .dependency/ | ||
- uses: actions/upload-artifact@v2 | ||
if: ${{ failure() }} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.