Skip to content

Commit

Permalink
Merge pull request #2 from ixofoundation/feat/devsecops
Browse files Browse the repository at this point in the history
Add CI/CD
  • Loading branch information
Michael-Ixo authored Aug 16, 2024
2 parents b3a36d6 + 0cae525 commit bb3f256
Show file tree
Hide file tree
Showing 6 changed files with 2,661 additions and 22 deletions.
13 changes: 13 additions & 0 deletions .github/workflows/node-ci-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: Build and Release
on:
push:
branches:
- main
- develop

jobs:
build-and-release:
uses: ixofoundation/ixo-github-actions/.github/workflows/node-ci-build.yml@main
with:
commit_sha: ${{ github.sha }}
secrets: inherit
7 changes: 7 additions & 0 deletions .github/workflows/node-ci-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
name: Pull Request Build and Test
on:
pull_request:

jobs:
call-ci-workflow:
uses: ixofoundation/ixo-github-actions/.github/workflows/node-ci-pr.yml@main
37 changes: 37 additions & 0 deletions .github/workflows/update-docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# name: update docs
# on:
# push:
# branches: [master]
# workflow_dispatch:
# permissions:
# contents: write

# jobs:
# ixo-cellnode-docs:
# runs-on: ubuntu-latest
# concurrency:
# group: ${{ github.ref }}
# cancel-in-progress: true
# steps:
# - name: 🏗 Setup repo
# uses: actions/checkout@v2

# - name: 🏗 Setup Node
# uses: actions/setup-node@v2
# with:
# node-version: 16.x

# - name: install typedoc
# run: npm install typedoc

# - name: generate docs
# run: npx typedoc src/* src/*/*

# # run: echo ${GITHUB_REF##*/}

# - name: Deploy 🚀
# uses: JamesIves/github-pages-deploy-action@v4
# with:
# folder: docs
# branch: master
# target-folder: docs
63 changes: 63 additions & 0 deletions .releaserc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
{
"branches": [
"main",
"master",
{
"name": "develop",
"channel": "alpha",
"prerelease": true
},
{
"name": "test",
"channel": "beta",
"prerelease": true
}
],
"ci": true,
"preset": "conventionalcommits",
"plugins": [
[
"@semantic-release/commit-analyzer",
{
"releaseRules": [
{ "breaking": true, "release": "major" },
{ "type": "feat", "release": "minor" },
{ "type": "fix", "release": "patch" },
{ "type": "perf", "release": "patch" },
{ "type": "build", "release": "patch" },
{ "scope": "security", "release": "patch" },
{ "type": "chore", "release": false },
{ "type": "ci", "release": false },
{ "type": "docs", "release": false },
{ "type": "refactor", "release": false },
{ "type": "revert", "release": false },
{ "type": "style", "release": false },
{ "type": "test", "release": false },
{ "scope": "no-release", "release": false },
{ "scope": "release", "release": "patch" }
],
"presetConfig": true
}
],
[
"@semantic-release/release-notes-generator",
{
"presetConfig": true
}
],
[
"@semantic-release/npm",
{
"npmPublish": false
}
],
[
"@semantic-release/git",
{
"assets": ["package.json"],
"message": "chore(release): ${nextRelease.version} [skip ci]\n${nextRelease.notes}"
}
],
"@semantic-release/github"
]
}
5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
"@nestjs/cli": "9.2.0",
"@nestjs/schematics": "9.0.4",
"@nestjs/testing": "9.3.9",
"@semantic-release/git": "^10.0.1",
"@types/cron": "2.0.0",
"@types/express": "4.17.17",
"@types/jest": "29.4.0",
Expand All @@ -53,11 +54,13 @@
"@types/supertest": "2.0.12",
"@typescript-eslint/eslint-plugin": "5.53.0",
"@typescript-eslint/parser": "5.53.0",
"conventional-changelog-conventionalcommits": "^7.0.2",
"eslint": "8.34.0",
"eslint-config-prettier": "8.6.0",
"eslint-plugin-prettier": "4.2.1",
"jest": "29.4.3",
"prettier": "2.8.4",
"semantic-release": "22",
"source-map-support": "0.5.21",
"supertest": "6.3.3",
"ts-jest": "29.0.5",
Expand All @@ -83,4 +86,4 @@
"coverageDirectory": "../coverage",
"testEnvironment": "node"
}
}
}
Loading

0 comments on commit bb3f256

Please sign in to comment.