xpam.pl

Month: April 2020

  • Apache http to https redirect – use 307

    Who knew that a simple thing like HTTP redirects would be so complicated? It turns out clients will just change POST to GET on 301 (Postman, curl, everyone?), same with 302 which really behaves like 303 and that is also an old implementation “bug”. Yeah, seriously. If you have a REST API with POST (or…

  • Setting env variables with hyphen and running a program

    Docker compose allows you very unrestrictive naming of your environment variables. It allows you to use hyphen and other “special” characters in variables names. When you need to use these variables in regular shell you are out of luck, bash and many other shells do not allow hyphens in variable names. But this is merely…