<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Swoole on seth-shi</title><link>https://sethix.com/tags/swoole/</link><description>Recent content in Swoole on seth-shi</description><generator>Hugo -- gohugo.io</generator><language>en</language><lastBuildDate>Tue, 01 Mar 2022 18:12:32 +0800</lastBuildDate><atom:link href="https://sethix.com/tags/swoole/index.xml" rel="self" type="application/rss+xml"/><item><title>Using laravel-s in Docker (Including Queue Usage)</title><link>https://sethix.com/posts/2022030118/</link><pubDate>Tue, 01 Mar 2022 18:12:32 +0800</pubDate><guid>https://sethix.com/posts/2022030118/</guid><description>Environment Configuration FROM phpswoole/swoole:php7.4-alpine # A script for installing PHP extensions COPY --from=mlocati/php-extension-installer /usr/bin/install-php-extensions /usr/local/bin/ RUN install-php-extensions pcntl redis pdo_mysql WORKDIR /var/www COPY . . RUN chmod -R 0777 storage &amp;amp;&amp;amp; \ chmod -R 0777 bootstrap/cache &amp;amp;&amp;amp; \ composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/ &amp;amp;&amp;amp; \ composer install --optimize-autoloader --no-dev &amp;amp;&amp;amp; \ php artisan config:cache &amp;amp;&amp;amp; \ php artisan route:cache &amp;amp;&amp;amp; \ php artisan view:cache &amp;amp;&amp;amp; \ php artisan laravels publish --no-interaction CMD [&amp;#34;php&amp;#34;, &amp;#34;bin/laravels&amp;#34;, &amp;#34;start&amp;#34;, &amp;#34;--env=product&amp;#34;] Deployment ## Build the image docker build .</description></item><item><title>Advanced Usage of Pyroscope for Go and PHP Performance Analysis</title><link>https://sethix.com/posts/2022021516/</link><pubDate>Tue, 15 Feb 2022 16:23:40 +0800</pubDate><guid>https://sethix.com/posts/2022021516/</guid><description>Installation Many online tutorials simply use a single Docker command:
docker run -it -p 4040:4040 --restart=always pyroscope/pyroscope:latest server However, this basic installation lacks crucial configurations: no authentication for the data dashboard, no API reporting restrictions (e.g., limiting reporting via API keys), and no data persistence after container destruction. Here&amp;rsquo;s a better approach using docker-compose.yml: version: &amp;#34;3&amp;#34; services: pyroscope: image: &amp;#34;pyroscope/pyroscope:latest&amp;#34; ports: - &amp;#34;4040:4040&amp;#34; command: - &amp;#34;server&amp;#34; environment: ## Enforce API key authentication for data ingestion - PYROSCOPE_AUTH_INGESTION_ENABLED=true ## Enable login for web dashboard - PYROSCOPE_AUTH_INTERNAL_ENABLED=true volumes: ## Persistent data storage - .</description></item><item><title>Troubleshooting Laravel-S Memory Leak with Swoole Tracker</title><link>https://sethix.com/posts/2022010510/</link><pubDate>Wed, 05 Jan 2022 10:54:45 +0800</pubDate><guid>https://sethix.com/posts/2022010510/</guid><description>Environment Setup Built using swoole:alpine Docker image FROM phpswoole/swoole:php7.4-alpine RUN sed -i &amp;#39;s/dl-cdn.alpinelinux.org/mirrors.aliyun.com/g&amp;#39; /etc/apk/repositories &amp;amp;&amp;amp; cat /etc/apk/repositories # Quick PHP extension installation COPY --from=mlocati/php-extension-installer /usr/bin/install-php-extensions /usr/local/bin/ RUN install-php-extensions pcntl redis pdo_mysql WORKDIR /var/www COPY . . RUN chmod -R 0777 storage &amp;amp;&amp;amp; \ chmod -R 0777 bootstrap/cache &amp;amp;&amp;amp; \ composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/ &amp;amp;&amp;amp; \ composer install --optimize-autoloader --no-dev &amp;amp;&amp;amp; \ php artisan config:cache &amp;amp;&amp;amp; \ php artisan route:cache &amp;amp;&amp;amp; \ php artisan view:cache &amp;amp;&amp;amp; \ php artisan laravels publish --no-interaction CMD [&amp;#34;php&amp;#34;, &amp;#34;bin/laravels&amp;#34;, &amp;#34;start&amp;#34;, &amp;#34;--env=product&amp;#34;] For initial setup, comment out the last two lines in Dockerfile: docker build .</description></item><item><title>Containerizing All Services: Running PHP Code in Containers with Laravel-S</title><link>https://sethix.com/posts/2021102416/</link><pubDate>Sun, 24 Oct 2021 16:05:45 +0800</pubDate><guid>https://sethix.com/posts/2021102416/</guid><description>Preface Recently containerized all Go programs on the server for deployment Combined with CODING&amp;rsquo;s CI/CD, deployment has become extremely pleasant But there were still several PHP projects remaining on the server Blog (Originally built with WordPress) Deploy Nginx and PHP containers, then reverse proxy via host machine Discovered Hugo (similar to Hexo), a static site generator Migrated blog to Hugo with fast builds and real-time previews Now runs in a single Nginx container with host reverse proxy Details: My Blog DreamNote Admin (Laravel) Original Nginx + PHP-FPM container approach Switched to persistent PHP runtime using laravel-s (supports dcat-admin) Official Swoole container docker-swoole with custom Dockerfile: FROM phpswoole/swoole:php7.</description></item></channel></rss>