Comments (4)
Hi @restoredtemecula. Can you please provide the exact steps for reproduction of the error? Be as detailed as possible. Also provide some screenshots as they could be useful.
from cors-server.
Sure thing. I followed all of your instructions outlined in your README for this repo. Each step listed below in sequence.
• First, I forked your repo and cloned it locally
• Updated index.js (in the functions directory) with my whitelist requirements.
• Ran npm install in functions directory
• Then I attempted to install firebase-tool globally npm install -g firebase-tools
(i already had firebase CLI, but did this to be certain I was on the latest. BUT ran into an error because my node.js version was not up to date enough for firebase-tools. So I updated node.js to version 18.12.1
• Then I installed firebase-tools
• I already had an existing firebase project that did not use "Functions" and this proxy applies to the same project, so I filled in my project-id to the default value field { "projects": { "default": "restored-temecula-mobile-app" } }
• Lastly, I double checked everything, than ran npm run deploy
from the functions directory. And received an error in terminal after the attempted deploy.
I also found the following in firebase-debug.log
[debug] [2022-11-13T23:47:46.069Z] TypeError: Cannot read properties of undefined (reading 'service') at /usr/local/lib/node_modules/firebase-tools/lib/deploy/functions/backend.js:198:113 at Array.map (<anonymous>) at loadExistingBackend (/usr/local/lib/node_modules/firebase-tools/lib/deploy/functions/backend.js:198:69) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async Object.existingBackend (/usr/local/lib/node_modules/firebase-tools/lib/deploy/functions/backend.js:174:9) at async prepare (/usr/local/lib/node_modules/firebase-tools/lib/deploy/functions/prepare.js:151:115) at async chain (/usr/local/lib/node_modules/firebase-tools/lib/deploy/index.js:35:9) at async deploy (/usr/local/lib/node_modules/firebase-tools/lib/deploy/index.js:79:5) [error] [error] Error: An unexpected error has occurred.
My copy your repo with the changes i made can be found here:
https://github.com/restoredtemecula/cors-server
Let me know if you need anything more in detail and I can provide. Appreciate your help!
from cors-server.
I manually deleted the attempted deploy on Google Cloud Console, and reset Permissions and it all deployed fine. This issue can be closed. Now I have a separate issue however and I keep getting 503 errors every time I try to perform a POST through the CORS-anywhere firebase function I deployed.
Any idea why I'd be getting a 503 error when sending a simple POST request for the firebase function to handle?
from cors-server.
I was just getting around to taking a look at the issue now, but good to see that you've resolved it. Thanks for providing such a detailed explanation of what you attempted.
If the other problem persists, feel free to open another issue on it providing similar detail. I'd like to keep the issues separate for future reference.
from cors-server.
Related Issues (9)
- Http-Proxy HOT 33
- fastly HOT 3
- Error 504 on my request HOT 8
- Different behavior between cors-everywhere webpage and Firebase cors-server HOT 2
- GitHub Codespaces
- Getting cors error even after following all the steps you have mentioned on readme HOT 3
- Always receiving status 503 error when performing HTTP POST to Firebase Function HOT 11
- Help for vercel deployment HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cors-server.