30 lines
No EOL
949 B
Markdown
30 lines
No EOL
949 B
Markdown
cloudfare
|
|
|
|
- using it for tunnel
|
|
https://yewtu.be/watch?v=Dp5VcCmlKh4
|
|
`cloudfared tunnel --url http://localhost:8080`
|
|
|
|
- deploy nodejs app
|
|
> it doesn't uses nodejs engine
|
|
<https://developers.cloudflare.com/workers/runtime-apis/nodejs/>
|
|
> express module isn't supported
|
|
<https://hono.dev/> or <https://github.com/kwhitley/itty-router>
|
|
> it don't give access to file system
|
|
<https://www.cloudflare.com/developer-platform/r2/>
|
|
> It's for basic things and simple requests
|
|
No, you just have to build your app a bit differently
|
|
- Example
|
|
- cors-anywhere
|
|
https://github.com/Zibri/cloudflare-cors-anywhere
|
|
[cloudflare-cors-anywhere-master.zip](../../../_resources/cloudflare-cors-anywhere-master.zip)
|
|
- cloudflare workers
|
|
Use wrangler by installing it via npm then
|
|
login with
|
|
`wrangler login`
|
|
if worker name is test then
|
|
`wrangler init --from-dash test`
|
|
Then finally deploy with
|
|
`wrangler deploy` or `wrangler publish`
|
|
|
|
|
|
|