Skip to content

feat(release): adds notifications release ci configs#1367

Merged
ygrishajev merged 1 commit intomainfrom
feature/notifications
May 26, 2025
Merged

feat(release): adds notifications release ci configs#1367
ygrishajev merged 1 commit intomainfrom
feature/notifications

Conversation

@ygrishajev
Copy link
Contributor

@ygrishajev ygrishajev commented May 26, 2025

Summary by CodeRabbit

  • New Features
    • Extended release process to include the notifications app, ensuring versioning and changelog updates.
    • Added automated build and deployment workflows for notifications, including Docker image creation and Kubernetes deployment.
    • Enabled manual deployment of the notifications app via updated GitHub Actions workflows.
    • Introduced release configuration for notifications in the .release-it.js file.
    • Added support for notifications in build scripts and environment setup files.
  • Chores
    • Updated workflows to support notifications app releases, builds, and deployments.
    • Modified environment configuration and ignored files to facilitate environment-specific setups and version control.

@ygrishajev ygrishajev requested a review from a team as a code owner May 26, 2025 12:10
@coderabbitai
Copy link
Contributor

coderabbitai bot commented May 26, 2025

Walkthrough

The changes add support for the notifications application across the release, build, and deployment workflows. This includes updating GitHub workflows, release configuration, environment variables, and scripts to automate versioning, containerization, and deployment processes specific to notifications.

Changes

