Stratus Guides - Install Sourceguardian

For performance reasons, the SourceGuardian Loader for PHP 8 is not installed as default on the Stratus Platform. The following steps can be applied to install it manually for PHP 8.1

Note: SourceGuardian Loader for PHP 8 installation at the server with Webscale Stratus had not been tested, and we cannot guarantee its stability.

To Install SourceGuardian Loader in your Stratus environment, follow these steps:

  1. cd /srv/

  2. Create a folder: mkdir sourceguardian

  3. Get linux x64 loader using the following command: curl 'https://www.sourceguardian.com/loaders/download/loaders.linux-x86_64.tar.gz' -H 'authority: www.sourceguardian.com' -H 'accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9' -H 'accept-language: en-GB,en-US;q=0.9,en;q=0.8,hr;q=0.7' -H 'cache-control: no-cache' -H 'cookie: RGTR=40811663063942; SiteSession1=1csd7upu9i6s3jvuss3v3ueuf7' -H 'pragma: no-cache' -H 'referer: https://www.google.com/' -H 'sec-ch-ua: ""' -H 'sec-ch-ua-mobile: ?0' -H 'sec-ch-ua-platform: ""' -H 'sec-fetch-dest: document' -H 'sec-fetch-mode: navigate' -H 'sec-fetch-site: cross-site' -H 'sec-fetch-user: ?1' -H 'upgrade-insecure-requests: 1' -H 'user-agent: Chrome' --output /srv/sourceguardian/loaders.linux-x86_64.tar.gz

  4. Cd into a folder, extract Sourceguardian loaders and then go back to the /srv/ directory: cd sourceguardian;tar -xvf loaders.linux-x86_64.tar.gz;cd ..

  5.    mkdir php_conf
       cp -a /usr/local/etc/php/conf.d/* php_conf
       cd php_conf/
       rm zzz_custom.ini
       ln -s /usr/local/etc/php/conf.d/zzz_custom.ini ./
       cp /usr/local/etc/php/php.ini ./
    
  6. While still in php_conf dir, create a file named 00_sourceguardian.ini with the following content:

zend_extension=/srv/sourceguardian/ixed.8.1.lin

  1. Edit /srv/.bash_profile file and add the following:
export PHP_INI_SCAN_DIR=/srv/php_conf
  1. Test. Redeploy the environment, and you should be getting, by default, SourceGuardian loader loaded.
www@somewhere:~$ php -v | grep -i Source
    with SourceGuardian v13.0.3, Copyright (c) 2000-2022, by SourceGuardian Ltd.
  1. Open up a ticket with Webscale Stratus support, so we can add the following environment variables for PHP-FPM.
PHP_INI_SCAN_DIR = /srv/php_conf

Last modified January 1, 0001