Resource icon

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

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,464
A number of updates to the script today, mostly in error handling--the script now makes sure it's running as root, that nextcloud-config exists, and that it sets all the required variables. It should also have the executable permissions set now, so you won't need to change that yourself.
 

cunningorb

Explorer
Joined
Feb 5, 2018
Messages
58
nano nextcloud-config
Ah, then you should be much better equipped than I to deal with this--I'm a lawyer.
Honestly, I'm not even going to rule this out. I was using filezilla to upload my nextcloud-config file to the appropriate directory. This time I used nano as above, so far it is working.

Yeah you may be a lawyer but that is one neat script you've got there developed outside (or inside?) the courtroom.

I will edit once the script finished but we are already beyond the point of errors from last several attempts.
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,464
I was using filezilla to upload my nextcloud-config file to the appropriate directory
Hmmm. Upload from a Windows machine? Newline characters? I had an issue with those yesterday that broke the script for a bit...
 

cunningorb

Explorer
Joined
Feb 5, 2018
Messages
58
Hmmm. Upload from a Windows machine? Newline characters? I had an issue with those yesterday that broke the script for a bit...
Yep I'm on windows. Either filezilla screws up permissions somehow or something was getting added incorrectly, but the script ran this time. However the jail is giving trouble, it states it is down and here is the logs.
Code:
2018/03/20 21:38:00 (INFO) Setting up zpool [orb1] for iocage usage
 If you wish to change please use "iocage activate"
2018/03/20 21:38:00 (INFO) Creating orb1/iocage
2018/03/20 21:38:00 (INFO) Creating orb1/iocage/download
2018/03/20 21:38:01 (INFO) Creating orb1/iocage/images
2018/03/20 21:38:01 (INFO) Creating orb1/iocage/jails
2018/03/20 21:38:01 (INFO) Creating orb1/iocage/log
2018/03/20 21:38:01 (INFO) Creating orb1/iocage/releases
2018/03/20 21:38:01 (INFO) Creating orb1/iocage/templates
2018/03/20 21:38:01 (DEBUG) Starting new HTTPS connection (1): www.freebsd.org
2018/03/20 21:38:01 (DEBUG) https://www.freebsd.org:443 "GET /security/unsupported.html HTTP/1.1" 200 20769
2018/03/20 21:38:01 (DEBUG) Starting new HTTP connection (1): download.freebsd.org
2018/03/20 21:38:02 (DEBUG) http://download.freebsd.org:80 "GET /ftp/releases/amd64 HTTP/1.1" 301 178
2018/03/20 21:38:02 (DEBUG) Starting new HTTPS connection (1): download.freebsd.org
2018/03/20 21:38:02 (DEBUG) https://download.freebsd.org:443 "GET /ftp/releases/amd64 HTTP/1.1" 301 178
2018/03/20 21:38:02 (DEBUG) https://download.freebsd.org:443 "GET /ftp/releases/amd64/ HTTP/1.1" 200 None
2018/03/20 21:38:02 (DEBUG) Starting new HTTP connection (1): download.freebsd.org
2018/03/20 21:38:02 (DEBUG) http://download.freebsd.org:80 "GET /ftp/releases/amd64/11.1-RELEASE HTTP/1.1" 301 178
2018/03/20 21:38:02 (DEBUG) Starting new HTTPS connection (1): download.freebsd.org
2018/03/20 21:38:02 (DEBUG) https://download.freebsd.org:443 "GET /ftp/releases/amd64/11.1-RELEASE HTTP/1.1" 301 178
2018/03/20 21:38:02 (DEBUG) https://download.freebsd.org:443 "GET /ftp/releases/amd64/11.1-RELEASE/ HTTP/1.1" 200 None
2018/03/20 21:38:02 (INFO) Fetching: 11.1-RELEASE