File(s) Change Summary
.github/workflows/create-pre-release-pr.yml Added npm run release for apps/notifications in the pre-release PR process.
.github/workflows/notifications-release.yml New workflow for releasing, building Docker images, and deploying notifications on push to main.
.github/workflows/reusable-build-image.yml Extended to recognize notifications/* tags, setting registry and app name accordingly.
.github/workflows/reusable-create-github-release.yml Added support for generating git_tag for notifications.
.github/workflows/reusable-deploy-k8s.yml Included notifications as a deployable option in manual workflow dispatch.
apps/notifications/.release-it.js New configuration exporting @akashnetwork/releaser for release automation.
apps/notifications/package.json Added release script and @akashnetwork/releaser dev dependency.
apps/notifications/env/.env Created environment config with APP_NAME and NOVU_MAILER_WORKFLOW_ID.

Sequence Diagram(s)

sequenceDiagram
    participant Dev as Developer
    participant GitHub as GitHub Actions
    participant Releaser as @akashnetwork/releaser
    participant Docker as Docker Registry
    participant K8s as Kubernetes Cluster

    Dev->>GitHub: Push to main (apps/notifications/package.json)
    GitHub->>GitHub: notifications-release.yml triggered
    GitHub->>Releaser: Create Release (generate git_tag)
    Releaser-->>GitHub: Release created with git_tag
    GitHub->>Docker: Build Docker image tagged with git_tag
    Docker-->>GitHub: Image built and pushed
    GitHub->>K8s: Deploy image to beta sandbox with git_tag
    K8s-->>GitHub: Deployment complete
Loading

Poem

A bunny hops through code so bright,
New releases now take flight!
Notifications join the crew,
With Docker builds and K8s too.
Automated flows, no more fright—
The rabbit cheers, “Deployments right!”
🐇✨

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

npm warn config production Use --omit=dev instead.
npm error Exit handler never called!
npm error This is an error with npm itself. Please report this error at:
npm error https://github.com/npm/cli/issues
npm error A complete log of this run can be found in: /.npm/_logs/2025-05-26T14_14_03_072Z-debug-0.log

✨ Finishing Touches
  • 📝 Generate Docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@ygrishajev ygrishajev force-pushed the feature/notifications branch from 9cec6d0 to 6cdfd96 Compare May 26, 2025 12:13
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between e0109dc and 6cdfd96.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (7)
  • .github/workflows/create-pre-release-pr.yml (1 hunks)
  • .github/workflows/notifications-release.yml (1 hunks)
  • .github/workflows/reusable-build-image.yml (1 hunks)
  • .github/workflows/reusable-create-github-release.yml (1 hunks)
  • .github/workflows/reusable-deploy-k8s.yml (1 hunks)
  • apps/notifications/.release-it.js (1 hunks)
  • apps/notifications/package.json (2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: validate-notifications
🔇 Additional comments (10)
apps/notifications/package.json (2)

15-15: Release script added
The "release": "release-it" command enables automated releases for the notifications app using your standardized releaser config.


72-72: Dev dependency for releaser
Introducing @akashnetwork/releaser into devDependencies aligns with your centralized release setup. Ensure the wildcard version is acceptable for stability.

.github/workflows/reusable-deploy-k8s.yml (1)

20-20: Enable notifications deployment
Including "notifications" in the app choices exposes the notifications service for manual K8s deployment. Ensure that a corresponding Helm chart and values file exist under .helm/notifications-<environment>-values.yaml.

apps/notifications/.release-it.js (1)

1-1: Re-export centralized releaser
Leveraging module.exports = require("@akashnetwork/releaser"); ensures consistent release behavior across projects. Confirm that @akashnetwork/releaser is installed in this workspace and that any custom configuration hooks are applied.

.github/workflows/create-pre-release-pr.yml (1)

88-88: Include notifications in pre-release step
Adding npm run release -w apps/notifications -- --verbose --ci ensures the notifications workspace is versioned and changelogged alongside other apps. Verify that the apps/notifications path matches your workspace configuration in package.json.

.github/workflows/reusable-create-github-release.yml (1)

59-60: Support notifications tag mapping
The new branch mapping for "notifications" to notifications/v$git_tag correctly extends your tag generation logic. Keep this branch in sync if the app directory name changes.

.github/workflows/notifications-release.yml (4)

1-9: Appropriate workflow trigger
The push event on main when apps/notifications/package.json changes scopes the release correctly, preventing unnecessary runs.


11-17: Release job setup is correct
The release job invokes the reusable release workflow, inherits secrets, and passes app: notifications as expected.


18-29: Build job looks solid
The conditional if: needs.release.outputs.git_tag != '' avoids orphan builds, and permissions for Docker registry publishing are minimal yet sufficient.


30-38: Deploy-to-beta wiring is correct
The deploy-beta job depends on build output, passes appVersion and environment: staging to the reusable deploy workflow.
Please verify that reusable-deploy-k8s.yml expects an appVersion input and uses the environment key.

@codecov
Copy link

codecov bot commented May 26, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 34.68%. Comparing base (973acd3) to head (79e9a9a).
Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1367   +/-   ##
=======================================
  Coverage   34.67%   34.68%           
=======================================
  Files         805      805           
  Lines       19587    19584    -3     
  Branches     3614     3614           
=======================================
  Hits         6792     6792           
+ Misses      12055    12052    -3     
  Partials      740      740           
Flag Coverage Δ *Carryforward flag
api 64.22% <ø> (ø) Carriedforward from 973acd3
deploy-web 13.90% <ø> (+<0.01%) ⬆️ Carriedforward from 973acd3
notifications 88.67% <ø> (ø)
provider-proxy 80.09% <ø> (ø) Carriedforward from 973acd3

*This pull request uses carry forward flags. Click here to find out more.

see 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@ygrishajev ygrishajev force-pushed the feature/notifications branch 2 times, most recently from 3a1aa6c to fd8f0c7 Compare May 26, 2025 13:23
@ygrishajev ygrishajev force-pushed the feature/notifications branch from fd8f0c7 to 79e9a9a Compare May 26, 2025 14:12
@ygrishajev ygrishajev changed the title chore(release): adds notifications release ci configs feat(release): adds notifications release ci configs May 26, 2025
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

♻️ Duplicate comments (1)
.github/workflows/reusable-build-image.yml (1)

80-83: Correct environment variable for notifications branch
The script now correctly sets app=notifications (instead of notifications=notifications), ensuring downstream steps relying on env.app will function as expected.

🧹 Nitpick comments (1)
apps/notifications/package.json (1)

73-73: Consider pinning @akashnetwork/releaser to a fixed version
Using "*" can lead to unpredictable builds. Pinning to a specific version or version range improves reproducibility and prevents unexpected breaking changes.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between fd8f0c7 and 79e9a9a.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (9)
  • .github/workflows/create-pre-release-pr.yml (1 hunks)
  • .github/workflows/notifications-release.yml (1 hunks)
  • .github/workflows/reusable-build-image.yml (1 hunks)
  • .github/workflows/reusable-create-github-release.yml (1 hunks)
  • .github/workflows/reusable-deploy-k8s.yml (1 hunks)
  • apps/notifications/.gitignore (0 hunks)
  • apps/notifications/.release-it.js (1 hunks)
  • apps/notifications/env/.env (1 hunks)
  • apps/notifications/package.json (3 hunks)
💤 Files with no reviewable changes (1)
  • apps/notifications/.gitignore
🚧 Files skipped from review as they are similar to previous changes (4)
  • apps/notifications/env/.env
  • apps/notifications/.release-it.js
  • .github/workflows/reusable-create-github-release.yml
  • .github/workflows/notifications-release.yml
⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: validate-notifications
🔇 Additional comments (4)
apps/notifications/package.json (2)

3-3: Bump version to 1.0.0
Updating from 0.0.1 to 1.0.0 signals the first stable release of the notifications package.


15-17: Add production and release scripts
Introducing "prod" and "release" scripts enables streamlined database migrations and uses release-it for automated changelogs and versioning.

.github/workflows/reusable-deploy-k8s.yml (1)

18-23: Include notifications in deployment choices
Adding "notifications" to the app input options aligns this manual and reusable workflow with the newly supported notifications application.

.github/workflows/create-pre-release-pr.yml (1)

83-89: Add notifications to pre-release commands
Including npm run release -w apps/notifications -- --verbose --ci ensures the notifications workspace is versioned and changeloged alongside other apps.

@ygrishajev ygrishajev merged commit 87655e2 into main May 26, 2025
29 checks passed
@ygrishajev ygrishajev deleted the feature/notifications branch May 26, 2025 14:42
@coderabbitai coderabbitai bot mentioned this pull request Oct 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Comments