Hi Felix! Thank you for this solution. But my point was in starting nginx server without encryption. Probably it should be a separate argument or something. In my case I used (local-file ) to set needed settings but your suggestion looks nice.
> On Dec 25, 2022, at 7:44 AM, Felix Lechner <felix.lech...@lease-up.com> wrote: > > Hi Adam, > >> On Sat, Dec 24, 2022 at 2:29 AM Adam Kandur <manual...@icloud.com> wrote: >> >> Which will not work because it asks to listen on 443 with ssl, which is not >> possible because no certificates are provided. > > I use this configuration [1] but also face a chicken-and-egg problem > for new sites. I normally take nginx offline with > > sudo herd stop nginx > > and then configure any newly needed certificates from Let's Encrypt with > > sudo certbot certificates --standalone > > Then I start Nginx again. > > At my convenience (but within ninety days) I then reconfigure the > equipment while including both the new website in Nginx and the new > Certbot definition in config.scm. > > Hope that helps! > > Kind regards > Felix Lechner > > [1] > https://codeberg.org/lechner/system-config/src/commit/2b6e49e466cb8bd4a3715111b4a4690192941ac8/host/wallace-server/operating-system.scm#L581-L743