2018/03/20 21:38:02 (DEBUG) Starting new HTTP connection (1): download.freebsd.org
2018/03/20 21:38:03 (DEBUG) http://download.freebsd.org:80 "GET /ftp/releases/amd64/11.1-RELEASE/MANIFEST HTTP/1.1" 301 178
2018/03/20 21:38:03 (DEBUG) Starting new HTTPS connection (1): download.freebsd.org
2018/03/20 21:38:03 (DEBUG) https://download.freebsd.org:443 "GET /ftp/releases/amd64/11.1-RELEASE/MANIFEST HTTP/1.1" 200 1157
2018/03/20 21:38:03 (DEBUG) Starting new HTTP connection (1): download.freebsd.org
2018/03/20 21:38:03 (DEBUG) http://download.freebsd.org:80 "GET /ftp/releases/amd64/11.1-RELEASE/base.txz HTTP/1.1" 301 178
2018/03/20 21:38:03 (DEBUG) Starting new HTTPS connection (1): download.freebsd.org
2018/03/20 21:38:03 (DEBUG) https://download.freebsd.org:443 "GET /ftp/releases/amd64/11.1-RELEASE/base.txz HTTP/1.1" 200 104780108
2018/03/20 21:38:19 (DEBUG) Starting new HTTP connection (1): download.freebsd.org
2018/03/20 21:38:19 (DEBUG) http://download.freebsd.org:80 "GET /ftp/releases/amd64/11.1-RELEASE/lib32.txz HTTP/1.1" 301 178
2018/03/20 21:38:19 (DEBUG) Starting new HTTPS connection (1): download.freebsd.org
2018/03/20 21:38:19 (DEBUG) https://download.freebsd.org:443 "GET /ftp/releases/amd64/11.1-RELEASE/lib32.txz HTTP/1.1" 200 18499068
2018/03/20 21:38:22 (DEBUG) Starting new HTTP connection (1): download.freebsd.org
2018/03/20 21:38:22 (DEBUG) http://download.freebsd.org:80 "GET /ftp/releases/amd64/11.1-RELEASE/doc.txz HTTP/1.1" 301 178
2018/03/20 21:38:22 (DEBUG) Starting new HTTPS connection (1): download.freebsd.org
2018/03/20 21:38:22 (DEBUG) https://download.freebsd.org:443 "GET /ftp/releases/amd64/11.1-RELEASE/doc.txz HTTP/1.1" 200 1428656
2018/03/20 21:38:23 (DEBUG) Starting new HTTP connection (1): download.freebsd.org
2018/03/20 21:38:23 (DEBUG) http://download.freebsd.org:80 "GET /ftp/releases/amd64/11.1-RELEASE/src.txz HTTP/1.1" 301 178
2018/03/20 21:38:23 (DEBUG) Starting new HTTPS connection (1): download.freebsd.org
2018/03/20 21:38:23 (DEBUG) https://download.freebsd.org:443 "GET /ftp/releases/amd64/11.1-RELEASE/src.txz HTTP/1.1" 200 147661560
2018/03/20 21:38:45 (INFO) Extracting: base.txz...
2018/03/20 21:39:24 (INFO) Extracting: lib32.txz...
2018/03/20 21:39:28 (INFO) Extracting: doc.txz...
2018/03/20 21:39:30 (INFO) Extracting: src.txz...
2018/03/20 21:41:02 (INFO)
* Updating 11.1-RELEASE to the latest patch level...
2018/03/20 21:41:43 (INFO) nextcloud successfully created!
2018/03/20 21:41:46 (INFO) nextcloud is not running, starting jail
2018/03/20 21:41:48 (INFO) nextcloud is not running, starting jail
2018/03/20 21:41:50 (INFO) nextcloud is not running, starting jail
2018/03/20 21:41:53 (INFO) Successfully added mount to nextcloud's fstab
2018/03/20 21:41:55 (INFO) Successfully added mount to nextcloud's fstab
2018/03/20 21:41:57 (INFO) Successfully added mount to nextcloud's fstab
2018/03/20 21:41:59 (INFO) Successfully added mount to nextcloud's fstab
2018/03/20 21:42:02 (INFO) Successfully added mount to nextcloud's fstab
2018/03/20 21:42:04 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:06 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:09 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:11 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:13 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:16 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:18 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:20 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:22 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:25 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:27 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:29 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:32 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:34 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:36 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:39 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:41 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:43 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:46 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:48 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:50 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:52 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:55 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:57 (INFO) nextcloud is not running, starting jail
2018/03/20 21:42:59 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:02 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:04 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:06 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:09 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:11 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:13 (ERROR) nextcloud is not running!
2018/03/20 21:43:16 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:18 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:20 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:23 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:25 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:28 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:30 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:32 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:34 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:37 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:39 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:41 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:44 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:46 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:48 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:51 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:53 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:55 (INFO) nextcloud is not running, starting jail
2018/03/20 21:43:58 (INFO) nextcloud is not running, starting jail
2018/03/20 21:44:00 (INFO) nextcloud is not running, starting jail
2018/03/20 21:44:02 (INFO) nextcloud is not running, starting jail
2018/03/20 21:44:05 (INFO) nextcloud is not running, starting jail
2018/03/20 21:44:07 (INFO) nextcloud is not running, starting jail
2018/03/20 21:44:09 (INFO) Successfully removed mount from nextcloud's fstab
2018/03/20 21:46:54 (INFO) +-----+-----------+-------+--------------+--------------+
| JID |   NAME	| STATE |   RELEASE	|	 IP4	  |
+=====+===========+=======+==============+==============+
| -   | nextcloud | down  | 11.1-RELEASE | 192.168.1.66 |
+-----+-----------+-------+--------------+--------------+
2018/03/20 21:47:15 (ERROR) ZFS pool 'nextcloud' not found!


