R2 _ Problem with Wrangler CLI Guide


I try to set up R2 (High performance storage for files and objects with no egress charges.) to test before deploying it to my site.
I have a problem for Wrangler CLI Guide with the command “wrangler login”.

  1. I install wrangler on my server
    #npm install -g wrangler

  2. Authenticate Wrangler with your Cloudflare account
    #wrangler login

I copy / paste the link in my web broswer and I press the “agree” button but I am redirected to a link starting with “localhost:8976/oauth/callback?code” so necessarily a redirection on “localhost” doesn’t work…

I don’t understand, if someone can help me, thanks!


Authenticate Wrangler using API tokens instead.


Thank you for your reply.

I already tried too
#CLOUDFLARE_API_TOKEN=*************** wrangler publish

but i have an error
“Error MIssing entry-point: the entry-point should be specified via the command line (e.g ‘wrangler publish path/to/script’) or the ‘main’ config field”

which path ?
#locate wrangler


For example @kaimi

As it says in the error message, you need to specify the script

wrangler publish src/index.js


…of the configuration file

## wrangler.toml

# Worker Name
name = "worker-script"

# Entry Point.
main = "src/index.js"
1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.