Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for deploying certs to Nextcloud instance hosted on TrueNAS (Core) #67

Closed
ccman32 opened this issue Feb 19, 2023 · 3 comments
Labels
wontfix This will not be worked on

Comments

@ccman32
Copy link

ccman32 commented Feb 19, 2023

I am using acme.sh on my TrueNAS Core system to obtain a wildcard cert which I then use for the UI and WebDAV. However, I recently also installed the Nextcloud plugin for which I also want to use my cert. Would it be possible to add an option to this script to copy the obtained cert into the Nextcloud jail, or are there any reasons for not doing this?

@danb35 danb35 added the wontfix This will not be worked on label Feb 19, 2023
@danb35
Copy link
Owner

danb35 commented Feb 19, 2023

Would it be possible to add an option to this script to copy the obtained cert into the Nextcloud jail

No, for a few reasons:

@danb35 danb35 closed this as completed Feb 19, 2023
@ccman32
Copy link
Author

ccman32 commented Feb 19, 2023

Thank you for the detailed response! First of all, I already suspected that my request might be out of scope for this script, but I thought it doesn't hurt to ask.

I also wasn't aware that plugins on Core should be avoided at all, so thank you for the heads-up. TrueNAS sometimes just seems like a big minefield to me with tons of things you "can" do but many of them being, in Kris Moore's words, a "path to sadness".

Anyway, as I just started working with the Nextcloud plugin and didn't really do much with it yet, I'll certainly check out freenas-iocage-nextcloud and try to set that up instead.

@adorobis
Copy link
Contributor

adorobis commented Feb 20, 2023

As much as I would agree that it might not make sense to implement it in this scrip, deploying a cert to a Nextcloud jail is actually quite simple. Here is my shell script that does it. I also deploy it to many other places (jails, other systems - e.g. debian, or even a router).

    # copy certificates to nextcloud jail
    cp /etc/certificates/new/letsencrypt.key /mnt/Dane/iocage/jails/nc/root/etc/ssl/cert.key
    cp /etc/certificates/new/letsencrypt.crt /mnt/Dane/iocage/jails/nc/root/etc/ssl/cert.crt
	
    # restart nextcloud web server
    iocage exec nc service nginx restart

Here is my full script if you are interested in more than just Nextcloud

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

3 participants