diff --git a/app/src/App.php b/app/src/App.php index 88a732ab..61853dd3 100644 --- a/app/src/App.php +++ b/app/src/App.php @@ -9,7 +9,7 @@ class App extends Application { - const NAME = "Doil Version 20240902 - build 2024-09-02"; + const NAME = "Doil Version 20240926 - build 2024-09-26"; public function __construct(Command ...$commands) { diff --git a/setup/stack/config/master.cnf b/setup/stack/config/master.cnf index b9bdd3bf..032af8dd 100755 --- a/setup/stack/config/master.cnf +++ b/setup/stack/config/master.cnf @@ -674,6 +674,8 @@ file_roots: - /srv/salt/states/php8.1 php8.2: - /srv/salt/states/php8.2 + php8.3: + - /srv/salt/states/php8.3 ilias: - /srv/salt/states/ilias compile-skins: diff --git a/setup/stack/states/php8.3/description.txt b/setup/stack/states/php8.3/description.txt new file mode 100644 index 00000000..894e1351 --- /dev/null +++ b/setup/stack/states/php8.3/description.txt @@ -0,0 +1 @@ +description = Enables php version 8.3. Disables other php versions. \ No newline at end of file diff --git a/setup/stack/states/php8.3/php/init.sls b/setup/stack/states/php8.3/php/init.sls new file mode 100755 index 00000000..70433054 --- /dev/null +++ b/setup/stack/states/php8.3/php/init.sls @@ -0,0 +1,100 @@ +apt_https: + pkg.installed: + - name: software-properties-common + +php_repo_list: + cmd.run: + - name: echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list + - unless: test -f /etc/apt/sources.list.d/php.list + +php_repo_key: + cmd.run: + - name: wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg + - unless: test -f /etc/apt/trusted.gpg.d/php.gpg + +php8.3: + pkg.installed: + - refresh: True + - skip_verify: True + - pkgs: + - libapache2-mod-php8.3 + - php-json + - php8.3-apcu + - php8.3-bcmath + - php8.3-cli + - php8.3-curl + - php8.3-gd + - php8.3-imap + - php8.3-mbstring + - php8.3-mysql + - php8.3-opcache + - php8.3-readline + - php8.3-soap + - php8.3-xml + - php8.3-xmlrpc + - php8.3-xsl + - php8.3-zip + - php8.3-imagick + +{% for version in ['7.0','7.1','7.2','7.3','7.4','8.0','8.1','8.2'] %} +php{{ version }}: + pkg.purged: + - refresh: True + - pkgs: + - libapache2-mod-php{{ version }} + - php{{ version }}-apcu + - php{{ version }}-bcmath + - php{{ version }}-cli + - php{{ version }}-common + - php{{ version }}-curl + - php{{ version }}-gd + - php{{ version }}-imap + - php{{ version }}-json + - php{{ version }}-mbstring + - php{{ version }}-mysql + - php{{ version }}-opcache + - php{{ version }}-readline + - php{{ version }}-soap + - php{{ version }}-xml + - php{{ version }}-xmlrpc + - php{{ version }}-xsl + - php{{ version }}-zip + - php{{ version }}-imagick +{% endfor %} + +ini_filesize_apache2: + cmd.run: + - name: sed -i "/upload_max_filesize*/c upload_max_filesize = 4096M" /etc/php/8.3/apache2/php.ini + +ini_filesize_cli: + cmd.run: + - name: sed -i "/upload_max_filesize*/c upload_max_filesize = 4096M" /etc/php/8.3/cli/php.ini + +ini_postmax_apache2: + cmd.run: + - name: sed -i "/post_max_size*/c post_max_size = 4096M" /etc/php/8.3/apache2/php.ini + +ini_postmax_cli: + cmd.run: + - name: sed -i "/post_max_size*/c post_max_size = 4096M" /etc/php/8.3/cli/php.ini + +ini_max_execution_time_apache2: + cmd.run: + - name: sed -i "/max_execution_time*/c max_execution_time = 3600" /etc/php/8.3/apache2/php.ini + +ini_max_execution_time_cli: + cmd.run: + - name: sed -i "/max_execution_time*/c max_execution_time = 3600" /etc/php/8.3/cli/php.ini + +a2_enable_php: + module.run: + - name: apache.a2enmod + - mod: php8.3 + +update_alternatives_php: + cmd.run: + - name: update-alternatives --set php /usr/bin/php8.3 &>/dev/null + +apache2_supervisor_signal: + cmd.run: + - name: supervisorctl restart apache2 diff --git a/setup/stack/states/php8.3/top.sls b/setup/stack/states/php8.3/top.sls new file mode 100755 index 00000000..1d51a662 --- /dev/null +++ b/setup/stack/states/php8.3/top.sls @@ -0,0 +1,3 @@ +php8.3: + '*': + - php diff --git a/setup/updates/update-20240926.sh b/setup/updates/update-20240926.sh new file mode 100644 index 00000000..ac109159 --- /dev/null +++ b/setup/updates/update-20240926.sh @@ -0,0 +1,7 @@ +#!/usr/bin/env bash + +doil_update_20240926() { + cp -r ${SCRIPT_DIR}/../app/src/* /usr/local/lib/doil/app/src/ + cp -r ${SCRIPT_DIR}/../setup/stack/* /usr/local/share/doil/stack/ + return $? +} \ No newline at end of file