ionic-team / ionic-cli

The Ionic command-line interface
MIT License
1.99k stars 640 forks source link

HTTPS not workin for localhost with --https #5045

Open sseppo opened 7 months ago

sseppo commented 7 months ago

I found couple of posts about getting https server running in ionic react projects with ionic serve --https

However that does not work. It still starts the server as http, and manually changing url to https does not help. I have created the certificates using ionic ssl generate

Also, running ionic --help

does not show option --https (or --ssl either).

I am using ionic 7.

reslear commented 7 months ago

duplicate https://github.com/ionic-team/ionic-cli/issues/5028

sseppo commented 7 months ago

@reslear, thanks for the comment, but is it dublicate or just possibly related? I mean, in the other thread it is trying to run on ios, this tries to run on desktop, not mobile. Also, there it is not using --ssl or --https which is mentioned that should be used in other threads about the subject. And it is for Vite, I have understood that the --https is only for React.

Anyway, it is also related to https so good to have that linked too. I will keep looking into that too. But I think it is not dublicate so good to have them both.