I get a "KeyError vnet_interface" message a lot during the script running. Could this be related: https://forums.freenas.org/index.php?threads/iocage-vnet0-and-bridge0.59964/
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,464

cunningorb

Explorer
Joined
Feb 5, 2018
Messages
58
The issues described in that thread should only apply if you're using vnet networking, which you shouldn't be. What's the output of ifconfig and the contents of nextcloud-config?
Code:
root@freenas:~ # ifconfig
em0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
		options=9b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM>
		ether 00:0c:29:28:56:27
		hwaddr 00:0c:29:28:56:27
		inet 192.168.1.118 netmask 0xffffff00 broadcast 192.168.1.255
		nd6 options=9<PERFORMNUD,IFDISABLED>
		media: Ethernet autoselect (1000baseT <full-duplex>)
		status: active
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
		options=600003<RXCSUM,TXCSUM,RXCSUM_IPV6,TXCSUM_IPV6>
		inet6 ::1 prefixlen 128
		inet6 fe80::1%lo0 prefixlen 64 scopeid 0x2
		inet 127.0.0.1 netmask 0xff000000
		nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
		groups: lo

Code:
JAIL_IP="192.168.1.66"
DEFAULT_GW_IP="192.168.1.1"
INTERFACE="em0"
POOL_PATH="/mnt/orb1"
JAIL_NAME="nextcloud"
TIME_ZONE="America/Detroit" # See http://php.net/manual/en/timezones.php
HOST_NAME="mydomaingoeshereyup.com"
STANDALONE_CERT=1
DNS_CERT=0
TEST_CERT="--test"
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,464
That all looks right, so it's odd that you're getting messages dealing with a vnet interface. Can you destroy this jail ( iocage destroy -f nextcloud) and try manually creating it at the command line? This command should do it:
Code:
iocage create --name "nextcloud" -r 11.1-RELEASE ip4_addr="em0|192.168.1.66/24" defaultrouter="192.168.1.1" boot="on" host_hostname="nextcloud"
 

cunningorb

Explorer
Joined
Feb 5, 2018
Messages
58
That all looks right, so it's odd that you're getting messages dealing with a vnet interface. Can you destroy this jail ( iocage destroy -f nextcloud) and try manually creating it at the command line? This command should do it:
Code:
iocage create --name "nextcloud" -r 11.1-RELEASE ip4_addr="em0|192.168.1.66/24" defaultrouter="192.168.1.1" boot="on" host_hostname="nextcloud"
Code:
Destroying nextcloud
root@freenas:/mnt/orb1/share/freenas-iocage-nextcloud # iocage create --name "nextcloud" -r 11.1-RELEASE ip4_addr="em0|192.168.1.66/24" defaultrouter="192.168.1.1" boot="on" host_hostname="nextcloud"
nextcloud successfully created!
* Starting nextcloud
  + Started OK
  + Starting services OK
root@freenas:/mnt/orb1/share/freenas-iocage-nextcloud # iocage list
+-----+-----------+-------+--------------+--------------+
| JID |   NAME	| STATE |   RELEASE	|	 IP4	  |
+=====+===========+=======+==============+==============+
| 1   | nextcloud | up	| 11.1-RELEASE | 192.168.1.66 |
+-----+-----------+-------+--------------+--------------+
root@freenas:/mnt/orb1/share/freenas-iocage-nextcloud #

And for what it's worth here is the full text of the relevant error I was getting while the script ran:
Code:
   File "/usr/local/lib/python3.6/site-packages/iocage/lib/ioc_start.py", line 127, in __start_jail__
	vnet_interfaces = self.conf["vnet_interfaces"]
KeyError: 'vnet_interfaces'

Noteworthy: that whole attempt above was on a fresh vm, I had deleted and reinstalled from scratch again since it only takes 10 minutes.

I am re-running the script with the jail already created to see how it goes.
 

cunningorb

Explorer
Joined
Feb 5, 2018
Messages
58
Did the script finish successfully?
No I'm afraid not. It may not be the script but after it finished I was being blocked (server not responding) on 443 and getting redirected to freenas gui on port 80 at the jail IP.
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,464
This is getting very strange. Can you try creating the jail manually from scratch, then enter the jail ( iocage console nextcloud) and try to install a package like nano?
 

