cURL Cheatsheet

Nice things you can do with cURL # Resolve a hostname with a given ip curl http://iix.se --resolve iix.se:80:206.189.18.126 # Run many queries in a loop (either for looping or load testing) curl 'http://localhost:8080/oauth/login?[1-10]' -d '{ "username": "[email protected]", "password": "secret" }' -vvv -H "Content-Type: application/json" # Light load testing an endpoint (Z=parallell, -s/-o removes output, -w sets new output) curl -Z -so /dev/null -w "%{time_total} %{http_code}\n" 'https://acme.system.com/api/endpoint?[1-20]'

May 25, 2020  |  🏷️curl

Building debian packages

Links Official Manual Example building sudo-1.8.11p1-2 # Download the source files curl -O http://ftp.de.debian.org/debian/pool/main/s/sudo/sudo_1.8.11p1-2.dsc curl -O http://ftp.de.debian.org/debian/pool/main/s/sudo/sudo_1.8.11p1.orig.tar.gz curl -O http://ftp.de.debian.org/debian/pool/main/s/sudo/sudo_1.8.11p1-2.debian.tar.xz # Extract the tarballs: tar xf sudo_1.8.11p1-2.debian.tar.xz # Creates folder sudo-1.8.11p1 tar xf sudo_1.8.11p1.orig.tar.gz # Creates folder debian # Move the debian file to the source mv debian sudo-1.8.11p1 # Cd to the folder cd sudo-1.8.11p1 # Build dpkg-buildpackage -us -uc

October 27, 2014  |  🏷️curl 🏷️tar 🏷️dpkg