0

Can I setup my (CLI) curl to either not set "Expect: 100-continue" or to set it to "Expect: " for my command-line browsing?

I've ran into this issue with GCE Load balancer returning 502 for curl because it's confused by Expect: 100 and breaks, and now I have to manually set it up on every request. (Well, not manually, I have aliases for the stuff I test frequently, but that's not the point.)

Community
  • 1
  • 1
Zlatko
  • 18,936
  • 14
  • 70
  • 123

1 Answers1

3

You can create a ~/.curlrc file and put your default options in that. Described in the man page section for -K, --config.

A default option to switch off the Expect: header could be:

header = "Expect:"
Daniel Stenberg
  • 54,736
  • 17
  • 146
  • 222