Skip to content

Instantly share code, notes, and snippets.

@josefglatz
Last active March 31, 2021 11:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save josefglatz/91188e5cb75457bb44db99add5e5cf60 to your computer and use it in GitHub Desktop.
Save josefglatz/91188e5cb75457bb44db99add5e5cf60 to your computer and use it in GitHub Desktop.
TYPO3 10 LTS on organization/institute webspace on univie.ac.at hosting environment (2020-03)
# Adopt one line in the TYPO3 default .htaccess right in your document_root:
# delete `Options -MultiViews`
# see also https://github.com/TYPO3/TYPO3.CMS/blob/440f748a8d75be5a2be516f5c09b99c932942f2c/typo3/sysext/install/Resources/Private/FolderStructureTemplateFiles/root-htaccess#L356
# Add the file ~/html/.user.ini and override specific PHP values for your TYPO3 instance
max_input_vars=3000
post_max_size=1024M

Need to set up the SYS/trustedHostPattern even if the default TYPO3 core value SERVER_NAME is set and $_SERVER['SERVER_NAME'] has the correct value

# example for univie.ac.at subdomain and a dedicated domain with and without www prefix:
    'SYS' => [
        'trustedHostsPattern' => '(www\\.)?organisationalwebsite(\\.univie\\.ac)?.at',
    ],

Need to set up SYS/reverseProxy{IP,SSL} settings due to possible wrong $_SERVER variables

  • $_SERVER['SERVER_PORT'] is 80 (and not 443)
  • missing $_SERVER['HTTPS'] environment variable (there's only a $_SERVER['HTTP_X_ZID_ORIGINAL_HTTPS'] variable)
    'BE' => [
        'lockSSL' => true,
    ],
    'SYS' => [
        'reverseProxyIP'      => '*',
        'reverseProxySSL'     => '*',
    ],

Alternative workaround could be to set $_SERVER['HTTPS'] via AdditionalConfiguration.php for the specific active applicationContext

# instead using SYS/reverseProxy{IP,SSL} settings
$_SERVER['HTTPS'] = $_SERVER['HTTP_X_ZID_ORIGINAL_HTTPS'];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment