You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
set_nextcloud_port() {
local nextcloud_port="$1"
yellow_msg "\nConfiguring NextCloud:${nextcloud_port}, please wait...\n"
sudo snap set nextcloud ports.http="${nextcloud_port}"
# TODO: verify nextcloud port is set successfully.
#The website should display:
#Secure Connection Failed
#An error occurred during a connection to localhost:81. SSL received a
# record that exceeded the maximum permissible length.
# Error code: SSL_ERROR_RX_RECORD_TOO_LONG
}
Include:
add_onion_to_nextcloud_trusted_domain() {
local onion_address
onion_address=$(sudo cat "$NEXTCLOUD_HIDDEN_SERVICE_PATH/hostname")
# TODO: verify format of incoming onion address.
#add Hidden Service address like a trusted domain in NextCloud instance
sudo /snap/bin/nextcloud.occ config:system:set trusted_domains 1 --value="$onion_address"
printf "\nThe Hidden Service address has been added like trusted domain successfully.\n"
# TODO: verify output:
sudo /snap/bin/nextcloud.occ config:system:get trusted_domains
}
Include:
dd_certs_to_nextcloud() {
local ssl_public_key_filename="$1"
local ssl_private_key_filename="$2"
local merged_ca_ssl_cert_filename="$3"
# First copy the files into nextcloud.
# Source: https://github.com/nextcloud-snap/nextcloud-snap/issues/256
# (see nextcloud.enable-https custom -h command).
#sudo cp ca.pem /var/snap/nextcloud/current/ca.pem
sudo cp "$ssl_public_key_filename" /var/snap/nextcloud/current/"$ssl_public_key_filename"
sudo cp "$ssl_private_key_filename" /var/snap/nextcloud/current/"$ssl_private_key_filename"
sudo cp "$merged_ca_ssl_cert_filename" /var/snap/nextcloud/current/"$merged_ca_ssl_cert_filename"
read -p "Before enable"
# CLI sudo /snap/bin/nextcloud.enable-https custom Says:
sudo /snap/bin/nextcloud.enable-https custom "/var/snap/nextcloud/current/$ssl_public_key_filename" "/var/snap/nextcloud/current/$ssl_private_key_filename" "/var/snap/nextcloud/current/$merged_ca_ssl_cert_filename"
#sudo /snap/bin/nextcloud.enable-https custom "/var/snap/nextcloud/current/cert.pem" "/var/snap/nextcloud/current/cert-key.pem" "/var/snap/nextcloud/current/fullchain.pem"
}
From here
The text was updated successfully, but these errors were encountered: