Skip to content

Commit

Permalink
Update documentation.
Browse files Browse the repository at this point in the history
  • Loading branch information
henrychao-rcsb committed Jul 17, 2023
1 parent a5ae01a commit 32742e7
Showing 1 changed file with 38 additions and 50 deletions.
88 changes: 38 additions & 50 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,52 +12,27 @@ For more in-depth documentation on the workflow `.yaml` files, see [this link](h

# Java Projects

## .github/workflows/push-to-branch.yaml
## .github/workflows/workflow-java.yaml

Add this file into your repository as `.github/workflows/push-to-branch.yaml` in order to have automated builds of all branches which are not `master`:
Add this file into your repository as `.github/workflows/workflow-java.yaml` in order to have automated builds run for all branches:

```yaml
name: Push2Branch
name: Run CI/CD Workflow

on:
push:
branches-ignore:
- "master"

jobs:
push-to-branch:
uses: rcsb/devops-cicd-github-actions/.github/workflows/push-to-branch.yaml@master
with:
distribution: # The file name of the built artifact which will be uploaded to buildlocker
type: # The type of file for the built artifact. Valid options are [ war | jar ]
do_skaffold_deploy: # Deploy the application to Kubernetes via skaffold. Valid options are [ true | false ]
```
## .github/workflows/push-to-master.yaml
Add this file into your repository as `.github/workflows/push-to-master.yaml` in order to have automated builds on the `master` branch (and only that branch):

```yaml
name: Push2Master
on:
push:
branches:
- "master"
jobs:
push-to-master:
uses: rcsb/devops-cicd-github-actions/.github/workflows/push-to-master.yaml@master
with:
distribution: # The file name of the built artifact which will be uploaded to buildlocker
type: # The type of file for the built artifact. Valid options are [ "war" | "jar" ]
run-workflow:
name: "Run automated workflow"
uses: rcsb/devops-cicd-github-actions/.github/workflows/workflow-java.yaml@master
```
# Node Projects
## .github/workflows/nightly-test.yaml
Add this file into your repository as `.github/workflows/nightly-test.yaml` in order to have automated builds run periodically to perform tests:
Add this file into your repository as `.github/workflows/nightly-test.yaml` in order to have automated builds run periodic tests:

```yaml
name: Nightly Cypress Test
Expand All @@ -77,34 +52,47 @@ on:
jobs:
cypress:
uses: rcsb/devops-cicd-github-actions/.github/workflows/cypress.yaml@master
uses: rcsb/devops-cicd-github-actions/.github/workflows/run_npm.yaml@master
with:
branch: "master" # The name of the branch the test will be ran against
type: "nightly" # The type of test to run. Values are [ "nightly" | "push" ]
script: runnightly
```

## .github/workflows/node-deploy.yaml
## .github/workflows/workflow-node.yaml

Add this file into your repository as `.github/workflows/node-deploy.yaml` in order to have automated builds run for all branches:
Add this file into your repository as `.github/workflows/workflow-node.yaml` in order to have automated builds run for all branches:

```yaml
name: Node Build and Deploy
name: Run CI/CD Workflow
on:
push:
workflow_dispatch:
jobs:
cypress-test:
uses: rcsb/devops-cicd-github-actions/.github/workflows/cypress.yaml@master
with:
branch: ${{ github.ref_name }} # Set this value to always use the commit branch. Leave as is.
type: 'push' # The type of test to run. Values are [ "nightly" | "push" ]. Should just leave this as "push" in most cases.
run-workflow:
name: "Run automated workflow"
uses: rcsb/devops-cicd-github-actions/.github/workflows/workflow-node.yaml@master
```

# Docker Projects

## .github/workflows/workflow-docker.yaml

Add this file into your repository as `.github/workflows/workflow-docker.yaml` in order to have automated builds run for all branches:

```yaml
name: Run CI/CD Workflow
on:
push:
node-build-deploy:
needs: cypress-test
uses: rcsb/devops-cicd-github-actions/.github/workflows/node-deploy.yaml@master
jobs:
run-workflow:
name: "Run automated workflow"
uses: rcsb/devops-cicd-github-actions/.github/workflows/workflow-docker.yaml@master
with:
distribution: # The file name of the built artifact which will be uploaded to buildlocker
branch: ${{ github.ref_name }} # Set this value to always use the commit branch. Leave as is.
```
dockerfile_location: # The location of the Dockerfile relative to the root of the repository. Defaults to "Dockerfile".
repo_url: # The URL of the remote Docker image repository. Defaults to "harbor.devops.k8s.rcsb.org".
repo_project: # REQUIRED. The name of the project or organization in the remote Docker image repository.
docker_image_name: # REQUIRED. The name of the Docker image to create.
docker_build_context: # The path location of the docker build context, relative to the project root. Defaults to the project root.
```

0 comments on commit 32742e7

Please sign in to comment.