Resource icon

Scripted installation of Nextcloud 28 in iocage jail 2018-03-23

norskman

Contributor
Joined
Sep 28, 2012
Messages
149
I was led to believe that the let's encrypt need constant 'looking after' and I felt a low cost Comodo SSL for a number of years would remove that headache.

When I used your script, I used it with the NO-CERT=1 option
 

norskman

Contributor
Joined
Sep 28, 2012
Messages
149
I could reload it again. your software is so easy to use, I would just rerun it but using lets encrypt instead if you recommend it for long-term use?
 
Last edited:

norskman

Contributor
Joined
Sep 28, 2012
Messages
149
I started again and used your Lets encrypt method.

It worked.
So very well done and a big thank you for all your effort to make this script work.

I can see though that I have a reverse proxy problem as I can now only enter my FQDN to get access to Nextcloud and there is no access using a local IP address.
That is not a worry but this then causes a further problem as I get a reverse proxy error when trying to get the Nextcloud agent to wok with my mac:

I follow the prompts for installation and when logging in to get the token from the nextcloud server , to allow synchronisation to take place
I get the following error:

Access denied
State token does not match

It is documented as a config.php piece of editing but I can't seem to get that bit in the correct syntax.

Otherwise Lets encrypt certs work!

anyone more familiar with this problem and know how to fix it?
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
When properly set up, Let's Encrypt certificates need no regular manual maintenance. They do need to be renewed regularly (they're only valid for 90 days, and are usually renewed at the 60-day point), but that should be an automated process that doesn't require manual intervention. The only reason, IMO, not to use a Let's Encrypt cert is if you can't make that automation work. And as a practical matter, that means that two things would be true:
  • The host on which you want to get the cert isn't accessible from the Internet on ports 80 and 443, and
  • Your DNS host doesn't have a supported API, and you're unwilling or unable to change to one that does
Caddy, the web server I use in this script, handles all the interaction with Let's Encrypt automatically, as long as either you have a suitable DNS host or your server is accessible from the Internet.

As to the reverse proxy question, I'm afraid I can't help there, though I know others in this thread (@Basil Hendroff, I believe) are using one. You may need to run Nextcloud without a cert at all, though, and use the proxy for TLS termination.
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
I now want to add my SSL certificates.
To go back to this question, even though I believe Let's Encrypt certs are the best way to go for 99% of people, the best way to use an external cert is to install Nextcloud using the SELFSIGNED_CERT option. This will give you a Caddyfile that's set up for an externally-generated cert. Then, once the jail's running, put your cert files in the places specified by that file (/usr/local/etc/pki/tls/private/privkey.pem for the private key, /usr/local/etc/pki/tls/certs/fullchain.pem for the "full chain", the single file containing both your server's certs and any intermediate CA certs) and do service caddy restart. You'll then be responsible for keeping that cert up-to-date, of course; Caddy won't have any of doing that for you as it does with Let's Encrypt certs.
 

MikeJ8181

Cadet
Joined
Jun 7, 2017
Messages
4
I just got an email saying I need to upgrade to ACMEv2 for lets encrypt. Can I fix this just by upgrading Caddy?
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
Can I fix this just by upgrading Caddy?
I wouldn't think you'd need to--what version of Caddy are you using right now? You can find out by running iocage exec nextcloud caddy --version.
 

beltet

Dabbler
Joined
Sep 24, 2013
Messages
26
I'm not quite sure what you're wanting to do here--could you explain a bit more?
You answered almost the same thing I wanted @profzelonka's post. The difference where that I wanted to add instead of replace a hostname. I will look at the caddyfile and see if there are any instructions there. And of course check the nextcloud config aswell.
 

InGenetic

Contributor
Joined
Dec 18, 2013
Messages
183
hi, i already nextcloud installed , using danbe35 scripts :

Scripted installation of Nextcloud 18 in iocage jail
Status: This script will run with FreeNAS 11.2-U7 and with the 11.3 series. It will not work with earlier versions due to the EOL status of FreeBSD 11.2. There are a number of guides on the forum to install Nextcloud/Owncloud, but they all rely...
www.ixsystems.com

and i'm looking for config file for add more trusted domain and which file to add more quota for upload from 20MB to 500MB for example.
where the config file stored if using danbe35 script and file for change upload limit size ?

Thank You .


Regards,
 
Last edited:
Joined
Jan 4, 2014
Messages
1,644
and i'm looking for config file for add more trusted domain and which file to add more quota for upload from 20MB to 500MB for example.
where the config file stored if using danbe35 script and file for change upload limit size ?
You will find config.php in the CONFIG_PATH.
 

InGenetic

Contributor
Joined
Dec 18, 2013
Messages
183
hi again ,

i want to ask about installing nextcloud using danbe35 scripts, in my freenas , i have 2 pool,
first pool for user data,
second pool for nextcloud,

can i installed nextcloud on second pool ? is nextcloud will look for jails folder in first pool ?

JAIL_IP="192.168.1.199"
DEFAULT_GW_IP="192.168.1.1"
POOL_PATH="/mnt/tank"
TIME_ZONE="America/New_York"
HOST_NAME="YOUR_FQDN"
STANDALONE_CERT=1
CERT_EMAIL=you@yourdomain.tld


ex :
First Pool : /mnt/Volume1
Second Pool : /mnt/Volume2

did i have to edit nextcloud config like this (as a pool path ) ?


JAIL_IP="192.168.1.199"
DEFAULT_GW_IP="192.168.1.1"
POOL_PATH="/mnt/Volume2"
TIME_ZONE="America/New_York"
HOST_NAME="YOUR_FQDN"
STANDALONE_CERT=1
CERT_EMAIL=you@yourdomain.tld


another question:

after edit the config ,

did i have to create dataset first on /mnt/Volume2 as below? :

/mnt/Volume2/files
/mnt/Volume2/db
/mnt/Volume2/portsnap

please advice..

wait almost forgot,
my situation is :

- i have 1 domain : mydomain.com , can i use for HOST_NAME="cloud.mydomain.com" ?
- i have 1 staticip public, let say, 115.85.75.xxx then i add ns record for "cloud.mydomain.com" to that ip public
if i create NAT behind my mikrotik to forward port 80 and 443 to my nextcloud LAN IP (192.168.0.5)

can i setup ssl using Let's Encrypt from danbe35 scripts ?



Thanks & regards,
 
Last edited:

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
POOL_PATH should point to wherever you want the data saved; the jails are stored wherever you've told iocage to store them.

- i have 1 domain : mydomain.com , can i use for HOST_NAME="cloud.mydomain.com" ?
Sure, if you set up a DNS record for cloud.
- i have 1 staticip public, let say, 115.85.75.xxx then i add ns record for "cloud.mydomain.com" to that IP public
It would be an A record, not a NS record, but yes, and then yes, you should be able to use Let's Encrypt too.
 

InGenetic

Contributor
Joined
Dec 18, 2013
Messages
183
POOL_PATH should point to wherever you want the data saved; the jails are stored wherever you've told iocage to store them.


Sure, if you set up a DNS record for cloud.

It would be an A record, not a NS record, but yes, and then yes, you should be able to use Let's Encrypt too.

Hi danbe35,

Did i still have to use cloudfare ? With my condition ?

And what kind of CERT type that i should use in nextcloud config ? Standalone ? Dns cert ?

And if lets encrypt working with forwarding port other than port 80 and 443? Ex : port 8787 dst nat to ip lan nextcloud port 443 and port 8888 dst nat to ip lan nextcloud port 80?


Thanks n regards,
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
Did i still have to use cloudfare ? With my condition ?
No, with the situation you describe, there wouldn't be any need to use any particular DNS provider--that's needed when you can't (or don't want to) open ports 80 and 443 to the Internet.

And what kind of CERT type that i should use in nextcloud config ? Standalone ? Dns cert ?
That would be standalone.

And if lets encrypt working with forwarding port other than port 80 and 443?
No, the Let's Encrypt validation servers must be able to connect to the specified FQDN on 80 and 443.
 

InGenetic

Contributor
Joined
Dec 18, 2013
Messages
183
No, with the situation you describe, there wouldn't be any need to use any particular DNS provider--that's needed when you can't (or don't want to) open ports 80 and 443 to the Internet.


That would be standalone.


