diff --git a/.github/workflows/api-deploy.yml b/.github/workflows/api-deploy.yml index 1964c547..3c16334e 100644 --- a/.github/workflows/api-deploy.yml +++ b/.github/workflows/api-deploy.yml @@ -129,7 +129,7 @@ jobs: # inject the expected React package URL for CORS logic environment-variables: | RUST_LOG=INFO - REACT_APP_URL=https://cairo-remix-dev.nethermind.io + VITE_URL=https://cairo-remix-dev.nethermind.io PROMTAIL_USERNAME=${{secrets.PROMTAIL_USERNAME}} PROMTAIL_PASSWORD=${{secrets.PROMTAIL_PASSWORD}} diff --git a/.gitignore b/.gitignore index b3be8ffd..9f80145f 100644 --- a/.gitignore +++ b/.gitignore @@ -6,6 +6,8 @@ api/casm api/casm/* +api/*.env + api/upload api/upload/* diff --git a/api/src/main.rs b/api/src/main.rs index fed5c848..0cd858e7 100644 --- a/api/src/main.rs +++ b/api/src/main.rs @@ -45,7 +45,7 @@ impl Fairing for CORS { } // Take the Plugin App URL from the env variable, if set - match env::var("REACT_APP_URL") { + match env::var("VITE_URL") { Ok(v) => { response.set_header(Header::new("Access-Control-Allow-Origin", v)); } diff --git a/plugin/.env b/plugin/.env index 95b00dee..f393870f 100644 --- a/plugin/.env +++ b/plugin/.env @@ -1,5 +1,5 @@ GENERATE_SOURCEMAP=false -REACT_APP_API_URL=https://cairo-remix-api-dev.nethermind.io -REACT_APP_DEVNET_URL=http://127.0.0.1:5050 -REACT_APP_REMOTE_DEVNET_URL=https://starknet-remix-devnet.nethermind.io -REACT_APP_VERSION=$npm_package_version \ No newline at end of file +VITE_API_URL=https://cairo-remix-api-dev.nethermind.io +VITE_DEVNET_URL=http://127.0.0.1:5050 +VITE_REMOTE_DEVNET_URL=https://starknet-remix-devnet.nethermind.io +VITE_VERSION=$npm_package_version \ No newline at end of file diff --git a/plugin/.env.development b/plugin/.env.development index 7c456897..d8b8e8b6 100644 --- a/plugin/.env.development +++ b/plugin/.env.development @@ -1,4 +1,4 @@ -REACT_APP_API_URL=https://cairo-compile-remix-test.nethermind.io -REACT_APP_DEVNET_URL=http://127.0.0.1:5050 -REACT_APP_REMOTE_DEVNET_URL=https://starknet-devnet-dev.nethermind.io -REACT_APP_VERSION=$npm_package_version \ No newline at end of file +VITE_API_URL=https://cairo-compile-remix-test.nethermind.io +VITE_DEVNET_URL=http://127.0.0.1:5050 +VITE_REMOTE_DEVNET_URL=https://starknet-devnet-dev.nethermind.io +VITE_VERSION=$npm_package_version \ No newline at end of file diff --git a/plugin/public/index.html b/plugin/index.html similarity index 83% rename from plugin/public/index.html rename to plugin/index.html index 38e4740c..a68f90c4 100644 --- a/plugin/public/index.html +++ b/plugin/index.html @@ -8,5 +8,6 @@
+