staticman
staticman copied to clipboard
Gracefully ignore absent SSH key
I believe one of the biggest sources of confusion for new users is the need to provide an SSH private key in order to have the API process running.
I believe a better default behavior should be to require the minimum possible amount of configuration and simply respond with an error when trying to access a disabled functionality.
I'd bet that for most new users (me included) the main reason to use Staticman is because they need a mean to add comments to a statically generated web site. The /encrypt feature might be a nice to have feature but I believe is not core and should definitely not be the cause of any confusion.
For example, a call to GET /v2/encrypt/
should return either a 404
or a 503 Service Unavailable
when key is missing and/or malformatted
@alexwaibel any thoughts on this too? we can definitely improve the docs to a certain extent but I think this is paramount to improve the UX
I agree this seems like a helpful addition. It's been a while since I dug through the full codebase so when adding this we should make sure to go look for all the places the key is used and ensure the core flow will work without it.