Microservices on php8

alt=
Dmitry Stremkovskiy
@dzmitry-stremkouski
3 years ago
10 posts
Hello, Jamroom team!
I have created docker compose template file for you to reuse microservices power for jamroom/genosis.
Entrypoints are changed to be as close to base image as possible.
If you want you can create docker image on hub.docker.com based on my work.

I have analyzed .htaccess files and extended nginx.conf based on them. Please update your doc.

Also I was trying to find jamroom sources in some versionning systems to propose my patch, but failed and created special repo to publish patches within github ( https://github.com/mitroko/genosis-phpX/).

I noticed it is not possible to run jamroom/genosis 6.5.9 with php6+
The code itself is not ready for it. I was playing with alpine, boost images of php8 and was forced to downgrate to php5.6

alpine image does not work for jamroom, php lacks of several constants and php-fpm fails to start.
boster image works, but codebase is not ready, lot of deprecated calls
stretch image works fine and my current setup is based on it.

Is it possible to update jamroom/genosis so it would be possible to run it on php8 ?
Also can you publish jamroom/genosis somewhere in code versionning system for collaboration?
Please update core/system checker to not check for APCu, this module is deprecated and disabled since 5.6, it is better to use memcached/redis or opcache instead

Thank you for your products, for your work!
updated by @dzmitry-stremkouski: 10/11/21 03:49:03AM
alt=
@nomoo
3 years ago
12 posts
I've got jamroom/genosis on php 7.3, works just fine.
core version - 6.5.9
genosis core version - 1.8.0
alt=
Dmitry Stremkovskiy
@dzmitry-stremkouski
3 years ago
10 posts
nomoo:
I've got jamroom/genosis on php 7.3, works just fine.
core version - 6.5.9
genosis core version - 1.8.0

Nice, can you also check if pedigree chart works? https://genosis.stremki.net/gencore/pedigree (like this one) ?
Also can you please share php-fpm conf and nginx conf so I would try to reproduce your env with my data?

Thank you!
alt=
@nomoo
3 years ago
12 posts
Quote:
Nice, can you also check if pedigree chart works? https://genosis.stremki.net/gencore/pedigree (like this one) ?
It works, but not as good as it could be:
https://www.jamroom.net/the-jamroom-network/forum/genosis/64277/pedigree-problem
Quote:
Also can you please share php-fpm conf and nginx conf so I would try to reproduce your env with my data?
It can be optimized but these values are almost 'as is':
http {
    include       mime.types;
    default_type  application/octet-stream;

    sendfile       on;
    tcp_nopush     on;

    keepalive_timeout  65;

    gzip  on;

        server {
            server_name server.org;
            add_header Strict-Transport-Security "max-age=31536000; includeSubdomains;";
            add_header X-Frame-Options SAMEORIGIN;
            add_header X-Xss-Protection "1; mode=block" always;
            add_header X-Content-Type-Options "nosniff" always;
            client_max_body_size 100m;

            # Access and Error Logs
            access_log /var/log/nginx/nginx.access.log;
            error_log /var/log/nginx/nginx.error.log;

            # Root Directory
            root /usr/local/www/genosis/;

            location ~ (?:^|/)\. {
                deny all;
            }

            location ~* \.(js|css|png|jpg|jpeg|gif|ico|swf)$ {
                    expires 24h;
                    log_not_found off;
            }

            location @rewrite {
                    rewrite ^(.*)$ /modules/jrCore/router.php?_uri=$1 last;
            }

            location / {
                    index index.html index.php sitemap.xml /modules/jrCore/router.php;
                    try_files $uri $uri/ @rewrite;
            }

            location ~ \.php$ {
                    #NOTE: You should have "cgi.fix_pathinfo = 0;" in php.ini
                    fastcgi_split_path_info ^(.+\.php)(/.+)$;
                    fastcgi_pass unix:/var/run/php-fpm.sock;
                    fastcgi_index index.php;
                    include fastcgi_params;
                    fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
            }
        }
}
[global]
pid = run/php-fpm.pid

[www]
user = www
group = www
listen = /var/run/php-fpm.sock
listen.owner = www
listen.group = www
listen.mode = 0600

pm = dynamic
pm.max_children = 5
pm.start_servers = 2
pm.min_spare_servers = 1
pm.max_spare_servers = 3

php_flag[display_errors] = off
php_admin_value[memory_limit] = 128M

updated by @nomoo: 04/24/21 12:10:22AM

Tags