diff --git a/.env.development b/.env.development index c6742b09..6989633c 100644 --- a/.env.development +++ b/.env.development @@ -9,4 +9,5 @@ VITE_DEFAULT_ENDORSER_API_SERVER=http://localhost:3000 # Using shared server by default to ease setup, which works for shared test users. VITE_DEFAULT_IMAGE_API_SERVER=https://test-image-api.timesafari.app VITE_DEFAULT_PARTNER_API_SERVER=http://localhost:3000 +#VITE_DEFAULT_PUSH_SERVER... can't be set up with localhost domain VITE_PASSKEYS_ENABLED=true diff --git a/.env.example b/.env.example deleted file mode 100644 index 983c4b64..00000000 --- a/.env.example +++ /dev/null @@ -1,6 +0,0 @@ -# Admin DID credentials -ADMIN_DID=did:ethr:0x0000694B58C2cC69658993A90D3840C560f2F51F -ADMIN_PRIVATE_KEY=2b6472c026ec2aa2c4235c994a63868fc9212d18b58f6cbfe861b52e71330f5b - -# API Configuration -ENDORSER_API_URL=https://test-api.endorser.ch/api/v2/claim \ No newline at end of file diff --git a/.env.production b/.env.production index d7669d93..bbf73a08 100644 --- a/.env.production +++ b/.env.production @@ -9,3 +9,4 @@ VITE_DEFAULT_ENDORSER_API_SERVER=https://api.endorser.ch VITE_DEFAULT_IMAGE_API_SERVER=https://image-api.timesafari.app VITE_DEFAULT_PARTNER_API_SERVER=https://partner-api.endorser.ch +VITE_DEFAULT_PUSH_SERVER=https://timesafari.app diff --git a/.env.staging b/.env.staging index 6f8c1fc1..a01c323c 100644 --- a/.env.staging +++ b/.env.staging @@ -9,4 +9,5 @@ VITE_DEFAULT_ENDORSER_API_SERVER=https://test-api.endorser.ch VITE_DEFAULT_IMAGE_API_SERVER=https://test-image-api.timesafari.app VITE_DEFAULT_PARTNER_API_SERVER=https://test-partner-api.endorser.ch +VITE_DEFAULT_PUSH_SERVER=https://test.timesafari.app VITE_PASSKEYS_ENABLED=true diff --git a/BUILDING.md b/BUILDING.md index 4887d7bc..d9debb77 100644 --- a/BUILDING.md +++ b/BUILDING.md @@ -84,7 +84,7 @@ Install dependencies: * For test, build the app (because test server is not yet set up to build): ```bash -TIME_SAFARI_APP_TITLE="TimeSafari_Test" VITE_APP_SERVER=https://test.timesafari.app VITE_BVC_MEETUPS_PROJECT_CLAIM_ID=https://endorser.ch/entity/01HWE8FWHQ1YGP7GFZYYPS272F VITE_DEFAULT_ENDORSER_API_SERVER=https://test-api.endorser.ch VITE_DEFAULT_IMAGE_API_SERVER=https://test-image-api.timesafari.app VITE_DEFAULT_PARTNER_API_SERVER=https://test-partner-api.endorser.ch VITE_PASSKEYS_ENABLED=true npm run build +TIME_SAFARI_APP_TITLE="TimeSafari_Test" VITE_APP_SERVER=https://test.timesafari.app VITE_BVC_MEETUPS_PROJECT_CLAIM_ID=https://endorser.ch/entity/01HWE8FWHQ1YGP7GFZYYPS272F VITE_DEFAULT_ENDORSER_API_SERVER=https://test-api.endorser.ch VITE_DEFAULT_IMAGE_API_SERVER=https://test-image-api.timesafari.app VITE_DEFAULT_PARTNER_API_SERVER=https://test-partner-api.endorser.ch VITE_DEFAULT_PUSH_SERVER=https://test.timesafari.app VITE_PASSKEYS_ENABLED=true npm run build ``` ... and transfer to the test server: diff --git a/src/constants/app.ts b/src/constants/app.ts index b49d3e34..3e9ebc4c 100644 --- a/src/constants/app.ts +++ b/src/constants/app.ts @@ -43,7 +43,7 @@ export const DEFAULT_PARTNER_API_SERVER = AppString.TEST_PARTNER_API_SERVER; export const DEFAULT_PUSH_SERVER = - window.location.protocol + "//" + window.location.host; + import.meta.env.VITE_DEFAULT_PUSH_SERVER || "https://timesafari.app"; export const IMAGE_TYPE_PROFILE = "profile";