From 93410356a67e6b4ad80f056dd35d5943cdc64d4a Mon Sep 17 00:00:00 2001 From: Ubuntu Date: Tue, 20 Jun 2023 03:06:24 +0000 Subject: [PATCH] Squashed commits --- .github/ISSUE_TEMPLATE /c4gt.md | 96 +++++++++++++++++++ .../ISSUE_TEMPLATE/c4gt-community-ticket.md | 58 +++++++++++ .github/workflows/smoke-test.yml | 18 ++++ docker-compose.yml | 3 +- 4 files changed, 174 insertions(+), 1 deletion(-) create mode 100644 .github/ISSUE_TEMPLATE /c4gt.md create mode 100644 .github/ISSUE_TEMPLATE/c4gt-community-ticket.md diff --git a/.github/ISSUE_TEMPLATE /c4gt.md b/.github/ISSUE_TEMPLATE /c4gt.md new file mode 100644 index 00000000..e3cbd23d --- /dev/null +++ b/.github/ISSUE_TEMPLATE /c4gt.md @@ -0,0 +1,96 @@ +--- +name: C4GT +about: C4GT Community Issues Template +title: "[C4GT] Button for likes" +labels: C4GT Community +assignees: '' + +--- + +## Description +[Provide a brief description of the feature, including why it is needed and what it will accomplish. You can skip any of Goals, Expected Outcome, Implementation Details, Mockups / Wireframes if they are irrelevant] + +## Goals +- [ ] [Goal 1] +- [ ] [Goal 2] +- [ ] [Goal 3] +- [ ] [Goal 4] +- [ ] [Goal 5] + +## Expected Outcome +[Describe in detail what the final product or result should look like and how it should behave.] + +## Acceptance Criteria +- [ ] [Criteria 1] +- [ ] [Criteria 2] +- [ ] [Criteria 3] +- [ ] [Criteria 4] +- [ ] [Criteria 5] + +## Implementation Details +[List any technical details about the proposed implementation, including any specific technologies that will be used.] + +## Mockups / Wireframes +[Include links to any visual aids, mockups, wireframes, or diagrams that help illustrate what the final product should look like. This is not always necessary, but can be very helpful in many cases.] + +--- + +### Project +[Project Name] + +### Organization Name: +[Organization Name] + +### Domain +[Area of governance] + + + +### Tech Skills Needed: +[Required technical skills for the project] + +### Mentor(s) +[@Mentor1] [@Mentor2] [@Mentor3] + +### Complexity +Pick one of [High]/[Medium]/[Low] + +### Category +Pick one or more of [CI/CD], [Integrations], [Performance Improvement], [Security], [UI/UX/Design], [Bug], [Feature], [Documentation], [Deployment], [Test], [PoC] + +### Sub Category +Pick one or more of [API], [Database], [Analytics], [Refactoring], [Data Science], [Machine Learning], [Accessibility], [Internationalization], [Localization], [Frontend], [Backend], [Mobile], [SEO], [Configuration], [Deprecation], [Breaking Change], [Maintenance], [Support], [Question], [Technical Debt], [Beginner friendly], [Research], [Reproducible], [Needs Reproduction]. diff --git a/.github/ISSUE_TEMPLATE/c4gt-community-ticket.md b/.github/ISSUE_TEMPLATE/c4gt-community-ticket.md new file mode 100644 index 00000000..2b9a3fce --- /dev/null +++ b/.github/ISSUE_TEMPLATE/c4gt-community-ticket.md @@ -0,0 +1,58 @@ +--- +name: C4GT Community Ticket +about: C4GT Community Ticket +title: C4GT +labels: C4GT Community +assignees: '' + +--- + +## Description +There is a need for a commenting system that will allow users to interact with the blog posts. This will increase user engagement and provide feedback to the blog authors. + +## Goals +- [ ] Add a comment section to each blog post +- [ ] Implement a moderation system for comments +- [ ] Ensure comments are tied to a registered user +- [ ] Implement spam and bot protection for the comments +- [ ] Add notification system for new comments + +## Expected Outcome +- Users must be registered and logged in to leave a comment. +- Each comment should include the user's name, profile picture (if available), comment text, and timestamp. +- Comments should be displayed in chronological order, with the most recent comment at the top. +- An email notification should be sent to the blog post author when a new comment is made. +- Blog post authors and administrators should be able to moderate comments (approve, deny, delete). + +## Acceptance Criteria +- [ ] A registered user can submit a comment on a blog post. +- [ ] The comment appears on the blog post after approval from the post author or administrator. +- [ ] An email notification is sent to the blog post author when a new comment is posted. +- [ ] Comments can be moderated by the blog post author and administrators. +- [ ] Commenting system is resistant to spam and bot attacks. + +## Implementation Details +- Leverage Django's built-in commenting framework (if applicable) +- Use JavaScript and AJAX for real-time comment posting and updates +- Consider integrating with a service like Akismet for spam protection +- Use Django's built-in email function for the notification system + +## Mockups / Wireframes +(Here, you can link to any visual aids, mockups, wireframes, or diagrams that help illustrate what the final product should look like. This is not always necessary, but can be very helpful in many cases.) + +--- + +### Project +OpenBlog Platform + +### Organization Name: +The name of the organization proposing the project. + +### Domain +The area of governance the project pertains to (ex: agri, healthcare, ed etc). + +### Tech Skills Needed: +Django, Typescript, NextJS, Akismet + +### Mentor(s) +@ChakshuGautam @Shruti3004 @sukhpreetssekhon diff --git a/.github/workflows/smoke-test.yml b/.github/workflows/smoke-test.yml index 6ca64f0d..b490b693 100644 --- a/.github/workflows/smoke-test.yml +++ b/.github/workflows/smoke-test.yml @@ -37,6 +37,24 @@ jobs: - name: Install psql run: sudo apt install postgresql-client + - name: Set Max Connection Limit + run: | + export PGHOST=localhost + export PGUSER=postgres + export PGPASSWORD=test1234 + psql -h localhost -U postgres -c "ALTER SYSTEM SET max_connections = '100';" + + - name: Verify Max Connection Limit + run: | + export PGHOST=localhost + export PGUSER=postgres + export PGPASSWORD=test1234 + MAX_CONNECTIONS=$(PGPASSWORD=test1234 psql -h localhost -U postgres -d postgres -c "SHOW max_connections;" | grep -oP '(?<=row )[0-9]+') + if [ "$MAX_CONNECTIONS" -ne "10" ]; then + echo "Max connections is not set correctly!" + exit 1 + fi + - name: Run the smoke test run: | set -eu diff --git a/docker-compose.yml b/docker-compose.yml index 2141a4f6..c985af72 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -11,7 +11,8 @@ services: environment: POSTGRES_USER: timescaledb POSTGRES_PASSWORD: postgrespassword - + POSTGRES_MAX_CONNECTIONS: 10 + graphql-engine: image: hasura/graphql-engine:latest ports: