CRM выдает ошибку Есть решение

Всем привет и хороших дней!

Пытаюсь настроить локально в Докере и вроде все завелось и все хорошо, но есть один нюанс =)

PHP

Отмечу, что на сервере все работает хорошо, думаю, что есть проблема в настройках NGINX.
Все что есть на форуме и в инете, уже прочитал, помогите, пожалуйста, понять что не так в настройках:

server {
    listen 80 default;
    server_name localhost;
    client_max_body_size 108M;

    fastcgi_buffers 16 16k;
    fastcgi_buffer_size 32k;

    root /webasyst;
    index index.php;

    access_log /var/log/nginx/application.access.log;
    fastcgi_param PHP_VALUE "error_log=$document_root/wa-log/wa71_php_errors.log";

    # try_files $uri $uri/ /index.php?$query_string;
    try_files $uri $uri/ /index.php?$args;

    # location /index.php {
    #     fastcgi_pass php-fpm:9000;
    #     fastcgi_index index.php;
    #     fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
    #     include fastcgi_params;
    # }
    location ~ \.php$ {
        try_files $uri =404;
        fastcgi_split_path_info ^(.+\.php)(/.+)$;
        fastcgi_pass php-fpm:9000;
        fastcgi_index index.php;
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_param PATH_INFO $fastcgi_path_info;
    }

    # for install only
    # location /install.php {
    #     fastcgi_pass php-fpm:9000;
    #     fastcgi_index install.php;
    #     include fastcgi_params;
    # }    
    
    # location /api.php {
    #     fastcgi_split_path_info  ^(.+\.php)(.*)$;
    #     fastcgi_pass php-fpm:9000;
    #     include fastcgi_params;
    # }    

    location ^~ /wa-data/protected/ {
        #return 403;
        #X-Accel-Redirect
        internal;
    }

    location ~* ^/wa-(log|config|cache|system)/ {
        return 403;
    }

    location ~* ^/wa-data/public/contacts/photos/[0-9]+/ {
#         root /var/www/fw/;
         access_log off;
         expires  30d;
         error_page   404  =  @contacts_thumb;
    }

    location @contacts_thumb {
        fastcgi_pass php-fpm:9000;
        include fastcgi_params;
        fastcgi_param  SCRIPT_NAME  /wa-data/public/contacts/photos/thumb.php;
        fastcgi_param  SCRIPT_FILENAME  $document_root/wa-data/public/contacts/photos/thumb.php;
    }
  
    # photos app
    location ~* ^/wa-data/public/photos/[0-9]+/ {
        access_log   off;
        expires      30d;
        error_page   404  =  @photos_thumb;
    }

    location @photos_thumb {
        fastcgi_pass php-fpm:9000;
        include fastcgi_params;
        fastcgi_param  SCRIPT_NAME  /wa-data/public/photos/thumb.php;
        fastcgi_param  SCRIPT_FILENAME  $document_root/wa-data/public/photos/thumb.php;
    }
    # end photos app
    
    # shop app
    location ~* ^/wa-data/public/shop/products/[0-9]+/ {
        access_log   off;
        expires      30d;
        error_page   404  =  @shop_thumb;
    }
    location @shop_thumb {
        fastcgi_pass php-fpm:9000;
        include fastcgi_params;
        fastcgi_param  SCRIPT_NAME  /wa-data/public/shop/products/thumb.php;
        fastcgi_param  SCRIPT_FILENAME  $document_root/wa-data/public/shop/products/thumb.php;
    }
    # end shop app
    
    # mailer app
    location ~* ^/wa-data/public/mailer/files/[0-9]+/ {
        access_log   off;
        error_page   404  =  @mailer_file;
    }
    location @mailer_file {
        fastcgi_pass php-fpm:9000;
        include fastcgi_params;
        fastcgi_param  SCRIPT_NAME  /wa-data/public/mailer/files/file.php;
        fastcgi_param  SCRIPT_FILENAME $document_root/wa-data/public/mailer/files/file.php;
    }
    # end mailer app

    location ~* ^.+\.(jpg|jpeg|gif|png|js|css)$ {
        access_log   off;
        expires      30d;
    }    
}

Dockerfile

FROM php:8.3-fpm

# Install selected extensions and other stuff

RUN apt-get clean && apt-get update && apt-get install -y \
    libzip-dev \
    libpng-dev \
    libjpeg-dev \
    libfreetype6-dev \
    libmagickwand-dev \
    libonig-dev \
    libxslt-dev \
    && docker-php-ext-configure gd --with-freetype --with-jpeg \
    && docker-php-ext-install -j$(nproc) gd \
    && docker-php-ext-install -j$(nproc) mysqli \
    && docker-php-ext-install -j$(nproc) pdo_mysql \
    && docker-php-ext-install -j$(nproc) zip \
    && docker-php-ext-install -j$(nproc) bz2 \
    && docker-php-ext-install -j$(nproc) mbstring \
    && docker-php-ext-install -j$(nproc) soap \
    && docker-php-ext-install -j$(nproc) xsl \
    && docker-php-ext-install -j$(nproc) exif
# git \
# tini \
# unzip \
# dos2unix \

# RUN apt-get update \
#     && apt-get -y --no-install-recommends install  php8.2-mysql php8.2-bz2 php8.2-gd php-imagick php8.2-mbstring php8.2-soap php-ssh2 php8.2-xsl php-yaml php-xdebug locales \
#     && sed -i 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen \
#     && sed -i 's/# ru_RU.UTF-8 UTF-8/ru_RU.UTF-8 UTF-8/' /etc/locale.gen \
#     && locale-gen \
#     && apt-get clean; rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /usr/share/doc/*

WORKDIR "/webasyst"

Вот эта ошибка висит на любой странице:

Deprecated: Return type of cashShopSettings::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /webasyst/wa-apps/cash/lib/class/Dto/cashDtoJsonSerializableTrait.class.php on line 11

Вот эти ошибки висят на странице приложения "Деньги":

Deprecated: Return type of cashAbstractDto::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /webasyst/wa-apps/cash/lib/class/Dto/cashAbstractDto.class.php on line 18

Deprecated: Return type of cashCurrencyVO::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /webasyst/wa-apps/cash/lib/class/VO/cashCurrencyVO.class.php on line 140

Deprecated: Return type of cashShopSettings::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /webasyst/wa-apps/cash/lib/class/Dto/cashDtoJsonSerializableTrait.class.php on line 11

Вот эти ошибки висят в приложении "Задачи":

Deprecated: Return type of tasksTask::offsetExists($offset) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /webasyst/wa-apps/tasks/lib/classes/tasksTask.class.php on line 918

Deprecated: Return type of tasksTask::offsetGet($offset) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /webasyst/wa-apps/tasks/lib/classes/tasksTask.class.php on line 930

Deprecated: Return type of tasksTask::offsetSet($offset, $value) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /webasyst/wa-apps/tasks/lib/classes/tasksTask.class.php on line 942

Deprecated: Return type of tasksTask::offsetUnset($offset) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /webasyst/wa-apps/tasks/lib/classes/tasksTask.class.php on line 953

1 ответ

  • 0
    Katvizkiy Stanislav 4 апреля 2024 22:41 # Решение

    не хватало переменных, которые описаны в самом низу документации
    Вопрос решен. закройте пожалуйста тему

Эта тема в архиве. Добавление комментариев к ней отключено.