cunningorb

Explorer
Joined
Feb 5, 2018
Messages
58
This is getting very strange. Can you try creating the jail manually from scratch, then enter the jail ( iocage console nextcloud) and try to install a package like nano?
I'm attempting this but not sure if I will finish tonight. Will update as soon as I can!

Edit: running into that python error thing I keep getting which I wasn't getting before on manually creating the jail.
Code:
nextcloud successfully created!
Traceback (most recent call last):
  File "/usr/local/bin/iocage", line 10, in <module>
	sys.exit(cli())
  File "/usr/local/lib/python3.6/site-packages/click/core.py", line 722, in __call__
	return self.main(*args, **kwargs)
  File "/usr/local/lib/python3.6/site-packages/click/core.py", line 697, in main
	rv = self.invoke(ctx)
  File "/usr/local/lib/python3.6/site-packages/click/core.py", line 1066, in invoke
	return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/usr/local/lib/python3.6/site-packages/click/core.py", line 895, in invoke
	return ctx.invoke(self.callback, **ctx.params)
  File "/usr/local/lib/python3.6/site-packages/click/core.py", line 535, in invoke
	return callback(*args, **kwargs)
  File "/usr/local/lib/python3.6/site-packages/iocage/cli/create.py", line 145, in cli
	basejail=basejail, empty=empty)
  File "/usr/local/lib/python3.6/site-packages/iocage/lib/iocage.py", line 644, in create
	exit_on_error=self.exit_on_error).create_jail()
  File "/usr/local/lib/python3.6/site-packages/iocage/lib/ioc_create.py", line 86, in create_jail
	return self._create_jail(jail_uuid, location)
  File "/usr/local/lib/python3.6/site-packages/iocage/lib/ioc_create.py", line 449, in _create_jail
	silent=self.silent)
  File "/usr/local/lib/python3.6/site-packages/iocage/lib/ioc_start.py", line 64, in __init__
	self.__start_jail__()
  File "/usr/local/lib/python3.6/site-packages/iocage/lib/ioc_start.py", line 127, in __start_jail__
	vnet_interfaces = self.conf["vnet_interfaces"]
KeyError: 'vnet_interfaces'
 
Last edited:

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,464
Can you revert to a clean install of 11.1-U2 and try manually creating the jail there? @kjake indicates that -U3 has broken vnet networking, which we shouldn't be using here, but which your error messages still seem to suggest.

While we're trying to figure this out, I've been working on improving the other configuration options. The various config files now have the system set up to do HTTP/2 and PHP-FPM, which should help performance quite a bit.
 

cunningorb

Explorer
Joined
Feb 5, 2018
Messages
58
Can you revert to a clean install of 11.1-U2 and try manually creating the jail there? @kjake indicates that -U3 has broken vnet networking, which we shouldn't be using here, but which your error messages still seem to suggest.

While we're trying to figure this out, I've been working on improving the other configuration options. The various config files now have the system set up to do HTTP/2 and PHP-FPM, which should help performance quite a bit.
The script ran on 11.1-U2 much as I expect it runs for you. I did still get an error though and the jail IP redirects to freenas gui.
Code:
./nextcloud-jail.sh: 182: Syntax error: end of file unexpected (expecting "fi")
root@freenas:/mnt/orb1/share/freenas-iocage-nextcloud # iocage list
+-----+-----------+-------+--------------+-------------+
| JID |   NAME	| STATE |   RELEASE	|	 IP4	 |
+=====+===========+=======+==============+=============+
| 2   | nextcloud | up	| 11.1-RELEASE | 192.168.1.2 |
+-----+-----------+-------+--------------+-------------+
root@freenas:/mnt/orb1/share/freenas-iocage-nextcloud #

Code:
em0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
		options=9b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM>
		ether 00:0c:29:28:56:27
		hwaddr 00:0c:29:28:56:27
		inet 192.168.1.118 netmask 0xffffff00 broadcast 192.168.1.255
		inet 192.168.1.2 netmask 0xffffff00 broadcast 192.168.1.255
		nd6 options=9<PERFORMNUD,IFDISABLED>
		media: Ethernet autoselect (1000baseT <full-duplex>)
		status: active
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
		options=600003<RXCSUM,TXCSUM,RXCSUM_IPV6,TXCSUM_IPV6>
		inet6 ::1 prefixlen 128
		inet6 fe80::1%lo0 prefixlen 64 scopeid 0x2
		inet 127.0.0.1 netmask 0xff000000
		nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
		groups: lo
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,464
Syntax error: end of file unexpected (expecting "fi")
Oh, bother. It's the simple things... Either do git pull again, or just fix line 116--change "else if" to "elif".
 

