Skip to content

Commit 101732e

Browse files
authored
Merge pull request #730 from kuzzleio/beta
Beta
2 parents d9660d3 + 5b8ad65 commit 101732e

File tree

155 files changed

+12922
-112699
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

155 files changed

+12922
-112699
lines changed

.ci/test-docs.sh

Lines changed: 0 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -9,53 +9,3 @@ docker-compose -f ./doc/docker-compose.yml pull
99
docker-compose -f ./doc/docker-compose.yml run doc-tests node index
1010
EXIT=$?
1111
docker-compose -f ./doc/docker-compose.yml down
12-
13-
docker-compose -f ./doc/docker-compose.yml up -d kuzzle
14-
15-
until $(curl --output /dev/null --silent --head --fail http://localhost:7512); do
16-
printf '.'
17-
sleep 5
18-
done
19-
20-
cd ${here}/../doc/7/getting-started/.react/with-redux
21-
npm ci
22-
SKIP_PREFLIGHT_CHECK=true npm run start &
23-
until $(curl --output /dev/null --silent --head --fail http://localhost:3000); do
24-
printf '.'
25-
sleep 5
26-
done
27-
npm run test
28-
kill $(lsof -t -i:3000)
29-
30-
cd ${here}/../doc/7/getting-started/.react/standalone
31-
npm ci
32-
SKIP_PREFLIGHT_CHECK=true npm run start &
33-
until $(curl --output /dev/null --silent --head --fail http://localhost:3000); do
34-
printf '.'
35-
sleep 5
36-
done
37-
npm run test
38-
39-
cd ${here}/../doc/7/getting-started/.vuejs
40-
npm ci
41-
npm run serve-standalone &
42-
until $(curl --output /dev/null --silent --head --fail http://localhost:8080); do
43-
printf '.'
44-
sleep 5
45-
done
46-
npm run test
47-
48-
cd ${here}/../doc/7/getting-started/.react-native
49-
# Here we use install instead of ci because expo-cli cannot be installed with ci
50-
npm install
51-
npm run web &
52-
until $(curl --output /dev/null --silent --head --fail http://localhost:19006); do
53-
printf '.'
54-
sleep 5
55-
done
56-
npm run test
57-
58-
cd ${here}
59-
docker-compose -f ./doc/docker-compose.yml down
60-
61-
exit $EXIT

.commitlintrc.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"extends": ["@commitlint/config-conventional"]
3+
}

.cz.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"path": "./node_modules/cz-conventional-changelog"
3+
}

.github/actions/tests-ac/action.yml

Lines changed: 0 additions & 43 deletions
This file was deleted.

.github/workflows/pull_request.workflow.yml

Lines changed: 32 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,14 @@ on: [pull_request]
55
jobs:
66
lint:
77
name: Lint
8-
runs-on: ubuntu-22.04
8+
runs-on: ubuntu-20.04
9+
strategy:
10+
matrix:
11+
node-version: ["16", "18"]
912
steps:
10-
- uses: actions/checkout@v2
13+
- uses: actions/checkout@v3
1114
- name: Cache node modules
12-
uses: actions/cache@v2
15+
uses: actions/cache@v3
1316
env:
1417
cache-name: cache-node-modules
1518
with:
@@ -19,19 +22,22 @@ jobs:
1922
${{ runner.os }}-build-${{ env.cache-name }}-
2023
${{ runner.os }}-build-
2124
${{ runner.os }}-
22-
- uses: actions/setup-node@v2
25+
- uses: actions/setup-node@v3
2326
with:
24-
node-version: "14"
27+
node-version: ${{ matrix.node-version }}
2528
- uses: ./.github/actions/es-lint
2629

2730
unit-tests:
2831
name: Unit Tests
29-
runs-on: ubuntu-22.04
32+
runs-on: ubuntu-20.04
3033
needs: [lint]
34+
strategy:
35+
matrix:
36+
node-version: ["16", "18"]
3137
steps:
32-
- uses: actions/checkout@v2
38+
- uses: actions/checkout@v3
3339
- name: Cache node modules
34-
uses: actions/cache@v2
40+
uses: actions/cache@v3
3541
env:
3642
cache-name: cache-node-modules
3743
with:
@@ -41,21 +47,24 @@ jobs:
4147
${{ runner.os }}-build-${{ env.cache-name }}-
4248
${{ runner.os }}-build-
4349
${{ runner.os }}-
44-
- uses: actions/setup-node@v2
50+
- uses: actions/setup-node@v3
4551
with:
46-
node-version: "14"
52+
node-version: ${{ matrix.node-version }}
4753
- uses: ./.github/actions/unit-tests
4854

4955
functional-tests:
5056
name: Functional Tests
51-
runs-on: ubuntu-22.04
57+
runs-on: ubuntu-20.04
5258
needs: [unit-tests]
59+
strategy:
60+
matrix:
61+
node-version: ["16", "18"]
5362
steps:
54-
- uses: actions/checkout@v2
63+
- uses: actions/checkout@v3
5564
with:
5665
submodules: 'recursive'
5766
- name: Cache node modules
58-
uses: actions/cache@v2
67+
uses: actions/cache@v3
5968
env:
6069
cache-name: cache-node-modules
6170
with:
@@ -65,69 +74,24 @@ jobs:
6574
${{ runner.os }}-build-${{ env.cache-name }}-
6675
${{ runner.os }}-build-
6776
${{ runner.os }}-
68-
- uses: actions/setup-node@v2
77+
- uses: actions/setup-node@v3
6978
with:
70-
node-version: "14"
79+
node-version: ${{ matrix.node-version }}
7180
- uses: ./.github/actions/functional-tests
7281
with:
7382
CYPRESS_RECORD_KEY_DOC: ${{ secrets.CYPRESS_RECORD_KEY_DOC }}
7483

75-
admin-console-tests:
76-
name: Admin Console Tests
77-
runs-on: ubuntu-22.04
78-
needs: [unit-tests]
79-
steps:
80-
- uses: actions/checkout@v2
81-
- name: Cache node modules
82-
uses: actions/cache@v2
83-
env:
84-
cache-name: cache-node-modules
85-
with:
86-
path: ~/.npm
87-
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
88-
restore-keys: |
89-
${{ runner.os }}-build-${{ env.cache-name }}-
90-
${{ runner.os }}-build-
91-
${{ runner.os }}-
92-
- uses: actions/setup-node@v1
93-
with:
94-
node-version: "14"
95-
- uses: ./.github/actions/tests-ac
96-
with:
97-
sdk-version: 7
98-
cypress-key: ${{ secrets.CYPRESS_RECORD_KEY }}
99-
100-
# doc-dead-links:
101-
# name: Check dead-links
102-
# runs-on: ubuntu-latest
103-
# steps:
104-
# - uses: actions/checkout@v2
105-
# with:
106-
# fetch-depth: 0
107-
# - name: Extract references from context
108-
# shell: bash
109-
# id: extract-refs
110-
# run: |
111-
# echo "::set-output name=version::$(git describe --abbrev=0 --tags | cut -d. -f 1)"
112-
# echo "::set-output name=repo::$(echo $GITHUB_REPOSITORY | cut -d/ -f 2)"
113-
# echo "::set-output name=fw-branch::$(if [ $BASE_BRANCH == master ]; then echo master; else echo develop; fi)"
114-
# - uses: convictional/[email protected]
115-
# with:
116-
# owner: kuzzleio
117-
# repo: documentation
118-
# github_token: ${{ secrets.ACCESS_TOKEN_CI }}
119-
# workflow_file_name: dead_links.workflow.yml
120-
# ref: ${{ steps.extract-refs.outputs.fw-branch }}
121-
# inputs: '{"repo_name": "${{ steps.extract-refs.outputs.repo }}", "branch": "${{ github.head_ref }}", "version": "${{ steps.extract-refs.outputs.version }}"}'
122-
12384
documentation-snippet-tests:
12485
name: Documentation Snippet Tests
12586
needs: [unit-tests]
126-
runs-on: ubuntu-22.04
87+
runs-on: ubuntu-20.04
88+
strategy:
89+
matrix:
90+
node-version: ["16", "18"]
12791
steps:
128-
- uses: actions/checkout@v2
92+
- uses: actions/checkout@v3
12993
- name: Cache node modules
130-
uses: actions/cache@v2
94+
uses: actions/cache@v3
13195
env:
13296
cache-name: cache-node-modules
13397
with:
@@ -137,9 +101,9 @@ jobs:
137101
${{ runner.os }}-build-${{ env.cache-name }}-
138102
${{ runner.os }}-build-
139103
${{ runner.os }}-
140-
- uses: actions/setup-node@v2
104+
- uses: actions/setup-node@v3
141105
with:
142-
node-version: "14"
106+
node-version: ${{ matrix.node-version }}
143107
- uses: ./.github/actions/snippet-tests
144108
with:
145109
CYPRESS_RECORD_KEY_DOC: ${{ secrets.CYPRESS_RECORD_KEY_DOC }}
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: Push checks
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
- beta
8+
9+
jobs:
10+
release:
11+
name: Release process
12+
runs-on: ubuntu-20.04
13+
permissions:
14+
contents: write
15+
issues: write
16+
pull-requests: write
17+
packages: write
18+
steps:
19+
- name: Checkout
20+
uses: actions/checkout@v3
21+
22+
- name: Setup Node.js
23+
uses: actions/setup-node@v3
24+
with:
25+
node-version: "lts/*"
26+
registry-url: "https://registry.npmjs.org"
27+
scope: '@kuzzleio'
28+
29+
- name: Install dependencies
30+
run: npm ci
31+
32+
- name: Release
33+
env:
34+
GITHUB_TOKEN: ${{ secrets.SEMANTIC_RELEASE_GHP }}
35+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
36+
SEMANTIC_RELEASE_NPM_PUBLISH: "true"
37+
SEMANTIC_RELEASE_SLACK_WEBHOOK: ${{ secrets.SEMANTIC_RELEASE_SLACK_WEBHOOK }}
38+
run: npx semantic-release
39+
40+
documentation_deploy:
41+
needs: [release]
42+
name: Documentation - Deploy
43+
runs-on: ubuntu-20.04
44+
steps:
45+
- name: Checkout
46+
uses: actions/checkout@v3
47+
48+
- uses: convictional/[email protected]
49+
with:
50+
owner: kuzzleio
51+
repo: documentation
52+
github_token: ${{ secrets.ACCESS_TOKEN_CI }}
53+
workflow_file_name: child_repo.workflow.yml
54+
ref: ${{ github.ref_name == 'master' && 'master' || 'develop' }}
55+
client_payload: '{"repo_name":"sdk-javascript","branch":"${{ github.ref_name }}","version":"1"}'

0 commit comments

Comments
 (0)