Just an FYI for folks, the Upgrade Plugin won't work if the web-daemon user cannot write to the document-root folder.
Our DevOps set up document-root ownership as root-root with perms 0644 - everything inside the document-root is owned by www-data.www-data. (It's a cautious security thing I guess)
This means the Upgrade Plugin can overwrite anything already in existence - but cannot create new folders etc. This leads to the non-writeable errors on new folders - like /bin or /.github
DevOps agreed to change Dokuwiki document-root to root.www-data and 2664 group writeable. This enables the Update Plugin to run without non-writeable errors.