mirror of
https://github.com/ToolJet/ToolJet
synced 2026-05-22 16:38:21 +00:00
* statement timeout for postgresql mssql mysql can now be configured from env * Enhance: Add clear all, cancel & apply functionality to TJDB filter-popup (#2344) * Update filter inputs * Update filter body * Style fixes * Handle invalid filters * Fix bugs * Feature: Add list all sheets and create new spreadsheet operation to GoogleSheets (#2370) * Add create spreadsheet functionality * Add list all sheets functionality * Updated delete and batch-update methods * Change interface to type * Enhance: Add read documentation link with data source drop down in query builder (#2162) * Add read-documentation link * Change copywriting for datasources name * Update new component for link * Increase input width Update redshift link * Fix the datasource name issue * Enhance: Improve error handling in Google-Sheets run query (#2286) * Add error details * Display error for incorrect JSON * Throw error for empty spreadsheetid and operator * Enhance: Error handling for PgSql, MySql and MsSql (#2389) * Enhance error handling for pgsql * Enhance error handling for mysql * Remove console logs * Enhance error handling for MsSql * Refactor error handling for consistency * Enhance: Rest api body to accept raw input instead of raw json. (#2249) * Enhanced rest api body to accept raw input instead of raw json. * Changed content type from application/json to text/json and changed copywrite to RAW. * Changed rest api body toggle label from 'RAW' to 'Raw'. * Added request label for static REST API data source. * Fixed issue where GET query failed since body was undefined. * Integrated json_body to add backward compatibility. * Removed console logs. * Added support for 'text/json' type in checkIfContentTypeIsJson function. * Made changes according to new frontend architecture in v3. * Fixed request URL field overflow issue. --------- Co-authored-by: Akshay Sasidharan <akshaysasidharan93@gmail.com> * Feature: Add SSL support to MongoDB datasource (#2430) * Add TLS support inputs in frontend * Add backend logic for TLS support * Add TLS inputs types * Update TLS label * Change ssl_certificate to tls_certificate * Update the file handling in tls * Update connection logic * Fix unlinking file issue * Remove catch block for unlinking file * Handle tls certs directly * Feature: Stripe plugin UI fixes with OpenAPI endpoint as source (#2725) * Fixed GET and DELETE request input renders and added all UX fixes (#9498) * fixed get and delete request input renders and added all UX fixes * Extracted Stripe plugin component as a separate component for Dynamic Form. * Resolved PR review comments and fixed issue where rendering path input field crashed the app. * Changed param name underline to dashed for tooltip and revamped input field clear button * Fixed a few sonarlint issues. * Removed the duplicate code by creating a separate function named RenderParameterFields. * Refactored computeOperationSelectionOptions function to not nest functions more than 4 levels deep. * Refactored RenderParameterFields function to reduce its Cognitive Complexity. * Made span tag with the 'button' interactive role focusable. * Inside switch case for codehinter in DynamicForm > getElementProps, Extracted nested ternary operation for theme into an independent statement. * Added keyboard listener to the clear button. * Removed opacity from select dropdown and operation from operation select dropdown UI. * Fixed syntax error in clearButton function. * Removed the package @nrwl/nx-linux-x64-gnu from marketplace dependencies. --------- Co-authored-by: Mansukh Kaur <mansukhkaur@Mansukhs-MacBook-Pro.local> Co-authored-by: Devanshu Rastogi <devanshu.rastogi05@gmail.com> * Made changes according to new app builder architecture in v3. * Fixed import issue for codehintor * Fixed issue where due to incorrect value, stripe queries crashed the entire app. --------- Co-authored-by: Mansukh Kaur <mansukhkaur@Mansukhs-MacBook-Pro.local> Co-authored-by: Devanshu Rastogi <devanshu.rastogi05@gmail.com> * Enhance: Improve error handling in Airtable run query (#2234) * Refactor error handling to streamline QueryError messages * Handle 404 errors * Enhance: Add AI-tag to datasources in marketplace page (#2597) * Add AI-tag to datasources in marketplace page * AI BANNER Tag * margin * Refactor tag rendering logic for marketplace page * Refactor tag rendering for datasource page * Refactor import and props * Remove ai prefix and fix indentations * Make custom hook for fetching plugins.json * Add AI tag on installed page * Marketplace page UI fix and add a plugin button fixes * Add AI tag on datasource connection form Change classname * Fix svg flickering * Fix svg chipping issue * Push AI tag to extreme right --------- Co-authored-by: Rudra <rudra21ultra@gmail.com> * Fix: Api call for token generation in client-credentials grant type (#2785) * fix: query kind for select source in rest api * Fix: ToolJet database limit check API issue (#11416) * bump to v3.0.5-ce * Added data-cy for newly added components (#11435) * Modified failed Platform cypress test cases for Tooljet V3 (#11486) * Modify platform cypress test cases * Added cypress test cases for user onboarding flow (#11499) * Add data-cy for newly added components * Add data-cy for onboarding page elements * Modify failed test cases * Adding more cases * Modify onboarding test cases * Modify user invite flow * chnages on onboarding test scripts * revert the changes * revert the changes * removed .only form profile file * resolved review changes --------- Co-authored-by: ajith-k-v <ajith.jaban@gmail.com> Co-authored-by: Sri mani Teja s <mani@Sris-MacBook-Pro-4.local> * fix: Fixes broken loading state for container * update cypress workflow for subpath * Add data-cy for workspace constants components (#11530) * fix table down load event not showing up * Hotfix: The build failed to include the reference file for custom validation of the ToolJet database schema. (#11490) * tooljet database schema custom validation reference file was not included in the build * fix: missed a dependency for copyfiles * change version to 3.1.0 --------- Co-authored-by: Ganesh Kumar <ganesh8056234@gmail.com> Co-authored-by: Parth <108089718+parthy007@users.noreply.github.com> Co-authored-by: Devanshu Rastogi <devanshu.rastogi05@gmail.com> Co-authored-by: Akshay Sasidharan <akshaysasidharan93@gmail.com> Co-authored-by: Mansukh Kaur <mansukhkaur@Mansukhs-MacBook-Pro.local> Co-authored-by: Rudra <rudra21ultra@gmail.com> Co-authored-by: Vijaykant Yadav <vjy239@gmail.com> Co-authored-by: Ganesh Kumar <40178541+ganesh8056@users.noreply.github.com> Co-authored-by: Ajith KV <ajith.jaban@gmail.com> Co-authored-by: Adish M <44204658+adishM98@users.noreply.github.com> Co-authored-by: Srimanitejas123 <mani@tooljet.com> Co-authored-by: Sri mani Teja s <mani@Sris-MacBook-Pro-4.local> Co-authored-by: Nithin David Thomas <1277421+nithindavid@users.noreply.github.com> Co-authored-by: Kartik Gupta <gupta.kartik18kg@gmail.com>
230 lines
8.6 KiB
YAML
230 lines
8.6 KiB
YAML
name: Cypress Platform
|
|
|
|
on:
|
|
pull_request_target:
|
|
types: [labeled, unlabeled, closed]
|
|
|
|
workflow_dispatch:
|
|
|
|
env:
|
|
PR_NUMBER: ${{ github.event.number }}
|
|
BRANCH_NAME: ${{ github.head_ref || github.ref_name }}
|
|
|
|
jobs:
|
|
Cypress-Platform:
|
|
runs-on: ubuntu-22.04
|
|
|
|
if: ${{ github.event.action == 'labeled' && (github.event.label.name == 'run-cypress-workspace' || github.event.label.name == 'run-cypress') }}
|
|
|
|
steps:
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v2
|
|
with:
|
|
node-version: 18.18.2
|
|
|
|
- name: Set up Docker
|
|
uses: docker-practice/actions-setup-docker@master
|
|
|
|
- name: Run PosgtreSQL Database Docker Container
|
|
run: |
|
|
sudo docker network create tooljet
|
|
sudo docker run -d --name postgres -p 5432:5432 -e POSTGRES_PASSWORD=postgres -e POSTGRES_USER=postgres -e POSTGRES_PORT=5432 -d postgres:13
|
|
|
|
- name: Checkout
|
|
uses: actions/checkout@v3
|
|
with:
|
|
ref: ${{ github.event.pull_request.head.ref }}
|
|
|
|
- name: Install and build dependencies
|
|
run: |
|
|
npm cache clean --force
|
|
npm install
|
|
npm install --prefix server
|
|
npm install --prefix frontend
|
|
npm run build:plugins
|
|
|
|
- name: Set up environment variables
|
|
run: |
|
|
echo "TOOLJET_HOST=http://localhost:8082" >> .env
|
|
echo "LOCKBOX_MASTER_KEY=cd97331a419c09387bef49787f7da8d2a81d30733f0de6bed23ad8356d2068b2" >> .env
|
|
echo "SECRET_KEY_BASE=7073b9a35a15dd20914ae17e36a693093f25b74b96517a5fec461fc901c51e011cd142c731bee48c5081ec8bac321c1f259ef097ef2a16f25df17a3798c03426" >> .env
|
|
echo "PG_DB=tooljet_development" >> .env
|
|
echo "PG_USER=postgres" >> .env
|
|
echo "PG_HOST=localhost" >> .env
|
|
echo "PG_PASS=postgres" >> .env
|
|
echo "PG_PORT=5432" >> .env
|
|
echo "ENABLE_TOOLJET_DB=true" >> .env
|
|
echo "TOOLJET_DB=tooljet" >> .env
|
|
echo "TOOLJET_DB_USER=postgres" >> .env
|
|
echo "TOOLJET_DB_HOST=localhost" >> .env
|
|
echo "TOOLJET_DB_PASS=postgres" >> .env
|
|
echo "PGRST_JWT_SECRET=r9iMKoe5CRMgvJBBtp4HrqN7QiPpUToj" >> .env
|
|
echo "ENABLE_ONBOARDING_QUESTIONS_FOR_ALL_SIGN_UPS=true" >> .env
|
|
echo "PGRST_HOST=localhost:3001" >> .env
|
|
echo "SSO_GIT_OAUTH2_CLIENT_ID=dummy" >> .env
|
|
echo "SSO_GIT_OAUTH2_CLIENT_SECRET=dummy" >> .env
|
|
echo "SSO_GIT_OAUTH2_HOST=dummy" >> .env
|
|
echo "SSO_GOOGLE_OAUTH2_CLIENT_ID=dummy" >> .env
|
|
echo "ENABLE_PRIVATE_APP_EMBED=true" >> .env
|
|
echo "ENABLE_MARKETPLACE_FEATURE=true" >> .env
|
|
echo "ENABLE_MARKETPLACE_DEV_MODE=true" >> .env
|
|
echo "TOOLJET_DB_STATEMENT_TIMEOUT=60000" >> .env
|
|
echo "TOOLJET_DB_RECONFIG=true" >> .env
|
|
|
|
- name: Set up database
|
|
run: |
|
|
npm run --prefix server db:create
|
|
npm run --prefix server db:reset
|
|
npm run --prefix server db:seed
|
|
|
|
- name: sleep 5
|
|
run: sleep 5
|
|
|
|
- name: Run PostgREST Docker Container
|
|
run: |
|
|
sudo docker run -d --name postgrest --network tooljet -p 3001:3000 \
|
|
-e PGRST_DB_URI="postgres://postgres:postgres@postgres:5432/tooljet" -e PGRST_DB_ANON_ROLE="postgres" -e PGRST_JWT_SECRET="r9iMKoe5CRMgvJBBtp4HrqN7QiPpUToj" -e PGRST_DB_PRE_CONFIG=postgrest.pre_config \
|
|
postgrest/postgrest:v12.2.0
|
|
|
|
- name: Run plugins compilation in watch mode
|
|
run: cd plugins && npm start &
|
|
|
|
- name: Run the server
|
|
run: cd server && npm run start:dev &
|
|
|
|
- name: Run the client
|
|
run: cd frontend && npm start &
|
|
|
|
- name: Wait for the server to be ready
|
|
run: |
|
|
timeout 1500 bash -c '
|
|
until curl --silent --fail http://localhost:8082; do
|
|
sleep 5
|
|
done'
|
|
|
|
- name: docker logs
|
|
run: sudo docker logs postgrest
|
|
|
|
- name: Create Cypress environment file
|
|
id: create-json
|
|
uses: jsdaniell/create-json@1.1.2
|
|
with:
|
|
name: "cypress.env.json"
|
|
json: ${{ secrets.CYPRESS_SECRETS }}
|
|
dir: "./cypress-tests"
|
|
|
|
- name: Platform
|
|
uses: cypress-io/github-action@v5
|
|
with:
|
|
working-directory: ./cypress-tests
|
|
config: "baseUrl=http://localhost:8082"
|
|
config-file: cypress-workspace.config.js
|
|
|
|
- name: Capture Screenshots
|
|
uses: actions/upload-artifact@v3
|
|
if: always()
|
|
with:
|
|
name: screenshots
|
|
path: cypress-tests/cypress/screenshots
|
|
|
|
Cypress-Platform-subpath:
|
|
runs-on: ubuntu-22.04
|
|
|
|
if: ${{ github.event.action == 'labeled' && github.event.label.name == 'run-cypress-workspace-subpath' }}
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v3
|
|
with:
|
|
ref: ${{ github.event.pull_request.head.ref }}
|
|
|
|
# Create Docker Buildx builder with platform configuration
|
|
- name: Set up Docker Buildx
|
|
run: |
|
|
mkdir -p ~/.docker/cli-plugins
|
|
curl -SL https://github.com/docker/buildx/releases/download/v0.11.0/buildx-v0.11.0.linux-amd64 -o ~/.docker/cli-plugins/docker-buildx
|
|
chmod a+x ~/.docker/cli-plugins/docker-buildx
|
|
docker buildx create --name mybuilder --platform linux/arm64,linux/amd64,linux/amd64/v2,linux/riscv64,linux/ppc64le,linux/s390x,linux/386,linux/mips64le,linux/mips64,linux/arm/v7,linux/arm/v6
|
|
docker buildx use mybuilder
|
|
|
|
- name: Set DOCKER_CLI_EXPERIMENTAL
|
|
run: echo "DOCKER_CLI_EXPERIMENTAL=enabled" >> $GITHUB_ENV
|
|
|
|
- name: use mybuilder buildx
|
|
run: docker buildx use mybuilder
|
|
|
|
- name: Build docker image
|
|
run: docker buildx build --platform=linux/amd64 -f docker/production.Dockerfile . -t tooljet/tj-osv:cypressplaform
|
|
|
|
- name: Set up environment variables
|
|
run: |
|
|
echo "TOOLJET_HOST=http://localhost:80" >> .env
|
|
echo "LOCKBOX_MASTER_KEY=cd97331a419c09387bef49787f7da8d2a81d30733f0de6bed23ad8356d2068b2" >> .env
|
|
echo "SECRET_KEY_BASE=7073b9a35a15dd20914ae17e36a693093f25b74b96517a5fec461fc901c51e011cd142c731bee48c5081ec8bac321c1f259ef097ef2a16f25df17a3798c03426" >> .env
|
|
echo "PG_DB=tooljet_development" >> .env
|
|
echo "PG_USER=postgres" >> .env
|
|
echo "PG_HOST=postgres" >> .env
|
|
echo "PG_PASS=postgres" >> .env
|
|
echo "PG_PORT=5432" >> .env
|
|
echo "ENABLE_TOOLJET_DB=true" >> .env
|
|
echo "TOOLJET_DB=tooljet_db" >> .env
|
|
echo "TOOLJET_DB_USER=postgres" >> .env
|
|
echo "TOOLJET_DB_HOST=postgres" >> .env
|
|
echo "TOOLJET_DB_PASS=postgres" >> .env
|
|
echo "PGRST_JWT_SECRET=r9iMKoe5CRMgvJBBtp4HrqN7QiPpUToj" >> .env
|
|
echo "PGRST_HOST=postgrest" >> .env
|
|
echo "PGRST_DB_URI=postgres://postgres:postgres@postgres/tooljet_db" >> .env
|
|
echo "ENABLE_ONBOARDING_QUESTIONS_FOR_ALL_SIGN_UPS=true" >> .env
|
|
echo "SSO_GIT_OAUTH2_CLIENT_ID=dummy" >> .env
|
|
echo "SSO_GIT_OAUTH2_CLIENT_SECRET=dummy" >> .env
|
|
echo "SSO_GIT_OAUTH2_HOST=dummy" >> .env
|
|
echo "SSO_GOOGLE_OAUTH2_CLIENT_ID=dummy" >> .env
|
|
echo "SUB_PATH=/apps/tooljet/" >> .env
|
|
echo "NODE_ENV=production" >> .env
|
|
echo "SERVE_CLIENT=true" >> .env
|
|
echo "ENABLE_MARKETPLACE_FEATURE=true" >> .env
|
|
echo "ENABLE_MARKETPLACE_DEV_MODE=true" >> .env
|
|
|
|
- name: Pulling the docker-compose file
|
|
run: curl -LO https://tooljet-test.s3.us-west-1.amazonaws.com/docker-compose.yaml && mkdir postgres_data
|
|
|
|
- name: Run docker-compose file
|
|
run: docker-compose up -d
|
|
|
|
- name: Checking containers
|
|
run: docker ps -a
|
|
|
|
- name: docker logs
|
|
run: sudo docker logs Tooljet-app
|
|
|
|
- name: Wait for the server to be ready
|
|
run: |
|
|
timeout 1500 bash -c '
|
|
until curl --silent --fail http://localhost:80/apps/tooljet/; do
|
|
sleep 5
|
|
done'
|
|
|
|
- name: Seeding
|
|
run: docker exec Tooljet-app npm run db:seed:prod
|
|
|
|
- name: Create Cypress environment file
|
|
id: create-json
|
|
uses: jsdaniell/create-json@1.1.2
|
|
with:
|
|
name: "cypress.env.json"
|
|
json: ${{ secrets.CYPRESS_SECRETS_SUBPATH }}
|
|
dir: "./cypress-tests"
|
|
|
|
- name: Platform-subpath
|
|
uses: cypress-io/github-action@v5
|
|
with:
|
|
working-directory: ./cypress-tests
|
|
config: "baseUrl=http://localhost:80/apps/tooljet/"
|
|
config-file: cypress-workspace.config.js
|
|
|
|
- name: Capture Screenshots
|
|
uses: actions/upload-artifact@v3
|
|
if: always()
|
|
with:
|
|
name: screenshots
|
|
path: cypress-tests/cypress/screenshots
|