On my site, if I start with
https://mysite.de/wiki, see the start page, klick [Login] -> the login continues to be processed via https.
So just use or publish the https-URL whereever you published the http-URL before and it works naturally.
Special coding is only neccessary if you want the site to switch from http to https and back, like i.e. Ebay does it, for performance reasons.