Compare commits
3 Commits
75df7a2554
...
devel
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d76624ff43 | ||
|
|
27b237a3c7 | ||
|
|
5349d46d71 |
@@ -84,10 +84,10 @@ if [ "$LOCAL_PHP" == "yes" ]; then
|
|||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
# Packages in Remi repo have names with php$version-php- prefixes
|
# Packages in Remi repo have names with php$version-php- prefixes
|
||||||
mph="php$version-php-fpm php$version-php-cgi php$version-php-mysqlnd php$version-php-pgsql
|
mph="php$version-php-fpm php$version-php-cgi php$version-php-mysqlnd php$version-php-pgsql
|
||||||
php$version-php-pdo php$version-php-common php$version-php-pecl-imagick php$version-php-imap
|
php$version-php-pdo php$version-php-common php$version-php-pecl-imagick php$version-php-imap
|
||||||
php$version-php-ldap php$version-php-pecl-apcu php$version-php-pecl-zip php$version-php-cli
|
php$version-php-ldap php$version-php-pecl-apcu php$version-php-pecl-zip php$version-php-cli
|
||||||
php$version-php-opcache php$version-php-xml php$version-php-gd php$version-php-intl
|
php$version-php-opcache php$version-php-xml php$version-php-gd php$version-php-intl
|
||||||
php$version-php-mbstring php$version-php-pspell php$version-php-readline"
|
php$version-php-mbstring php$version-php-pspell php$version-php-readline"
|
||||||
if [ "$version" = "56" ]; then
|
if [ "$version" = "56" ]; then
|
||||||
mph=$(sed -e "s/php$version-php-pecl-apcu//")
|
mph=$(sed -e "s/php$version-php-pecl-apcu//")
|
||||||
@@ -156,23 +156,15 @@ else
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Check if required modules for apache2 are enabled
|
# Check if required modules for apache2 are enabled
|
||||||
if [ "$WEB_SYSTEM" = "apache2" ]; then
|
if [ "$WEB_SYSTEM" = "httpd" ]; then
|
||||||
if [ -f /etc/redhat-release ]; then
|
if ! httpd -M | grep 'proxy_fcgi_module' ; then
|
||||||
if ! httpd -M | grep 'proxy_fcgi_module' ; then
|
sed 's/#LoadModule proxy_fcgi_module/LoadModule proxy_fcgi_module/' -i /etc/httpd/conf.modules.d/00-proxy.conf
|
||||||
sed 's/#LoadModule proxy_fcgi_module/LoadModule proxy_fcgi_module/' -i /etc/httpd/conf.modules.d/00-proxy.conf
|
sed 's/#LoadModule proxy_module/LoadModule proxy_module/' -i /etc/httpd/conf.modules.d/00-proxy.conf
|
||||||
sed 's/#LoadModule proxy_module/LoadModule proxy_module/' -i /etc/httpd/conf.modules.d/00-proxy.conf
|
|
||||||
fi
|
|
||||||
if ! httpd -M | grep 'setenvif_module' ; then
|
|
||||||
sed 's/#LoadModule setenvif_module/LoadModule setenvif_module/' -i /etc/httpd/conf.modules.d/00-base.conf
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
if ! a2query -q -m proxy_fcgi; then
|
|
||||||
a2enmod -q proxy_fcgi
|
|
||||||
fi
|
|
||||||
if ! a2query -q -m setenvif; then
|
|
||||||
a2enmod -q setenvif
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
|
if ! httpd -M | grep 'setenvif_module' ; then
|
||||||
|
sed 's/#LoadModule setenvif_module/LoadModule setenvif_module/' -i /etc/httpd/conf.modules.d/00-base.conf
|
||||||
|
fi
|
||||||
|
|
||||||
$BIN/v-restart-web "yes"
|
$BIN/v-restart-web "yes"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|||||||
@@ -148,4 +148,4 @@ bundle install
|
|||||||
bundle install --path=vendor
|
bundle install --path=vendor
|
||||||
```
|
```
|
||||||
|
|
||||||
для установки пользователю необходимых гемов локально.
|
для установки пользователю необходимых гемов локально.
|
||||||
|
|||||||
@@ -56,11 +56,12 @@ upgrade_health_check() {
|
|||||||
|
|
||||||
upgrade_welcome_message() {
|
upgrade_welcome_message() {
|
||||||
echo
|
echo
|
||||||
echo ' _ _ _ _ ____ ____ '
|
echo ' _ _ _ _ ____ ____ '
|
||||||
echo ' | | | | ___ ___| |_(_) __ _ / ___| _ \ '
|
echo ' | | | | ___ ___| |_(_) __ _ / ___| _ \ _ _ . . '
|
||||||
echo ' | |_| |/ _ \/ __| __| |/ _` | | | |_) | '
|
echo ' | |_| |/ _ \/ __| __| |/ _` | | | |_) | | \| \|\/| '
|
||||||
echo ' | _ | __/\__ \ |_| | (_| | |___| __/ '
|
echo ' | _ | __/\__ \ |_| | (_| | |___| __/ |_/|_/| | '
|
||||||
echo ' |_| |_|\___||___/\__|_|\__,_|\____|_| '
|
echo ' |_| |_|\___||___/\__|_|\__,_|\____|_| | \| | | '
|
||||||
|
echo " "
|
||||||
echo " "
|
echo " "
|
||||||
echo " Hestia Control Panel Software Update "
|
echo " Hestia Control Panel Software Update "
|
||||||
echo " Version: ${DISPLAY_VER}"
|
echo " Version: ${DISPLAY_VER}"
|
||||||
|
|||||||
@@ -20,15 +20,15 @@ class PassengerWorker < Kernel::ModuleCoreWorker
|
|||||||
ID: 2,
|
ID: 2,
|
||||||
NAME: MODULE_ID,
|
NAME: MODULE_ID,
|
||||||
DESCR: "Added passenger support for nginx",
|
DESCR: "Added passenger support for nginx",
|
||||||
REQ: "puppet_installer",
|
REQ: "",
|
||||||
CONF: "yes",
|
CONF: "yes",
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
def enable
|
def enable
|
||||||
log_file = get_log
|
log_file = get_log
|
||||||
f_inst_pp = get_module_paydata("passenger_installer.pp")
|
f_inst_pp = get_module_paydata("passenger_installer.yml")
|
||||||
f_uninst_pp = get_module_paydata("passenger_uninstaller.pp")
|
f_uninst_pp = get_module_paydata("passenger_uninstaller.yml")
|
||||||
if !check
|
if !check
|
||||||
inf = info
|
inf = info
|
||||||
log("Req error, needed #{inf[:REQ]}")
|
log("Req error, needed #{inf[:REQ]}")
|
||||||
@@ -36,16 +36,16 @@ class PassengerWorker < Kernel::ModuleCoreWorker
|
|||||||
else
|
else
|
||||||
begin
|
begin
|
||||||
prepare_default_ruby_conf
|
prepare_default_ruby_conf
|
||||||
log("install packages for passenger + nginx support: /usr/bin/puppet apply --detailed-exitcodes #{f_inst_pp}")
|
log("install packages for passenger + nginx support: /usr/bin/ansible-playbook -vv #{f_inst_pp}")
|
||||||
result_action = `/usr/bin/puppet apply --detailed-exitcodes "#{f_inst_pp}" 2>&1`
|
result_action = `LC_ALL=C.UTF-8 /usr/bin/ansible-playbook -vv "#{f_inst_pp}" 2>&1`
|
||||||
ex_status = $?.exitstatus
|
ex_status = $?.exitstatus
|
||||||
if ex_status.to_i == 0 || ex_status.to_i == 2
|
if ex_status.to_i == 0 || ex_status.to_i == 2
|
||||||
log(result_action)
|
log(result_action)
|
||||||
super
|
super
|
||||||
else
|
else
|
||||||
log(result_action)
|
log(result_action)
|
||||||
log("Try to disable action: /usr/bin/puppet apply --detailed-exitcodes #{f_uninst_pp}")
|
log("Try to disable action: /usr/bin/ansible-playbook -vv #{f_uninst_pp}")
|
||||||
result_action = `/usr/bin/puppet apply --detailed-exitcodes "#{f_uninst_pp}" 2>&1`
|
result_action = `LC_ALL=C.UTF-8 /usr/bin/ansible-playbook -vv "#{f_uninst_pp}" 2>&1`
|
||||||
"module installation error. See log #{log_file}"
|
"module installation error. See log #{log_file}"
|
||||||
end
|
end
|
||||||
rescue => e
|
rescue => e
|
||||||
@@ -57,14 +57,14 @@ class PassengerWorker < Kernel::ModuleCoreWorker
|
|||||||
|
|
||||||
def disable
|
def disable
|
||||||
log_file = get_log
|
log_file = get_log
|
||||||
f_uninst_pp = get_module_paydata("passenger_uninstaller.pp")
|
f_uninst_pp = get_module_paydata("passenger_uninstaller.yml")
|
||||||
if !check_domains_with_passenger
|
if !check_domains_with_passenger
|
||||||
return log_return("Presents domains with passenger support disable it first")
|
return log_return("Presents domains with passenger support disable it first")
|
||||||
end
|
end
|
||||||
begin
|
begin
|
||||||
log("uninstall packages for passenger + nginx support")
|
log("uninstall packages for passenger + nginx support")
|
||||||
log("Try to disable action: /usr/bin/puppet apply --detailed-exitcodes #{f_uninst_pp}")
|
log("Try to disable action: /usr/bin/ansible-playbook -vv #{f_uninst_pp}")
|
||||||
result_action = `/usr/bin/puppet apply --detailed-exitcodes "#{f_uninst_pp}" 2>&1`
|
result_action = `LC_ALL=C.UTF-8 /usr/bin/ansible-playbook -vv "#{f_uninst_pp}" 2>&1`
|
||||||
ex_status = $?.exitstatus
|
ex_status = $?.exitstatus
|
||||||
if ex_status.to_i == 0 || ex_status.to_i == 2
|
if ex_status.to_i == 0 || ex_status.to_i == 2
|
||||||
log(result_action)
|
log(result_action)
|
||||||
|
|||||||
@@ -0,0 +1,69 @@
|
|||||||
|
---
|
||||||
|
- name: Install Passenger and configure Nginx on localhost
|
||||||
|
hosts: localhost
|
||||||
|
connection: local
|
||||||
|
become: true
|
||||||
|
gather_facts: false
|
||||||
|
environment:
|
||||||
|
LANG: en_US.UTF-8
|
||||||
|
LC_ALL: en_US.UTF-8
|
||||||
|
tasks:
|
||||||
|
# Устанавливаем Ruby и зависимости
|
||||||
|
- name: Install rubygems-devel
|
||||||
|
ansible.builtin.dnf:
|
||||||
|
name: rubygems-devel
|
||||||
|
state: present
|
||||||
|
- name: Install rubygem-rake
|
||||||
|
ansible.builtin.dnf:
|
||||||
|
name: rubygem-rake
|
||||||
|
state: present
|
||||||
|
- name: Install ruby-devel
|
||||||
|
ansible.builtin.dnf:
|
||||||
|
name: ruby-devel
|
||||||
|
state: present
|
||||||
|
- name: Install rubygem-rack
|
||||||
|
ansible.builtin.dnf:
|
||||||
|
name: rubygem-rack
|
||||||
|
state: present
|
||||||
|
- name: Install alt-brepo-ruby33-devel
|
||||||
|
ansible.builtin.dnf:
|
||||||
|
name: alt-brepo-ruby33-devel
|
||||||
|
state: present
|
||||||
|
- name: Install alt-brepo-ruby33-rubygem-rake
|
||||||
|
ansible.builtin.dnf:
|
||||||
|
name: alt-brepo-ruby33-rubygem-rake
|
||||||
|
state: present
|
||||||
|
# Устанавливаем Passenger и модуль Nginx
|
||||||
|
- name: Install passenger-devel
|
||||||
|
ansible.builtin.dnf:
|
||||||
|
name: passenger-devel
|
||||||
|
state: present
|
||||||
|
- name: Install passenger
|
||||||
|
ansible.builtin.dnf:
|
||||||
|
name: passenger
|
||||||
|
state: present
|
||||||
|
- name: Install nginx-mod-http-passenger
|
||||||
|
ansible.builtin.dnf:
|
||||||
|
name: nginx-mod-http-passenger
|
||||||
|
state: present
|
||||||
|
# Конфигурируем Nginx для Passenger
|
||||||
|
- name: Create passenger.conf
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: /etc/nginx/conf.d/passenger.conf
|
||||||
|
content: |
|
||||||
|
passenger_root /usr/share/ruby/vendor_ruby/phusion_passenger/locations.ini;
|
||||||
|
passenger_ruby /usr/bin/ruby;
|
||||||
|
passenger_instance_registry_dir /var/run/passenger-instreg;
|
||||||
|
passenger_user_switching on;
|
||||||
|
passenger_env_var PASSENGER_COMPILE_NATIVE_SUPPORT_BINARY 0;
|
||||||
|
passenger_env_var PASSENGER_DOWNLOAD_NATIVE_SUPPORT_BINARY 0;
|
||||||
|
- name: Create passenger_includer.conf
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: /etc/nginx/conf.d/main/passenger.conf
|
||||||
|
content: |
|
||||||
|
load_module modules/ngx_http_passenger_module.so;
|
||||||
|
# Перезапускаем Nginx
|
||||||
|
- name: Restart nginx service
|
||||||
|
ansible.builtin.service:
|
||||||
|
name: nginx
|
||||||
|
state: restarted
|
||||||
@@ -0,0 +1,38 @@
|
|||||||
|
---
|
||||||
|
- name: Uninstall Passenger and configure Nginx on localhost
|
||||||
|
hosts: localhost
|
||||||
|
connection: local
|
||||||
|
become: true
|
||||||
|
gather_facts: false
|
||||||
|
environment:
|
||||||
|
LANG: en_US.UTF-8
|
||||||
|
LC_ALL: en_US.UTF-8
|
||||||
|
tasks:
|
||||||
|
# Удалаем модуль nginx-passenger
|
||||||
|
- name: Remove nginx-mod-http-passenger package
|
||||||
|
ansible.builtin.dnf:
|
||||||
|
name: nginx-mod-http-passenger
|
||||||
|
state: absent
|
||||||
|
# Удалаем passenger и зависимости
|
||||||
|
- name: Remove passenger-devel package
|
||||||
|
ansible.builtin.dnf:
|
||||||
|
name: passenger-devel
|
||||||
|
state: absent
|
||||||
|
- name: Remove passenger package
|
||||||
|
ansible.builtin.dnf:
|
||||||
|
name: passenger
|
||||||
|
state: absent
|
||||||
|
# Удаляем конфигурационные файлы Nginx
|
||||||
|
- name: Remove passenger.conf
|
||||||
|
ansible.builtin.file:
|
||||||
|
path: /etc/nginx/conf.d/passenger.conf
|
||||||
|
state: absent
|
||||||
|
- name: Remove passenger_includer.conf
|
||||||
|
ansible.builtin.file:
|
||||||
|
path: /etc/nginx/conf.d/main/passenger.conf
|
||||||
|
state: absent
|
||||||
|
# Перезапускаем Nginx (необязательно, но полезно)
|
||||||
|
- name: Restart nginx service
|
||||||
|
ansible.builtin.service:
|
||||||
|
name: nginx
|
||||||
|
state: restarted
|
||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
Name: hestia
|
Name: hestia
|
||||||
Version: 1.9.6
|
Version: 1.9.6
|
||||||
Release: 8%{dist}
|
Release: 9%{dist}
|
||||||
Summary: Hestia Control Panel
|
Summary: Hestia Control Panel
|
||||||
Group: System Environment/Base
|
Group: System Environment/Base
|
||||||
License: GPLv3
|
License: GPLv3
|
||||||
@@ -36,8 +36,7 @@ Requires(post): systemd
|
|||||||
Requires(preun): systemd
|
Requires(preun): systemd
|
||||||
Requires(postun): systemd
|
Requires(postun): systemd
|
||||||
Requires: ruby
|
Requires: ruby
|
||||||
Requires: puppet
|
Requires: ansible-core
|
||||||
Requires: puppet-stdlib
|
|
||||||
|
|
||||||
Provides: hestia = %{version}-%{release}
|
Provides: hestia = %{version}-%{release}
|
||||||
Conflicts: redhat-release < 8
|
Conflicts: redhat-release < 8
|
||||||
@@ -184,6 +183,9 @@ fi
|
|||||||
%{_tmpfilesdir}/%{name}.conf
|
%{_tmpfilesdir}/%{name}.conf
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sun Mar 29 2026 Alexey Berezhok <a@bayrepo.ru> - 1.9.6-9
|
||||||
|
- Added support ansible instead of puppet
|
||||||
|
|
||||||
* Fri Mar 27 2026 Alexey Berezhok <a@bayrepo.ru> - 1.9.6-8
|
* Fri Mar 27 2026 Alexey Berezhok <a@bayrepo.ru> - 1.9.6-8
|
||||||
- Fixed installation of panel without PHP-FPM
|
- Fixed installation of panel without PHP-FPM
|
||||||
- Fixed mod_php, fcgid, fcgi mode
|
- Fixed mod_php, fcgid, fcgi mode
|
||||||
|
|||||||
Reference in New Issue
Block a user