Skip to content

Commit

Permalink
mod: update workflow config (#27)
Browse files Browse the repository at this point in the history
  • Loading branch information
hetao92 authored Oct 14, 2021
1 parent 92a2e00 commit c83df89
Show file tree
Hide file tree
Showing 15 changed files with 123 additions and 101 deletions.
70 changes: 61 additions & 9 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ on:
branches:
- master
jobs:
package:
name: build package
tar-package:
name: build tar package
runs-on: ubuntu-latest
strategy:
matrix:
Expand All @@ -16,25 +16,77 @@ jobs:
steps:
- uses: actions/checkout@v2
with:
ref: 'master'
path: source/nebula-graph-studio
- uses: actions/checkout@v2
with:
repository: vesoft-inc/nebula-http-gateway
path: source/nebula-http-gateway
ref: v2.0
- uses: actions/setup-go@v2
with:
go-version: '^1.13.1'
- uses: actions/setup-node@v2
with:
node-version: '10'
- name: Package
run: bash ./source/nebula-graph-studio/scripts/tar/pack.sh
- name: Upload to OSS
run: bash ./source/nebula-graph-studio/scripts/tar/upload.sh ${{ secrets.OSS_ENDPOINT }} ${{ secrets.OSS_ID }} ${{ secrets.OSS_SECRET }} ${{ secrets.OSS_TEST_URL }}
rpm-package:
name: build rpm package
runs-on: ubuntu-latest
strategy:
matrix:
os:
- centos7
container:
image: vesoft/nebula-dev:${{ matrix.os }}
steps:
- uses: actions/checkout@v2
with:
repository: vesoft-inc/nebula-importer
path: source/nebula-importer
path: source/nebula-graph-studio
- uses: actions/checkout@v2
with:
repository: vesoft-inc/nebula-http-gateway
path: source/nebula-http-gateway
ref: v2.0
- uses: actions/setup-go@v2
with:
go-version: '^1.13.1'
- uses: actions/setup-node@v2
with:
node-version: '10'
- name: Package
run: bash ./source/nebula-graph-studio/scripts/rpm-package.sh ${{ secrets.GA_ID }}
run: bash ./source/nebula-graph-studio/scripts/rpm/pack.sh
- name: Upload oss
run: cd ./source/nebula-graph-studio/tmp/ && ossutil64 -e ${{ secrets.OSS_ENDPOINT }} -i ${{ secrets.OSS_ID }} -k ${{ secrets.OSS_SECRET }} -f cp ./ ${{ secrets.OSS_TEST_URL }} --include "nebula-graph-studio-*.rpm*" --only-current-dir -r


run: bash ./source/nebula-graph-studio/scripts/rpm/upload.sh ${{ secrets.OSS_ENDPOINT }} ${{ secrets.OSS_ID }} ${{ secrets.OSS_SECRET }} ${{ secrets.OSS_TEST_URL }}
docker-image:
name: docker image build
runs-on: ubuntu-latest
steps:
-
name: Checkout Github Action
uses: actions/checkout@master
-
name: set track
run: bash ./scripts/setEventTracking.sh ${{ secrets.GA_ID }}
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
-
name: Set up Docker Build
uses: docker/setup-buildx-action@v1
-
name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
-
name: Build and push
uses: docker/build-push-action@v2
with:
context: .
file: ./Dockerfile
push: true
tags: vesoft/nebula-graph-studio:nightly
63 changes: 60 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,74 @@
name: Studio Image Release
name: Studio Release
on:
release:
types:
- published
jobs:
release-image:
tar-package:
name: build tar package
runs-on: ubuntu-latest
strategy:
matrix:
os:
- centos7
container:
image: vesoft/nebula-dev:${{ matrix.os }}
steps:
- uses: actions/checkout@v2
with:
path: source/nebula-graph-studio
- uses: actions/checkout@v2
with:
repository: vesoft-inc/nebula-http-gateway
path: source/nebula-http-gateway
ref: v2.0
- uses: actions/setup-go@v2
with:
go-version: '^1.13.1'
- uses: actions/setup-node@v2
with:
node-version: '10'
- name: Package
run: bash ./source/nebula-graph-studio/scripts/tar/pack.sh
- name: Upload to OSS
run: bash ./source/nebula-graph-studio/scripts/tar/upload.sh ${{ secrets.OSS_ENDPOINT }} ${{ secrets.OSS_ID }} ${{ secrets.OSS_SECRET }} ${{ secrets.OSS_URL }}
rpm-package:
name: build rpm package
runs-on: ubuntu-latest
strategy:
matrix:
os:
- centos7
container:
image: vesoft/nebula-dev:${{ matrix.os }}
steps:
- uses: actions/checkout@v2
with:
path: source/nebula-graph-studio
- uses: actions/checkout@v2
with:
repository: vesoft-inc/nebula-http-gateway
path: source/nebula-http-gateway
ref: v2.0
- uses: actions/setup-go@v2
with:
go-version: '^1.13.1'
- uses: actions/setup-node@v2
with:
node-version: '10'
- name: Package
run: bash ./source/nebula-graph-studio/scripts/rpm/pack.sh
- name: Upload oss
run: bash ./source/nebula-graph-studio/scripts/rpm/upload.sh ${{ secrets.OSS_ENDPOINT }} ${{ secrets.OSS_ID }} ${{ secrets.OSS_SECRET }} ${{ secrets.OSS_URL }}
docker-image:
name: docker image build
runs-on: ubuntu-latest
steps:
-
name: Checkout Github Action
uses: actions/checkout@master
-
name: Package
name: set track
run: bash ./scripts/setEventTracking.sh ${{ secrets.GA_ID }}
-
name: Set up QEMU
Expand Down
36 changes: 0 additions & 36 deletions .github/workflows/studio-rpm-package.yml

This file was deleted.

38 changes: 0 additions & 38 deletions .github/workflows/studio-tar-package.yml

This file was deleted.

13 changes: 0 additions & 13 deletions scripts/pid.sh

This file was deleted.

File renamed without changes.
2 changes: 1 addition & 1 deletion scripts/postinst.sh → scripts/rpm/postinst.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ chmod 755 ./vendors/nebula-http-gateway/nebula-httpd
chmod 777 ./tmp/
tar -xzvf node_modules.tar.gz

bash ./scripts/start.sh
bash ./scripts/rpm/start.sh
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion scripts/prerm.sh → scripts/rpm/prerm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@
# kill nebula-http-gateway server
set +e
cd /usr/local/nebula-graph-studio/
bash ./scripts/stop.sh
bash ./scripts/rpm/stop.sh
set -e
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit c83df89

Please sign in to comment.