Permalink
Show file tree
Hide file tree
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
refact: adopt backend for ant-ui & improve configs (#348)
also enable the ci/cd & release steps
- Loading branch information
Showing
29 changed files
with
264 additions
and
121 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 |
---|---|---|
@@ -0,0 +1,88 @@ | ||
name: hugegraph-hubble ci | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
- /^release-.*$/ | ||
- /^test-.*$/ | ||
- /^v[0-9]\..*$/ | ||
pull_request: | ||
branches: | ||
- master | ||
- /^release-.*$/ | ||
- /^test-.*$/ | ||
- /^v[0-9]\..*$/ | ||
|
||
env: | ||
TRAVIS_DIR: hubble-dist/assembly/travis | ||
SERVER_VERSION: 0.12.0 | ||
|
||
jobs: | ||
hubble-ci: | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- name: Install JDK 8 | ||
uses: actions/setup-java@v2 | ||
with: | ||
java-version: '8' | ||
distribution: 'adopt' | ||
|
||
# we also should cache python & yarn & downloads to avoid useless work | ||
- name: Cache Maven packages | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.m2/repository | ||
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }} | ||
restore-keys: | | ||
${{ runner.os }}-maven- | ||
- name: Get Yarn path | ||
id: yarn-cache-dir-path | ||
run: echo "::set-output name=dir::$(yarn cache dir)" | ||
|
||
- name: Ceche Yarn packages | ||
uses: actions/cache@v2 | ||
# use id to check `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) | ||
id: yarn-cache | ||
with: | ||
path: ${{ steps.yarn-cache-dir-path.outputs.dir }} | ||
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-yarn- | ||
- name: Ceche Python packages | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.cache/pip | ||
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }} | ||
restore-keys: | | ||
${{ runner.os }}-pip- | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 2 | ||
|
||
- name: Compile | ||
run: | | ||
mvn clean compile -Dmaven.javadoc.skip=true | grep -v "Downloading\|Downloaded" | ||
- name: Prepare env and service | ||
run: | | ||
sudo pip install -r ${TRAVIS_DIR}/requirements.txt | ||
$TRAVIS_DIR/install-hugegraph.sh $SERVER_VERSION | ||
- name: Unit test | ||
run: mvn test -P unit-test | ||
|
||
- name: API test | ||
env: | ||
CI: false | ||
run: | | ||
$TRAVIS_DIR/run-api-test.sh | ||
- name: Upload coverage to Codecov | ||
uses: codecov/codecov-action@v1 | ||
with: | ||
file: target/site/jacoco/*.xml |
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 |
---|---|---|
@@ -0,0 +1,39 @@ | ||
name: release maven package | ||
|
||
on: | ||
release: | ||
types: [ published ] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- name: Install JDK 8 | ||
uses: actions/setup-java@v2 | ||
with: | ||
java-version: '8' | ||
distribution: 'adopt' | ||
|
||
- name: Cache Maven packages | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.m2 | ||
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }} | ||
restore-keys: ${{ runner.os }}-m2 | ||
|
||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 2 | ||
|
||
- name: Release Maven package | ||
uses: samuelmeuli/action-maven-publish@v1 | ||
with: | ||
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }} | ||
gpg_passphrase: ${{ secrets.GPG_PASSPHRASE }} | ||
nexus_username: ${{ secrets.NEXUS_USERNAME }} | ||
nexus_password: ${{ secrets.NEXUS_PASSWORD }} | ||
server_id: sonatype-nexus-staging | ||
maven_profiles: "release" | ||
maven_args: > | ||
-Dmaven.test.skip=true |
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 |
---|---|---|
@@ -34,6 +34,7 @@ build/ | ||
|
||
### VS Code ### | ||
.vscode/ | ||
/hubble-fe/.history/ | ||
|
||
# dependencies | ||
/hubble-fe/node_modules | ||
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,19 @@ | ||
#!/bin/bash | ||
|
||
HOME_PATH=`dirname $0` | ||
HOME_PATH=`cd ${HOME_PATH}/.. && pwd` | ||
HOME_PATH=$(dirname $0) | ||
HOME_PATH=$(cd "${HOME_PATH}"/.. && pwd) | ||
BIN_PATH=${HOME_PATH}/bin | ||
PID_FILE=${BIN_PATH}/pid | ||
|
||
if [[ -f ${PID_FILE} ]]; then | ||
pid=`cat ${PID_FILE}` | ||
if kill -0 ${pid} > /dev/null 2>&1; then | ||
kill -9 ${pid} | ||
pid=$(cat "${PID_FILE}") | ||
if kill -0 "${pid}" > /dev/null 2>&1; then | ||
kill -9 "${pid}" | ||
echo "stopped HugeGraphHubble" | ||
else | ||
echo "process not exist" | ||
echo "process ${pid} not exist" | ||
fi | ||
rm ${PID_FILE} | ||
rm "${PID_FILE}" | ||
else | ||
echo "HugeGraphHubble not running" | ||
fi |
Binary file not shown.
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
BIN
-679 Bytes
hubble-dist/assembly/static/conf/hugegraph.truststore
Binary file not shown.
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.