updated config

This commit is contained in:
Warunee Tamkoo 2024-12-10 10:45:01 +07:00
parent 0dd17e797c
commit 493f0294e8
4 changed files with 5 additions and 8 deletions

View file

@ -1,2 +1,3 @@
VITE_API_URI_CONFIG: "https://app.your-domain.com/api/v1" VITE_API_URI_CONFIG: "https://app.your-domain.com/api/v1"
VITE_URL_SSO: "https://app-sso.your-domain.com"
VITE_MANUAL_URL: "https://app-manual.your-domain.com" VITE_MANUAL_URL: "https://app-manual.your-domain.com"

View file

@ -1,5 +1,4 @@
VITE_API_PUBLISH_URL=VITE_API_PUBLISH_URL
VITE_API_REPORT_URL=VITE_API_REPORT_URL
VITE_API_URI_CONFIG=VITE_API_URI_CONFIG VITE_API_URI_CONFIG=VITE_API_URI_CONFIG
VITE_API_REPORT_URL=VITE_API_REPORT_URL
VITE_MANUAL_URL=VITE_MANUAL_URL VITE_MANUAL_URL=VITE_MANUAL_URL
VITE_URL_SSO: VITE_URL_SSO VITE_URL_SSO: VITE_URL_SSO

View file

@ -8,9 +8,8 @@ for file in $ROOT_DIR/assets/app.*.js* $ROOT_DIR/js/app.*.js* $ROOT_DIR/assets/Q
do do
echo "Processing $file ..."; echo "Processing $file ...";
sed -i 's|VITE_API_PUBLISH_URL|'${VITE_API_PUBLISH_URL}'|g' $file
sed -i 's|VITE_API_REPORT_URL|'${VITE_API_REPORT_URL}'|g' $file
sed -i 's|VITE_API_URI_CONFIG|'${VITE_API_URI_CONFIG}'|g' $file sed -i 's|VITE_API_URI_CONFIG|'${VITE_API_URI_CONFIG}'|g' $file
sed -i 's|VITE_API_REPORT_URL|'${VITE_API_REPORT_URL}'|g' $file
sed -i 's|VITE_MANUAL_URL|'${VITE_MANUAL_URL}'|g' $file sed -i 's|VITE_MANUAL_URL|'${VITE_MANUAL_URL}'|g' $file
sed -i 's|VITE_URL_SSO|'${VITE_URL_SSO}'|g' $file sed -i 's|VITE_URL_SSO|'${VITE_URL_SSO}'|g' $file

View file

@ -3,8 +3,7 @@ import { ref } from "vue";
const env = ref<string>(process.env.NODE_ENV || "development"); const env = ref<string>(process.env.NODE_ENV || "development");
export const apiUrlConfig = import.meta.env.VITE_API_URI_CONFIG; export const apiUrlConfig = import.meta.env.VITE_API_URI_CONFIG;
// export const apiUrlConfigPublish = import.meta.env.VITE_API_PUBLISH_URL; export const apiUrlConfigReport = import.meta.env.VITE_API_REPORT_URL;
// export const apiUrlConfigReport = import.meta.env.VITE_API_REPORT_URL;
// if (process.env.VUE_APP_TEST) { // if (process.env.VUE_APP_TEST) {
// env = "test"; // env = "test";
// } // }
@ -37,8 +36,7 @@ const config = ref<any>({
API_REPORT_URI: apiUrlConfig, API_REPORT_URI: apiUrlConfig,
MEET_URI: "meet.frappet.com", MEET_URI: "meet.frappet.com",
API_REPORT2_URI: `${window.location.protocol}//${window.location.host}/api/v2`, API_REPORT2_URI: `${window.location.protocol}//${window.location.host}/api/v2`,
API_REPORT_TEMPLATE_URI: API_REPORT_TEMPLATE_URI: apiUrlConfigReport,
"https://report-server.frappet.synology.me/api/v1/report-template",
API_LOG: apiUrlConfig, API_LOG: apiUrlConfig,
}, },
}); });