cunningorb

Explorer
Joined
Feb 5, 2018
Messages
58
Oh, bother. It's the simple things... Either do git pull again, or just fix line 116--change "else if" to "elif".
I can tell already it will probably work. It will take me about 30 minutes though. Before I started I just did a quick fix to the iocage network issue based on this post here: https://forums.freenas.org/index.php?threads/iocage-no-route-to-gateway-from-jail.60352/
That allowed me to get to mydomain.com (It works!) as well as mydomain.com/nextcloud (just loaded index.php in plain text). Good progress, can't wait to rerun this script from fresh 11.1-U2 install. Doing a snapshot before this time so I don't have to keep re-configuring the darn VM.

Edit (final?): I AM IN. @danb35 thank you so much for this script. It will help many users trying to create a nextcloud on freenas using version 11.1-U2 of freenas and version 13 of nextcloud. Here were my final, very easy steps via command line to run the script.

From freenas userspace shell: cd /mnt/poolname/optionaldatasetlocation then get the script git clone https://github.com/danb35/freenas-iocage-nextcloud
Next enter the newly created directory cd freenas-iocage-nextcloud
Then create the config file nano nextcloud-config
Paste in your customized version of this:
Code:
JAIL_IP="192.168.1.199"
DEFAULT_GW_IP="192.168.1.1"
INTERFACE="igb0"
POOL_PATH="/mnt/tank"
JAIL_NAME="nextcloud"
TIME_ZONE="America/New_York" # See http://php.net/manual/en/timezones.php
HOST_NAME="YOUR_FQDN"
STANDALONE_CERT=0
DNS_CERT=0
TEST_CERT="--test"

Exit with Ctrl+X on a PC, probably command + x on mac (assuming this).
Run the script, don't worry about what directory you are in when you run it ./nextcloud-jail.sh
Walk away, seriously. For 25 minutes or so depending on hardware. Done.
 
Last edited:

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,464
So now it's working for @cunningorb too, so I feel a bit better about it. However, we're both seeing one issue--client apps don't seem to be able to log in. On iOS, I'm seeing that the app keeps looping back to the login screen; on the Mac Desktop app, it's saying "connection refused" after entering the username/password. I'll assume this is something I'm doing wrong with the configuration somewhere and try to track it down (probably asking the Nextcloud forums), but if anyone else has input it would be appreciated.
Edit: There's one report that really sounds like the same issue, and another that could be. It sounds like using mpm_event/php-fpm is a common thread. I'd like to keep those in there for performance reasons though. Still looking...
 
Last edited:

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,464
OK, I think I have the client login issue sorted. You can git pull a new version, or just make a couple of edits:

To /usr/local/etc/apache24/includes/yourhostname.conf, add these lines between the DocumentRoot and the ProxyPass lines:
Code:
  RewriteEngine On
  RewriteCond %{HTTP:Authorization} ^(.*)
  RewriteRule .* - [e=HTTP_AUTHORIZATION:%1]

...and in /usr/local/etc/php-fpm.d/www.conf, uncomment these lines:
Code:
env[HOSTNAME] = $HOSTNAME
env[PATH] = /usr/local/bin:/usr/bin:/bin
env[TMP] = /tmp
env[TMPDIR] = /tmp
env[TEMP] = /tmp

(they're lines 388-392 in my copy). Restart the apache24 and php-fpm services and see if that works.
 

cunningorb

Explorer
Joined
Feb 5, 2018
Messages
58
OK, I think I have the client login issue sorted. You can git pull a new version, or just make a couple of edits:

To /usr/local/etc/apache24/includes/yourhostname.conf, add these lines between the DocumentRoot and the ProxyPass lines:
Code:
  RewriteEngine On
  RewriteCond %{HTTP:Authorization} ^(.*)
  RewriteRule .* - [e=HTTP_AUTHORIZATION:%1]

...and in /usr/local/etc/php-fpm.d/www.conf, uncomment these lines:
Code:
env[HOSTNAME] = $HOSTNAME
env[PATH] = /usr/local/bin:/usr/bin:/bin
env[TMP] = /tmp
env[TMPDIR] = /tmp
env[TEMP] = /tmp

(they're lines 388-392 in my copy). Restart the apache24 and php-fpm services and see if that works.
This completely solved it. Well done!
 
Top