diff --git a/.env b/.env index 8a7b0acaa..d4dfbae78 100644 --- a/.env +++ b/.env @@ -9,12 +9,12 @@ REACT_APP_LINKED_REGISTRATIONS_UI_URL=https://linkedregistrations.dev.hel.ninja REACT_APP_SENTRY_DSN= REACT_APP_SENTRY_ENVIRONMENT= -REACT_APP_MATOMO_URL_BASE="//matomo.dev.hel.ninja/" -REACT_APP_MATOMO_SITE_ID="42" +REACT_APP_MATOMO_URL_BASE="//matomo.hel.fi/" +REACT_APP_MATOMO_SITE_ID=42 REACT_APP_MATOMO_SRC_URL="matomo.js" REACT_APP_MATOMO_DOMAINS="*.linkedevents.hel.fi" REACT_APP_MATOMO_COOKIE_DOMAIN="*.linkedevents.hel.fi" -REACT_APP_MATOMO_ENABLED=false +REACT_APP_MATOMO_ENABLED=true REACT_APP_SWAGGER_URL=https://dev.hel.fi/apis/linkedevents REACT_APP_SWAGGER_SCHEMA_URL=https://raw.githubusercontent.com/City-of-Helsinki/api-linked-events/master/linked-events.swagger.yaml diff --git a/.env.local.example b/.env.local.example index 03e257818..b645219be 100644 --- a/.env.local.example +++ b/.env.local.example @@ -14,5 +14,5 @@ REACT_APP_MATOMO_DOMAINS="*.linkedevents.hel.fi" REACT_APP_MATOMO_COOKIE_DOMAIN="*.linkedevents.hel.fi,*.linkedevents.hel.fi" #comma separated domains REACT_APP_MATOMO_SRC_URL="matomo.js" REACT_APP_MATOMO_URL_BASE="//matomo.dev.hel.ninja/" -REACT_APP_MATOMO_SITE_ID="42" +REACT_APP_MATOMO_SITE_ID=42 REACT_APP_MATOMO_ENABLED=false diff --git a/pipelines/linkedcomponents-ui-release.yml b/pipelines/linkedcomponents-ui-release.yml index 374112d8c..ec6ac651e 100644 --- a/pipelines/linkedcomponents-ui-release.yml +++ b/pipelines/linkedcomponents-ui-release.yml @@ -31,7 +31,7 @@ resources: extends: # Filename in Azure DevOps Repository template: azure-pipelines-linkedcomponents-ui-release.yml@linkedevents-pipelines - # parameters: + parameters: # Application build arguments and config map values as key value pairs. # Does not contain all buildArguments or configMap values, the rest located in linkedevents-pipelines # Default value to nodeVersion is set on template. @@ -42,7 +42,13 @@ extends: # configMapStage: # pod environment variables # DEBUG: 1 ## Production definitions - # buildArgs: + buildArgs: + REACT_APP_MATOMO_URL_BASE: //matomo.hel.fi/ + REACT_APP_MATOMO_SITE_ID: 42 + REACT_APP_MATOMO_SRC_URL: matomo.js + REACT_APP_MATOMO_DOMAINS: '*.linkedevents.hel.fi' + REACT_APP_MATOMO_COOKIE_DOMAIN: '*.linkedevents.hel.fi' + REACT_APP_MATOMO_ENABLED: true # DEBUG: 1 # configMap: # pod environment variables # DEBUG: 1 diff --git a/pipelines/linkedcomponents-ui-review.yml b/pipelines/linkedcomponents-ui-review.yml index 520d62134..14f717236 100644 --- a/pipelines/linkedcomponents-ui-review.yml +++ b/pipelines/linkedcomponents-ui-review.yml @@ -50,12 +50,12 @@ extends: # Default value to nodeVersion is set on template. # The values here will override the values defined in the linkedevents-pipelines repository buildArgs: - REACT_APP_MATOMO_URL_BASE: //matomo.dev.hel.ninja/ + REACT_APP_MATOMO_URL_BASE: //matomo.hel.fi/ REACT_APP_MATOMO_SITE_ID: 42 REACT_APP_MATOMO_SRC_URL: matomo.js REACT_APP_MATOMO_DOMAINS: '*.linkedevents.hel.fi' REACT_APP_MATOMO_COOKIE_DOMAIN: '*.linkedevents.hel.fi' - # REACT_APP_MATOMO_ENABLED=false + REACT_APP_MATOMO_ENABLED: true # DEBUG: 1 # configMap: # pod environment variables # DEBUG: 1 diff --git a/src/domain/app/App.tsx b/src/domain/app/App.tsx index 61516f6fa..57360fe7b 100644 --- a/src/domain/app/App.tsx +++ b/src/domain/app/App.tsx @@ -65,8 +65,8 @@ const App: React.FC = () => { configurations: { setDocumentTitle: `${document.location}${document.title}`, setCookieDomain: import.meta.env.REACT_APP_MATOMO_COOKIE_DOMAIN, - setDomains: import.meta.env.MATOMO_DOMAINS - ? import.meta.env.MATOMO_DOMAINS.split(',') + setDomains: import.meta.env.REACT_APP_MATOMO_DOMAINS + ? import.meta.env.REACT_APP_MATOMO_DOMAINS.split(',') : [], setDoNotTrack: undefined, disableCookies: undefined,