Update documentation. #3
Workflow file for this 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
name: Node Workflow | ||
# Standard workflow for any NodeJS based projects. | ||
on: | ||
workflow_call: | ||
workflow_dispatch: | ||
jobs: | ||
# Build jobs | ||
build_npm: | ||
name: "Build via NPM" | ||
uses: ./.github/workflows/run_npm.yaml | ||
with: | ||
script: "build" | ||
lint_npm: | ||
name: "Lint via NPM" | ||
uses: ./.github/workflows/run_npm.yaml | ||
with: | ||
script: "lint" | ||
lint_docker: | ||
name: "Lint Dockerfile" | ||
uses: ./.github/workflows/lint_docker.yaml | ||
# Test jobs | ||
test_npm: | ||
name: "Run unit tests via NPM" | ||
needs: | ||
- build_npm | ||
- lint_npm | ||
- lint_docker | ||
uses: ./.github/workflows/run_npm.yaml | ||
with: | ||
script: "test" | ||
build_docker: | ||
name: "Build docker image" | ||
needs: | ||
- build_npm | ||
- lint_npm | ||
- lint_docker | ||
uses: ./.github/workflows/build_docker.yaml | ||
with: | ||
repo_project: "rcsb" | ||
docker_image_name: "rcsb-sierra" | ||
# Staging jobs | ||
build_docker_staging: | ||
name: "Build docker image with staging tag" | ||
needs: | ||
- test_npm | ||
- build_docker | ||
uses: ./.github/workflow/build_docker.yaml | ||
with: | ||
repo_project: "rcsb" | ||
docker_image_name: "rcsb-sierra" | ||
additional_tag: "staging" | ||
skaffold_deploy_staging: | ||
name: "Skaffold deploy into staging namespace" | ||
if: github.ref == format('refs/heads/{0}', github.event.repository.default_branch) | ||
needs: | ||
- build_docker_staging | ||
uses: ./.github/workflows/deploy_skaffold.yaml | ||
with: | ||
namespace: staging | ||
profile: staging | ||
# Production jobs | ||
build_docker_production: | ||
name: "Build docker image with production tag" | ||
needs: | ||
- build_docker_staging | ||
uses: ./.github/workflow/build_docker.yaml | ||
with: | ||
repo_project: "rcsb" | ||
docker_image_name: "rcsb-sierra" | ||
additional_tag: "production" | ||
skaffold_deploy_production: | ||
name: Skaffold deploy into production environment" | ||
if: github.ref == format('refs/heads/{0}', github.event.repository.default_branch) | ||
needs: | ||
- build_docker_production | ||
uses: ./.github/workflows/deploy_skaffold.yaml | ||
with: | ||
namespace: production | ||
profile: production | ||