No, the Let's Encrypt validation servers must be able to connect to the specified FQDN on 80 and 443.
Really thanks danbe35 for your fast reply, i will try to install nextcloud by ur scripts tomorrow morning, it's late at night here.. .
I will let u know the result tomorrow..

Regards,
 

InGenetic

Contributor
Joined
Dec 18, 2013
Messages
183
Really thanks danbe35 for your fast reply, i will try to install nextcloud by ur scripts tomorrow morning, it's late at night here.. .
I will let u know the result tomorrow..

Regards,
hi again ..

if my nextcloud config like below :

JAIL_IP="192.168.0.99"
DEFAULT_GW_IP="192.168.0.1"
POOL_PATH="/mnt/Volume2"
TIME_ZONE="Asia/Jakarta"
HOST_NAME="cloud.mydomain.com"
STANDALONE_CERT=1
CERT_EMAIL=admin@mydomain.com

where the upload data that user's upload will be store ? is it will be store at /mnt/Volume2 ?
cause when i see installer run like below :

+ Using IP options: vnet
+ Starting services OK
+ Executing poststart OK
Destination: /mnt/Volume1/iocage/jails/nextcloud/root/usr/ports does not exist or is not a directory.
Successfully added mount to nextcloud's fstab
Successfully added mount to nextcloud's fstab
Malformed fstab at line 0: '\t/mnt/Volume1/iocage/jails/nextcloud/root/usr/local/www/nextcloud/config\tnullfs\trw\t0\t0'
Successfully added mount to nextcloud's fstab
Successfully added mount to nextcloud's fstab

it means data from user's upload will be store at /mnt/Volume1 ? not in /mnt/Volume2 ??

please advice ..

By the way , i already installed nextcloud,

here's the log :

Libraries have been installed in:
/usr/ports/www/php73-opcache/work/php-7.3.16/ext/opcache/modules

If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the `-LLIBDIR'
flag during linking and do at least one of the following:
- add LIBDIR to the `LD_LIBRARY_PATH' environment variable
during execution
- add LIBDIR to the `LD_RUN_PATH' environment variable
during linking
- use the `-Wl,--rpath -Wl,LIBDIR' linker flag

See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
----------------------------------------------------------------------
--- all ---

Build complete.
Don't forget to run 'make test'.
===> Staging for php73-opcache-7.3.16
===> php73-opcache-7.3.16 depends on file: /usr/local/include/php/main/php.h - found
===> Generating temporary packing list
====> Compressing man pages (compress-man)
===> Installing for php73-opcache-7.3.16
===> Checking if php73-opcache is already installed
===> Registering installation for php73-opcache-7.3.16
[nextcloud] Installing php73-opcache-7.3.16...
This file has been added to automatically load the installed extension:
/usr/local/etc/php/ext-10-opcache.ini

