-
-
Notifications
You must be signed in to change notification settings - Fork 971
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BugFixes: Minimize Docker resource efficiency (this pull request is to pass github test flow for branch different than develop) #2791
Conversation
* fix: Fixed error in UnblockUser mutation * Added tests
…alisadoesFoundation#2240) * Fix MongoDB URI in loadPlugin function * Implement connection check before establishing new database connection * Replace isConnected variable with mongoose.connection.readyState check * Add check comments to db.ts file
…sadoesFoundation#2247) Bumps [@typescript-eslint/parser](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/parser) from 7.6.0 to 7.7.0. - [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases) - [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/parser/CHANGELOG.md) - [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v7.7.0/packages/parser) --- updated-dependencies: - dependency-name: "@typescript-eslint/parser" dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…dation#2252) Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 20.12.5 to 20.12.7. - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node) --- updated-dependencies: - dependency-name: "@types/node" dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…2248) Bumps [mongoose](https://github.com/Automattic/mongoose) from 8.3.1 to 8.3.2. - [Release notes](https://github.com/Automattic/mongoose/releases) - [Changelog](https://github.com/Automattic/mongoose/blob/master/CHANGELOG.md) - [Commits](Automattic/mongoose@8.3.1...8.3.2) --- updated-dependencies: - dependency-name: mongoose dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…oesFoundation#2250) Bumps [@graphql-tools/utils](https://github.com/ardatan/graphql-tools/tree/HEAD/packages/utils) from 10.1.2 to 10.1.3. - [Release notes](https://github.com/ardatan/graphql-tools/releases) - [Changelog](https://github.com/ardatan/graphql-tools/blob/master/packages/utils/CHANGELOG.md) - [Commits](https://github.com/ardatan/graphql-tools/commits/@graphql-tools/[email protected]/packages/utils) --- updated-dependencies: - dependency-name: "@graphql-tools/utils" dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
PalisadoesFoundation#2251) Bumps [@typescript-eslint/eslint-plugin](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin) from 7.6.0 to 7.7.0. - [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases) - [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/CHANGELOG.md) - [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v7.7.0/packages/eslint-plugin) --- updated-dependencies: - dependency-name: "@typescript-eslint/eslint-plugin" dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…tion#2254) * Added a unit test for app user profile * Updated 100% coverage for updateAdvertisement * ran prettier * fixed linting error * Ran prettier again * Changed user to users * Added a field level resolver for Users * Removed redundant isNote boolean type * Added a new note model * Added mutation resolvers for notes * Added queries for notes * test * Added tests for delta files * Ran prettier * Added necessary tests for note specific queries * Fixed formatting errors * Minor changes * test * Test * format fix --------- Co-authored-by: Peter Harrison <[email protected]>
…Foundation#2256) - Adjusted permissions checks to allow superadmins to delete fundraising campaigns as intended. - Adjusted permissions checks to allow admins of the organization to delete fundraising campaigns as intended. - Ensured no other functionality got affected. - Ensured all the tests are passing succesfully. Signed-off-by: Akhilender <[email protected]>
…oesFoundation#2261) - Ensure the videos directory is present before executing tests to prevent failures due to its absence. Signed-off-by: Akhilender <[email protected]>
…ation#2226) * fix: invalid url error while fetching advertisements * fix: failing tests * fix: failing tests * fix: formatting issues * improved code coverage
* Added new media directories * Changed order for .gitignore file * Added media directories * Updated media directory files * Removed references to files in media directories * Removed log/README.md reference
…oesFoundation#2269) * Reordered installation steps * Reordered installation steps v2 * Fixes 2268 * Fixed TOC
* Updated the installation steps. Fixes PalisadoesFoundation#2268 * Fixes PalisadoesFoundation#2268 v2 * Fixed bullet indentation
* Refactor MongoDB.ts to use existingMongoDbUrls variable instead of an array * added tests * clear mock after each * . * Update schema.graphql * Update schema.graphql * Update schema.graphql * Update schema.graphql * Update pre-commit * Revert "Update pre-commit" This reverts commit 6134b5a. * Update pre-commit * comment
* Fixes PalisadoesFoundation#2268 - Ubuntu docker-compose Path * Removed Dockerfile* from .dockerignore
…ndation#2277) Bumps [@apollo/server](https://github.com/apollographql/apollo-server/tree/HEAD/packages/server) from 4.10.2 to 4.10.4. - [Release notes](https://github.com/apollographql/apollo-server/releases) - [Changelog](https://github.com/apollographql/apollo-server/blob/main/packages/server/CHANGELOG.md) - [Commits](https://github.com/apollographql/apollo-server/commits/@apollo/[email protected]/packages/server) --- updated-dependencies: - dependency-name: "@apollo/server" dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
) Bumps [ioredis](https://github.com/luin/ioredis) from 5.3.2 to 5.4.1. - [Release notes](https://github.com/luin/ioredis/releases) - [Changelog](https://github.com/redis/ioredis/blob/main/CHANGELOG.md) - [Commits](redis/ioredis@v5.3.2...v5.4.1) --- updated-dependencies: - dependency-name: ioredis dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [tsx](https://github.com/privatenumber/tsx) from 4.7.2 to 4.7.3. - [Release notes](https://github.com/privatenumber/tsx/releases) - [Changelog](https://github.com/privatenumber/tsx/blob/master/release.config.cjs) - [Commits](privatenumber/tsx@v4.7.2...v4.7.3) --- updated-dependencies: - dependency-name: tsx dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…Foundation#2280) Bumps [@vitest/coverage-v8](https://github.com/vitest-dev/vitest/tree/HEAD/packages/coverage-v8) from 1.5.0 to 1.5.2. - [Release notes](https://github.com/vitest-dev/vitest/releases) - [Commits](https://github.com/vitest-dev/vitest/commits/v1.5.2/packages/coverage-v8) --- updated-dependencies: - dependency-name: "@vitest/coverage-v8" dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…dation#2281) Bumps [@types/i18n](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/i18n) from 0.13.10 to 0.13.12. - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/i18n) --- updated-dependencies: - dependency-name: "@types/i18n" dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* feat: prompt server port during setup * fix: parseInt for env * fix: SERVER_PORT in github env * fix:set SERVER_PORT as env * refactor: remove console log * fix: positioning of text
…Foundation#2287) Bumps [@types/nodemailer](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/nodemailer) from 6.4.14 to 6.4.15. - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/nodemailer) --- updated-dependencies: - dependency-name: "@types/nodemailer" dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…oesFoundation#2288) Bumps [@graphql-tools/utils](https://github.com/ardatan/graphql-tools/tree/HEAD/packages/utils) from 10.1.3 to 10.2.0. - [Release notes](https://github.com/ardatan/graphql-tools/releases) - [Changelog](https://github.com/ardatan/graphql-tools/blob/master/packages/utils/CHANGELOG.md) - [Commits](https://github.com/ardatan/graphql-tools/commits/@graphql-tools/[email protected]/packages/utils) --- updated-dependencies: - dependency-name: "@graphql-tools/utils" dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…on#2652) Bumps [globals](https://github.com/sindresorhus/globals) from 15.11.0 to 15.12.0. - [Release notes](https://github.com/sindresorhus/globals/releases) - [Commits](sindresorhus/globals@v15.11.0...v15.12.0) --- updated-dependencies: - dependency-name: globals dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…oesFoundation#2662) Bumps [@aws-sdk/client-s3](https://github.com/aws/aws-sdk-js-v3/tree/HEAD/clients/client-s3) from 3.675.0 to 3.691.0. - [Release notes](https://github.com/aws/aws-sdk-js-v3/releases) - [Changelog](https://github.com/aws/aws-sdk-js-v3/blob/main/clients/client-s3/CHANGELOG.md) - [Commits](https://github.com/aws/aws-sdk-js-v3/commits/v3.691.0/clients/client-s3) --- updated-dependencies: - dependency-name: "@aws-sdk/client-s3" dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…Foundation#2663) Bumps [@vitest/coverage-v8](https://github.com/vitest-dev/vitest/tree/HEAD/packages/coverage-v8) from 2.1.3 to 2.1.5. - [Release notes](https://github.com/vitest-dev/vitest/releases) - [Commits](https://github.com/vitest-dev/vitest/commits/v2.1.5/packages/coverage-v8) --- updated-dependencies: - dependency-name: "@vitest/coverage-v8" dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…oesFoundation#2665) Bumps [@graphql-inspector/cli](https://github.com/kamilkisiela/graphql-inspector/tree/HEAD/packages/cli) from 5.0.6 to 5.0.7. - [Release notes](https://github.com/kamilkisiela/graphql-inspector/releases) - [Changelog](https://github.com/kamilkisiela/graphql-inspector/blob/master/packages/cli/CHANGELOG.md) - [Commits](https://github.com/kamilkisiela/graphql-inspector/commits/@graphql-inspector/[email protected]/packages/cli) --- updated-dependencies: - dependency-name: "@graphql-inspector/cli" dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…curity] (PalisadoesFoundation#2660) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
…on#2694) * Updated Pull Request Template to Enforce Standards * Updated the changes for pull_request_template.md * Update .github/pull_request_template.md Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> * feat: Changed the pr-template file as per changes. * feat: refactor checklist given by coderabbit. --------- Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
* getVolunteerRanks test fix * test fix
* added installation script * shell.nix file * nix script * nix flakes * made script cross-platform * test * test * test * test * test * test * test * test * fix nix flake * fix * fix * fix * fix * added dev container for devpods * fix * fix * fix * fix * fix * temp fix * temp fix * temp fix * temp fix * temp fix * shell.nix file * removed nix file * fix * docker file * fix * fix * fix * fix * made changes * Update INSTALLATION.md * Update INSTALLATION.md * made changes * Update INSTALLATION.md * fix docker file
…ation#2715) * Adding a new dependency nodemon to get rid of the experimental warning * Resolving conflicts in the package-lock.json * Adding suggestions from coderabbit and removing unecessary changes in the installation.md * Removing irrelevant changes in the installation.md --------- Co-authored-by: root <root@JARVIS>
* Removing eslintrc.json and eslintignore * resolving the flaky voluteenrank test
…lisadoesFoundation#2751) * added changes and venue.json * Update getVolunteerRanks.spec.ts * Update getVolunteerRanks.spec.ts * Update getVolunteerRanks.spec.ts * Update getVolunteerRanks.spec.ts * Update setup.ts
…security] (PalisadoesFoundation#2752) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
…eck (PalisadoesFoundation#2770) * updated setup.ts to support docker compose v2 * updated setup.ts to support docker compose v1 and v2 * removed erroneous empty gql block from unions.ts * improved error and time handling in setup.ts * fixed incorrect test * removed debug log * removed minio.deb which got committed by mistake
…esFoundation#2538 (PalisadoesFoundation#2766) * Update package.json * Update package-lock.json * Update tsconfig.json * Update createVenue.ts * Update tsconfig.json * Update tsconfig.json * Update createVenue.spec.ts * Updated format
…alisadoesFoundation/talawa-admin#1873) (PalisadoesFoundation#2753) * Fixed: issue-PalisadoesFoundation#1873 * test file updated-1 * test file updated-1-a
Important Review skippedMore than 25% of the files skipped due to max files limit. The review is being skipped to prevent a low-quality review. 82 files out of 280 files are above the max files limit of 75. Please upgrade to Pro plan to get higher limits. You can disable this status message by setting the Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
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)
Other keywords and placeholders
Documentation and Community
|
Our Pull Request Approval ProcessThanks for contributing! Testing Your CodeRemember, your PRs won't be reviewed until these criteria are met:
Our policies make our code better. ReviewersDo not assign reviewers. Our Queue Monitors will review your PR and assign them.
Reviewing Your CodeYour reviewer(s) will have the following roles:
CONTRIBUTING.mdRead our CONTRIBUTING.md file. Most importantly:
Other
|
Please submit your PRs against our Also if applicable, make sure your branch name is different from Closing. |
@palisadoes are u talking about my branch or upstream branch? Means upstream branch should be different than develop means it should develop-postgress or what? |
Base your PR against the latest |
What kind of change does this PR introduce?
This PR introduces a resource optimization enhancement for Docker Compose configurations. It dynamically adjusts CPU and memory limits and reservations for all containers based on available system resources, ensuring smooth operation on systems with minimal specs (1 core, 2 GB RAM).
Issue Number:
Fixes #2730
Did you add tests for your changes?
No not required as it is a dockerCompose File.
Snapshots/Videos:
This is video of container running on Docker
https://github.com/user-attachments/assets/2935ec31-266d-4d90-9048-31ae880d5d41
This one is without docker means out main code is running
https://github.com/user-attachments/assets/b16de757-16a2-4cd3-a85f-b9224873a785
If relevant, did you update the documentation?
No all things are already there in documentation
Summary
1.Set appropriate limits and reservations for each container (e.g., MongoDB, Redis, MinIO, Talawa API, and Caddy) to ensure smooth operation on a minimum spec system (1 core CPU, 2 GB RAM, 40 GB storage).
2.Prevents resource contention and reduces swap usage by balancing container demands.
3.This update provides a more flexible and efficient containerized deployment for Talawa API and its dependencies.
Does this PR introduce a breaking change?
No breaking changes are there.
Other information
1.Once the application is stable and the npm run prod command runs successfully, it is recommended to use npm run prod instead of npm run dev for better performance in production environments. This reduces overhead caused by development-specific features like watchers and live reloads.
2.Use the docker system prune command periodically to remove unnecessary images, containers, and volumes. This helps reduce disk space usage and keeps the system clean.
3.Disabling file watchers in development mode and setting appropriate resource limits as defined in the updated configuration can significantly improve performance, especially on systems with limited resources.
Have you read the contributing guide?
Yes