-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
719 changed files
with
103,436 additions
and
54,528 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,32 @@ | ||
|
||
# Special property that should be specified | ||
# at the top of the file outside of any sections. | ||
# Set to true to stop .editorconfig files search | ||
# on current file. | ||
root = true | ||
|
||
[*] #All type of file | ||
end_of_line = lf | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.js] | ||
indent_style = space | ||
tab_width = 4 | ||
|
||
[*.yml] | ||
indent_style = space | ||
indent_size = 2 | ||
|
||
[package.json] | ||
indent_style = space | ||
indent_size = 2 | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false | ||
|
||
[*.{html,js,md}] | ||
block_comment_start = /** | ||
block_comment = * | ||
block_comment_end = */ |
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 |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: "Reusable workflow to build JSorolla" | ||
|
||
on: | ||
workflow_call: | ||
outputs: | ||
version: | ||
description: "JSorolla version" | ||
value: ${{ jobs.build-jsorolla-workflow.outputs.version }} | ||
|
||
jobs: | ||
build-jsorolla-workflow: | ||
name: Build JSorolla | ||
runs-on: ubuntu-20.04 | ||
outputs: | ||
version: ${{ steps.package.outputs.version }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-node@v2 | ||
with: | ||
node-version: "16" | ||
- uses: actions/cache@v2 | ||
env: | ||
cache-name: cache-node-modules | ||
with: | ||
# npm cache files are stored in `~/.npm` on Linux/macOS | ||
path: ~/.npm | ||
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-${{ env.cache-name }}- | ||
${{ runner.os }}-build- | ||
${{ runner.os }}- | ||
- run: npm install | ||
- run: npm run build | ||
- id: package | ||
uses: tyankatsu0105/read-package-version-actions@v1 | ||
- uses: actions/upload-artifact@v2 | ||
with: | ||
name: jsorolla-build | ||
path: build | ||
retention-days: 1 | ||
- uses: actions/upload-artifact@v2 | ||
with: | ||
name: jsorolla-release | ||
# TODO: we should rename the iva-VERSION.tar.gz file as jsorolla-VERSION.tar.gz | ||
path: iva-${{ steps.package.outputs.version }}.tar.gz | ||
retention-days: 1 | ||
|
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,33 @@ | ||
name: "Reusable workflow to deploy JSorolla application" | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
version: | ||
type: string | ||
required: true | ||
secrets: | ||
SSH_SWDEV_IP: | ||
required: true | ||
SSH_SWDEV_USER: | ||
required: true | ||
SSH_SWDEV_PASSWORD: | ||
required: true | ||
|
||
jobs: | ||
deploy-jsorolla-workflow: | ||
name: Deploy JSorolla Application | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- uses: actions/download-artifact@v2 | ||
with: | ||
name: jsorolla-build | ||
path: build | ||
- uses: garygrossgarten/github-action-scp@release | ||
with: | ||
local: build | ||
remote: /mnt/data/WEB-APPS/dev/jsorolla-${{ inputs.version }} | ||
rmRemote: true | ||
host: ${{ secrets.SSH_SWDEV_IP }} | ||
username: ${{ secrets.SSH_SWDEV_USER }} | ||
password: ${{ secrets.SSH_SWDEV_PASSWORD }} |
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,42 @@ | ||
name: "Main Workflow for JSorolla" | ||
|
||
on: | ||
push: | ||
branches: | ||
- "develop" | ||
- "release-*" | ||
|
||
jobs: | ||
build: | ||
uses: opencb/jsorolla/.github/workflows/build-jsorolla-workflow.yml@develop | ||
|
||
docker: | ||
needs: build | ||
uses: opencb/jsorolla/.github/workflows/docker-jsorolla-workflow.yml@develop | ||
secrets: | ||
DOCKER_HUB_USER: ${{ secrets.DOCKER_HUB_USER }} | ||
DOCKER_HUB_PASSWORD: ${{ secrets.DOCKER_HUB_PASSWORD }} | ||
|
||
deploy: | ||
needs: build | ||
uses: opencb/jsorolla/.github/workflows/deploy-jsorolla-workflow.yml@develop | ||
with: | ||
version: ${{ needs.build.outputs.version }} | ||
secrets: | ||
SSH_SWDEV_IP: ${{ secrets.SSH_SWDEV_IP }} | ||
SSH_SWDEV_USER: ${{ secrets.SSH_SWDEV_USER }} | ||
SSH_SWDEV_PASSWORD: ${{ secrets.SSH_SWDEV_PASSWORD }} | ||
|
||
# notify: | ||
# name: Notify private repository | ||
# runs-on: ubuntu-20.04 | ||
# needs: build | ||
# steps: | ||
# - uses: actions/checkout@v2 | ||
# - name: Invoke workflow in a private repo | ||
# uses: benc-uk/workflow-dispatch@v1 | ||
# with: | ||
# workflow: Docker publish | ||
# ref: ${{ github.event.push.head.ref }} | ||
# repo: ${{ secrets.JSOROLLA_PRIVATE_REPO }} | ||
# token: ${{ secrets.ZG_PERSONAL_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 |
---|---|---|
@@ -0,0 +1,26 @@ | ||
name: "Reusable workflow to publish JSorolla in DockerHub" | ||
|
||
on: | ||
workflow_call: | ||
secrets: | ||
DOCKER_HUB_USER: | ||
required: true | ||
DOCKER_HUB_PASSWORD: | ||
required: true | ||
|
||
jobs: | ||
docker-jsorolla-workflow: | ||
name: Publish JSorolla Docker | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/download-artifact@v2 | ||
with: | ||
name: jsorolla-build | ||
path: build | ||
- uses: docker/login-action@v1 | ||
with: | ||
username: ${{ secrets.DOCKER_HUB_USER }} | ||
password: ${{ secrets.DOCKER_HUB_PASSWORD }} | ||
- run: python3 ./docker/docker-build.py push --images app | ||
|
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,34 @@ | ||
name: "Release" | ||
|
||
on: | ||
push: | ||
tags: | ||
- "*" | ||
|
||
jobs: | ||
build: | ||
uses: opencb/jsorolla/.github/workflows/build-jsorolla-workflow.yml@develop | ||
|
||
docker: | ||
needs: build | ||
uses: opencb/jsorolla/.github/workflows/docker-jsorolla-workflow.yml@develop | ||
secrets: | ||
DOCKER_HUB_USER: ${{ secrets.DOCKER_HUB_USER }} | ||
DOCKER_HUB_PASSWORD: ${{ secrets.DOCKER_HUB_PASSWORD }} | ||
|
||
release: | ||
needs: [build, docker] | ||
uses: opencb/java-common-libs/.github/workflows/release-github-workflow.yml@develop | ||
with: | ||
artifact: jsorolla-release | ||
file: iva-${{ needs.build.outputs.version }}.tar.gz | ||
|
||
deploy: | ||
needs: build | ||
uses: opencb/jsorolla/.github/workflows/deploy-jsorolla-workflow.yml@develop | ||
with: | ||
version: ${{ needs.build.outputs.version }} | ||
secrets: | ||
SSH_SWDEV_IP: ${{ secrets.SSH_SWDEV_IP }} | ||
SSH_SWDEV_USER: ${{ secrets.SSH_SWDEV_USER }} | ||
SSH_SWDEV_PASSWORD: ${{ secrets.SSH_SWDEV_PASSWORD }} |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
_ |
This file was deleted.
Oops, something went wrong.
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,5 @@ | ||
#!/bin/sh | ||
. "$(dirname "$0")/_/husky.sh" | ||
|
||
npm run lint:js | ||
# npm test |
Oops, something went wrong.