===> Cleaning for php73-pcntl-7.3.16
===> License PHP301 accepted by the user
===> php73-pcntl-7.3.16 depends on file: /usr/local/sbin/pkg - found
===> Fetching all distfiles required by php73-pcntl-7.3.16 for building
===> Extracting for php73-pcntl-7.3.16
=> SHA256 Checksum OK for php-7.3.16.tar.xz.
===> Patching for php73-pcntl-7.3.16
===> php73-pcntl-7.3.16 depends on file: /usr/local/bin/phpize - found
===> php73-pcntl-7.3.16 depends on package: autoconf>0 - found
===> PHPizing for php73-pcntl-7.3.16
===> Configuring for php73-pcntl-7.3.16
Configuring for:
PHP Api Version: 20180731
Zend Module Api No: 20180731
Zend Extension Api No: 320180731
configure: loading site script /usr/ports/Templates/config.site
checking for grep that handles long lines and -e... (cached) /usr/bin/grep
checking for egrep... (cached) /usr/bin/egrep
checking for a sed that does not truncate output... /usr/bin/sed
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking how to run the C preprocessor... cpp
checking for icc... no
checking for suncc... no
checking whether cc understands -c and -o together... yes
checking for system library directory... lib
checking if compiler supports -R... no
checking if compiler supports -Wl,-rpath,... yes
checking build system type... amd64-portbld-freebsd11.3
checking host system type... amd64-portbld-freebsd11.3
checking target system type... amd64-portbld-freebsd11.3
checking for PHP prefix... /usr/local
checking for PHP includes... -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib
checking for PHP extension directory... /usr/local/lib/php/20180731
checking for PHP installed headers prefix... /usr/local/include/php
checking if debug is enabled... no
checking if zts is enabled... no
checking for re2c... no
configure: WARNING: You will need re2c 0.13.4 or later if you want to regenerate PHP parsers.
checking for gawk... (cached) /usr/bin/awk
checking if /usr/bin/awk is broken... no
checking whether to enable pcntl support... yes, shared
checking for fork... (cached) yes
checking for waitpid... (cached) yes
checking for sigaction... (cached) yes
checking for getpriority... yes
checking for setpriority... yes
checking for wait3... (cached) yes
checking for wait4... (cached) yes
checking for sigprocmask... (cached) yes
checking for sigwaitinfo... yes
checking for sigtimedwait... yes
checking for siginfo_t... yes
checking for ld used by cc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for /usr/bin/ld option to reload object files... -r
checking for BSD-compatible nm... /usr/bin/nm
checking whether ln -s works... yes
checking how to recognize dependent libraries... pass_all
checking for ANSI C header files... (cached) yes
checking for sys/types.h... (cached) yes
checking for sys/stat.h... (cached) yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking for memory.h... (cached) yes
checking for strings.h... (cached) yes
checking for inttypes.h... (cached) yes
checking for stdint.h... (cached) yes
checking for unistd.h... (cached) yes
checking for dlfcn.h... (cached) yes
checking the maximum length of command line arguments... (cached) 262144
checking command to parse /usr/bin/nm output from cc object... ok
checking for objdir... .libs
checking for ar... ar
checking for ranlib... ranlib
checking for strip... strip
checking if cc supports -fno-rtti -fno-exceptions... yes
checking for cc option to produce PIC... -fPIC
checking if cc PIC flag -fPIC works... yes
checking if cc static flag -static works... yes
checking if cc supports -c -o file.o... yes
checking whether the cc linker (/usr/bin/ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... freebsd11.3 ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... no
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... no

creating libtool
appending configuration tag "CXX" to libtool
checking whether the c++ linker (/usr/bin/ld) supports shared libraries... yes
checking for c++ option to produce PIC...
checking if c++ static flag works... yes
checking if c++ supports -c -o file.o... yes
checking whether the c++ linker (/usr/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... freebsd11.3 ld.so
(cached) (cached) checking how to hardcode library paths into programs... unsupported
configure: creating ./config.status
config.status: creating config.h
===> Building for php73-pcntl-7.3.16
--- pcntl.lo ---
--- php_signal.lo ---
--- pcntl.lo ---
/bin/sh /usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/libtool --mode=compile cc -DHAVE_STRUCT_SIGINFO_T -I. -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl -DPHP_ATOM_INC -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/include -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/main -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -O2 -pipe -fstack-protector-strong -fno-strict-aliasing -c /usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/pcntl.c -o pcntl.lo
--- php_signal.lo ---
/bin/sh /usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/libtool --mode=compile cc -DHAVE_STRUCT_SIGINFO_T -I. -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl -DPHP_ATOM_INC -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/include -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/main -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -O2 -pipe -fstack-protector-strong -fno-strict-aliasing -c /usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/php_signal.c -o php_signal.lo
--- pcntl.lo ---
mkdir .libs
cc -DHAVE_STRUCT_SIGINFO_T -I. -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl -DPHP_ATOM_INC -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/include -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/main -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -O2 -pipe -fstack-protector-strong -fno-strict-aliasing -c /usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/pcntl.c -fPIC -DPIC -o .libs/pcntl.o
--- php_signal.lo ---
cc -DHAVE_STRUCT_SIGINFO_T -I. -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl -DPHP_ATOM_INC -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/include -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/main -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -O2 -pipe -fstack-protector-strong -fno-strict-aliasing -c /usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/php_signal.c -fPIC -DPIC -o .libs/php_signal.o
--- ./pcntl.la ---
/bin/sh /usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/libtool --mode=link cc -DPHP_ATOM_INC -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/include -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/main -I/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend-I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -O2 -pipe -fstack-protector-strong -fno-strict-aliasing -fstack-protector-strong -o ./pcntl.la -export-dynamic -avoid-version -prefer-pic -module -rpath/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/modules pcntl.lo php_signal.lo
cc -shared .libs/pcntl.o .libs/php_signal.o -Wl,-soname -Wl,pcntl.so -o ./.libs/pcntl.so
creating ./pcntl.la
(cd ./.libs && rm -f pcntl.la && ln -s ../pcntl.la pcntl.la)
--- /usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/modules/pcntl.la ---
/bin/sh /usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/libtool --mode=install cp ./pcntl.la /usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/modules
cp ./.libs/pcntl.so /usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/modules/pcntl.so
cp ./.libs/pcntl.lai /usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/modules/pcntl.la
----------------------------------------------------------------------
Libraries have been installed in:
/usr/ports/devel/php73-pcntl/work/php-7.3.16/ext/pcntl/modules

If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the `-LLIBDIR'
flag during linking and do at least one of the following:
- add LIBDIR to the `LD_LIBRARY_PATH' environment variable
during execution
- add LIBDIR to the `LD_RUN_PATH' environment variable
during linking
- use the `-Wl,--rpath -Wl,LIBDIR' linker flag

See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
----------------------------------------------------------------------
--- all ---

Build complete.
Don't forget to run 'make test'.
===> Staging for php73-pcntl-7.3.16
===> php73-pcntl-7.3.16 depends on file: /usr/local/include/php/main/php.h - found
===> Generating temporary packing list
====> Compressing man pages (compress-man)
===> Installing for php73-pcntl-7.3.16
===> Checking if php73-pcntl is already installed
===> Registering installation for php73-pcntl-7.3.16
[nextcloud] Installing php73-pcntl-7.3.16...
This file has been added to automatically load the installed extension:
/usr/local/etc/php/ext-20-pcntl.ini

/tmp/getcaddy.com 7380 B 110 MBps 00s
Downloading Caddy for freebsd/amd64 (personal license)...
No valid response from keyservers
Extracting...
Putting caddy in /usr/local/bin (may require password)
v1.0.4
Successfully installed
/tmp/latest-18.tar.bz2 82 MB 528 kBps 02m41s
/tmp/latest-18.tar.bz2.asc 819 B 35 MBps 00s
/tmp/nextcloud.asc 3100 B 109 MBps 00s
gpg: Warning: using insecure memory!
gpg: /root/.gnupg/trustdb.gpg: trustdb created
gpg: key D75899B9A724937A: public key "Nextcloud Security <security@nextcloud.com>" imported
gpg: Total number processed: 1
gpg: imported: 1
gpg: Warning: using insecure memory!
gpg: assuming signed data in '/tmp/latest-18.tar.bz2'
gpg: Signature made Wed Mar 18 21:28:40 2020 WIB
gpg: using RSA key D75899B9A724937A
gpg: Good signature from "Nextcloud Security <security@nextcloud.com>" [unknown]
gpg: WARNING: This key is not certified with a trusted signature!
gpg: There is no indication that the signature belongs to the owner.
Primary key fingerprint: 2880 6A87 8AE4 23A2 8372 792E D758 99B9 A724 937A
mysql_enable: -> YES
redis_enable: -> YES
php_fpm_enable: -> YES
Copying Caddyfile for Let's Encrypt cert
caddy_enable: -> YES
caddy_cert_email: -> admin@mydomain.com
caddy_env: ->
* Stopping nextcloud
+ Executing prestop OK
+ Stopping services OK
+ Tearing down VNET OK
+ Removing devfs_ruleset: 5 OK
+ Removing jail process OK
+ Executing poststop OK
No default gateway found for ipv6.
* Starting nextcloud
+ Started OK
+ Using devfs_ruleset: 5
+ Configuring VNET OK
+ Using IP options: vnet
+ Starting services OK
+ Executing poststart OK
Nextcloud was successfully installed
System config value mysql.utf8mb4 set to boolean true
Check indices of the share table.
Check indices of the filecache table.
Check indices of the twofactor_providers table.
Check indices of the login_flow_v2 table.
Check indices of the whats_new table.
Check indices of the cards table.
Check indices of the cards_properties table.
Check indices of the calendarobjects_props table.
Adding calendarobject_calid_index index to the calendarobjects_props table, this can take some time...
calendarobjects_props table updated successfully.
Check indices of the schedulingobjects table.
Adding schedulobj_principuri_index index to the schedulingobjects table, this can take some time...
schedulingobjects table updated successfully.
Following columns will be updated:

* mounts.storage_id
* mounts.root_id
* mounts.mount_id

This can take up to hours, depending on the number of files in your instance!
System config value logtimezone set to string Asia/Jakarta
System config value log_type set to string file
System config value logfile set to string /var/log/nextcloud.log
System config value loglevel set to string 2
System config value logrotate_size set to string 104847600
System config value memcache.local set to string \OC\Memcache\APCu
System config value redis => host set to string /tmp/redis.sock
System config value redis => port set to integer 0
System config value memcache.locking set to string \OC\Memcache\Redis
System config value overwrite.cli.url set to string https://cloud.mydomain.com/
System config value htaccess.RewriteBase set to string /
.htaccess has been updated
System config value trusted_domains => 1 set to string cloud.mydomain.com
System config value trusted_domains => 2 set to string 192.168.0.99
encryption enabled
Encryption enabled

Default module: OC_DEFAULT_MODULE
Encryption disabled
Set mode for background jobs to 'cron'
Successfully removed mount from nextcloud's fstab
Installation complete!
Using your web browser, go to https://cloud.mydomain.com to log in

posting finished.jpg

what i have to do after installer finished ?

i can't access to https://cloud.mydomain.com
This site can’t be reached

when i try to access from https://192.168.0.99 :

192.168.0.99 refused to connect.


Try:
ERR_CONNECTION_REFUSED

please advice..

Thanks n regards,
 
Last edited:
Joined
Jan 4, 2014
Messages
1,644
@InGenetic A couple of things:
  1. Make sure CERT_EMAIL is surrounded with quotes.
  2. You may be able to get past the error by explicitly specifying CONFIG_PATH="/mnt/Volume2/nextcloud/config" in nextcloud-config.
@danb35 Can you please check this section of the script:

Code:
if [ -z "${FILES_PATH}" ]; then
  FILES_PATH="${POOL_PATH}"/nextcloud/files
fi
if [ -z "${CONFIG_PATH}" ]; then
  FILES_PATH="${POOL_PATH}"/nextcloud/config
fi

CONFIG_PATH doesn't actually get defined if not specified in nextcloud-config.

EDIT: If you're planning on updating the script in the repository, can you please also consider this issue?
 
Last edited:

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
Joined
Jan 4, 2014
Messages
1,644
Have you tested the code you provided?
I'll set up a jail and run a modified script against that and get back to you in due course.
 

InGenetic

Contributor
Joined
Dec 18, 2013
Messages
183
hi again ..

if my nextcloud config like below :

JAIL_IP="192.168.0.99"
DEFAULT_GW_IP="192.168.0.1"
POOL_PATH="/mnt/Volume2"
TIME_ZONE="Asia/Jakarta"
HOST_NAME="cloud.mydomain.com"
STANDALONE_CERT=1
CERT_EMAIL=admin@mydomain.com

where the upload data that user's upload will be store ? is it will be store at /mnt/Volume2 ?
cause when i see installer run like below :

+ Using IP options: vnet
+ Starting services OK
+ Executing poststart OK
Destination: /mnt/Volume1/iocage/jails/nextcloud/root/usr/ports does not exist or is not a directory.
Successfully added mount to nextcloud's fstab
Successfully added mount to nextcloud's fstab
Malformed fstab at line 0: '\t/mnt/Volume1/iocage/jails/nextcloud/root/usr/local/www/nextcloud/config\tnullfs\trw\t0\t0'
Successfully added mount to nextcloud's fstab
Successfully added mount to nextcloud's fstab

it means data from user's upload will be store at /mnt/Volume1 ? not in /mnt/Volume2 ??

please advice ..

By the way , i already installed nextcloud,

here's the log :



View attachment 37597
what i have to do after installer finished ?

i can't access to https://cloud.mydomain.com
This site can’t be reached

when i try to access from https://192.168.0.99 :

192.168.0.99 refused to connect.


Try:
ERR_CONNECTION_REFUSED

please advice..

Thanks n regards,
hi .. did anyone can help ?

Regards,
 
Top