PromucFlow_constructor/app/client/netlify.toml

70 lines
2.4 KiB
TOML
Raw Normal View History

Use injected configuration from Nginx at runtime instead of build time (#30) * Use envsubst and nginx templates to generate nginx configs which can substitute environment variables and inject into the index.html file * Fix path in dockerfile. Add .gitignore and .env.example files. Fix nginx-linux template. * Add all environment variables. Add prefix to all environment variables. Update scripts to attempt to substitute all environment variables with the prefix * Setup dockerfile to execute a bash script. use env.example for fetching environment variables in development * Toggle features based on injected configs. Fix nginx template substitution script. * Update env.example file * Remove debug code from start-nginx.sh * Fix nginx config templates by adding quotes by default. Fix sed regex to include numerals. Toggle social login buttons on Login page based on the config. * Update rapid api environment variable name. Toggle oauth buttons based on config in SignUp page. Update .env.example to be a union of server and client environment variables * Adding a Map disabled message on Map widget * Adding links to Privacy policy and TNC * Use REACT_APP_ env variables with higher priority over injected config variables for toggling features * Update netlify.toml by commenting out the build environment variables * Remove env variables not required by the client * Remove start-storybook entry from package.json * Fix netlify.toml. Fallback algolia configs * Add contexts to netlify.toml for successful deploys. Swith to using APPSMITH_MARKETPLACE_URL as the toggle for RapidAPI feature on the client. Remove comments in nginx config templates. Fix template used in dockerfile. Co-authored-by: Satbir Singh <apple@apples-MacBook-Pro.local> Co-authored-by: Satbir Singh <satbir121@gmail.com>
2020-07-07 10:22:17 +00:00
[build]
[build.environment]
REACT_APP_OAUTH2_GOOGLE_CLIENT_ID = "enabled"
REACT_APP_OAUTH2_GITHUB_CLIENT_ID = "enabled"
REACT_APP_ALGOLIA_API_ID = "AZ2Z9CJSJ0"
chore: update omnibar to work with docusaurus site (#18146) Fixes #17501 New index will be used once the algolia keys are updated https://github.com/appsmithorg/keys/pull/10 ## Description - Update algolia index name and keys. - Removed [app/client/gitbook-algolia-lambda.js](https://github.com/appsmithorg/appsmith/pull/18146/files#diff-cd4ea8ae515ff25aaad99dc86059b65cc9b67edcde4eb261e1e456497b6957d3). It is being replaced by [website/omnibar-algolia-index.js](https://github.com/appsmithorg/appsmith-docs/pull/564/files#diff-a3f32686fd88fe5556e1dec268d0fa72ddd30a7ca05af48e2d55f1a811acd2c0). - Fixes video and list styles of content shown in the omnibar. - Videos on docs.appsmith.com are wrapped in a `videoembed` tag so have updated the regex for the same. - Image urls also sometimes include algolia highlight tags which makes the url invalid have removed the same https://github.com/appsmithorg/appsmith/pull/18146/files#diff-0e7cdbf77157af62f50ece962a8d4e381b2c070c2453123e8a713298f9640e25R126. - Docusaurus https://docusaurus.io/docs/markdown-features/admonitions have a different syntax have updated the regex to parse the same. https://github.com/appsmithorg/appsmith/pull/18146/files#diff-0e7cdbf77157af62f50ece962a8d4e381b2c070c2453123e8a713298f9640e25R154 TLDR Make omnibar work with the new docs site. ## How Has This Been Tested? - Manual ### Test Plan > Add Testsmith test cases links that relate to this PR ### Issues raised during DP testing https://github.com/appsmithorg/appsmith/issues/17501#issuecomment-1307043824 ## Checklist: ### Dev activity - [x] My code follows the style guidelines of this project - [x] I have performed a self-review of my own code - [ ] I have commented my code, particularly in hard-to-understand areas - [ ] I have made corresponding changes to the documentation - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works - [x] New and existing unit tests pass locally with my changes - [ ] PR is being merged under a feature flag ### QA activity: - [ ] Test plan has been approved by relevant developers - [ ] Test plan has been peer reviewed by QA - [ ] Cypress test cases have been added and approved by either SDET or manual QA - [ ] Organized project review call with relevant stakeholders after Round 1/2 of QA - [ ] Added Test Plan Approved label after reveiwing all Cypress test
2022-11-21 08:25:33 +00:00
REACT_APP_ALGOLIA_API_KEY = "dfde934d9bdc2e0b14830f1dd3cb240f"
REACT_APP_ALGOLIA_SEARCH_INDEX_NAME = "omnibar_docusaurus_index"
REACT_APP_CLIENT_LOG_LEVEL = "debug"
REACT_APP_GOOGLE_MAPS_API_KEY = "AIzaSyBOQFulljufGt3VDhBAwNjZN09KEFufVyg"
REACT_APP_GOOGLE_RECAPTCHA_SITE_KEY = ""
REACT_APP_TNC_PP = "true"
REACT_APP_CLOUD_HOSTING = "true"
REACT_APP_INTERCOM_APP_ID = "y10e7138"
2020-08-20 08:14:07 +00:00
REACT_APP_MAIL_ENABLED = "true"
2020-10-26 09:29:27 +00:00
REACT_APP_SENTRY_DSN = "https://abf15a075d1347969df44c746cca7eaa@o296332.ingest.sentry.io/1546547"
REACT_APP_SENTRY_ENVIRONMENT = "Production"
2021-06-04 07:48:17 +00:00
REACT_APP_SHOW_ONBOARDING_FORM = "true"
2020-10-26 09:29:27 +00:00
SENTRY_AUTH_TOKEN = "dfdf7fa46c5b483a944b4571554d6466da3c64a6ed8b46e3b8a4285183a6bcc3"
SENTRY_DSN = "https://abf15a075d1347969df44c746cca7eaa@o296332.ingest.sentry.io/1546547"
SENTRY_ORG = "appsmith"
SENTRY_PROJECT = "appsmith"
SENTRY_LOG_LEVEL = "info"
REACT_APP_CLOUD_SERVICES_BASE_URL = "https://release-cs.appsmith.com"
[context.deploy-preview]
[context.deploy-preview.environment]
REACT_APP_ENVIRONMENT = "STAGING"
2020-10-26 09:29:27 +00:00
REACT_APP_SENTRY_ENVIRONMENT = "Development"
REACT_APP_BASE_URL = "https://release.app.appsmith.com"
# Not adding an APP_HOST here because the URL is dynamic in nature and cannot be determined.
[context.develop]
[context.develop.environment]
REACT_APP_ENVIRONMENT = "STAGING"
REACT_APP_BASE_URL = "https://release.app.appsmith.com"
APP_HOST = "develop.app.appsmith.com"
Use injected configuration from Nginx at runtime instead of build time (#30) * Use envsubst and nginx templates to generate nginx configs which can substitute environment variables and inject into the index.html file * Fix path in dockerfile. Add .gitignore and .env.example files. Fix nginx-linux template. * Add all environment variables. Add prefix to all environment variables. Update scripts to attempt to substitute all environment variables with the prefix * Setup dockerfile to execute a bash script. use env.example for fetching environment variables in development * Toggle features based on injected configs. Fix nginx template substitution script. * Update env.example file * Remove debug code from start-nginx.sh * Fix nginx config templates by adding quotes by default. Fix sed regex to include numerals. Toggle social login buttons on Login page based on the config. * Update rapid api environment variable name. Toggle oauth buttons based on config in SignUp page. Update .env.example to be a union of server and client environment variables * Adding a Map disabled message on Map widget * Adding links to Privacy policy and TNC * Use REACT_APP_ env variables with higher priority over injected config variables for toggling features * Update netlify.toml by commenting out the build environment variables * Remove env variables not required by the client * Remove start-storybook entry from package.json * Fix netlify.toml. Fallback algolia configs * Add contexts to netlify.toml for successful deploys. Swith to using APPSMITH_MARKETPLACE_URL as the toggle for RapidAPI feature on the client. Remove comments in nginx config templates. Fix template used in dockerfile. Co-authored-by: Satbir Singh <apple@apples-MacBook-Pro.local> Co-authored-by: Satbir Singh <satbir121@gmail.com>
2020-07-07 10:22:17 +00:00
[[headers]]
for = "/static/*"
[header.values]
cache-control = "max-age=604800"
[[redirects]]
from = "/api/*"
to = "API_PLACEHOLDER/api/:splat"
status = 200
force = true
headers = { X-Forwarded-Host = "APP_HOST_PLACEHOLDER", X-Forwarded-Proto = "https" }
[[redirects]]
from = "/oauth2/*"
to = "API_PLACEHOLDER/oauth2/:splat"
status = 200
force = true
headers = { X-Forwarded-Host = "APP_HOST_PLACEHOLDER", X-Forwarded-Proto = "https" }
[[redirects]]
from = "/login/*"
to = "API_PLACEHOLDER/login/:splat"
status = 200
force = true
headers = { X-Forwarded-Host = "APP_HOST_PLACEHOLDER", X-Forwarded-Proto = "https" }
# This must be the last redirect in the chain because it's a catch-all
[[redirects]]
from = "/*"
to = "/index.html"
status = 200