I have an endpoint that returns the following plain text:
openssl genrsa -out server.key 2048
openssl req -new -sha256 -key server.key -out server.csr
but after I run it like this:
curl -sSf https://.../ | bash -
it asks Country Name (2 letter code) [XX]: but then immediately runs the second command which causes an error and goes back to the prompt. How can I make it wait for the user to enter all the fields asked by command 1 and then run command 2?
The reason I am doing it like this is because I am creating a service that reads plain text from a curl call and pipes it to bash; a sort of automated scripting from a remote resource.
curl -sSf https://.../ | bash -as that is an internal service I created for running automated scripts.bash <(curl blah blah).