File tree Expand file tree Collapse file tree 4 files changed +22
-13
lines changed Expand file tree Collapse file tree 4 files changed +22
-13
lines changed Original file line number Diff line number Diff line change @@ -25,20 +25,22 @@ jobs:
2525 - name : Checkout.
2626 uses : actions/checkout@v5
2727
28- - name : Install docker compose .
28+ - name : Show docker version .
2929 run : |
30- sudo curl -L "https://github.com/docker/compose/releases/latest/download/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
31- sudo chmod +x /usr/local/bin/docker-compose
32- docker-compose --version
30+ docker version
31+ docker compose version
3332
3433 - name : Build and start containers.
35- run : docker- compose up -d --build
34+ run : docker compose up -d --build
3635
37- - name : Wait for container to be ready .
36+ - name : Wait for readiness .
3837 run : |
39- echo "Waiting 30 seconds for container initialization..."
40- sleep 30
41- docker logs yii2-nginx
38+ for i in {1..60}; do
39+ if docker exec yii2-nginx sh -lc "curl -ksS -o /dev/null -w '%{http_code}' https://localhost | grep -qE '200|302'"; then
40+ echo "Service is ready"; exit 0; fi
41+ sleep 2
42+ done
43+ echo "Service not ready"; docker logs yii2-nginx; exit 1
4244
4345 - name : Codeceptcion build.
4446 run : docker exec yii2-nginx vendor/bin/codecept build
Original file line number Diff line number Diff line change 44 server_name localhost;
55
66 # Redirect all HTTP to HTTPS
7- return 301 https://localhost:8445 $request_uri;
7+ return 301 https://$host $request_uri;
88}
99
1010# HTTPS server
@@ -82,7 +82,7 @@ server {
8282 # Static files handling with caching
8383 location ~* \.(js|css|png|jpg|jpeg|gif|ico|svg|woff|woff2|ttf|eot)$ {
8484 expires 1y;
85- add_header Cache-Control "web , immutable";
85+ add_header Cache-Control "public , immutable";
8686 try_files $uri =404;
8787 }
8888
Original file line number Diff line number Diff line change 22date.timezone = UTC
33display_errors = Off
44expose_php = Off
5+ log_errors = On
6+ error_log = /proc/self/fd/2
57memory_limit = 512M
68post_max_size = 150M
79session.auto_start = Off
Original file line number Diff line number Diff line change 22process_name=%(program_name)s_%(process_num)02d
33command=/usr/local/bin/php /app/yii queue/listen --verbose=1 --color=0
44autorestart=true
5- autostart=true
6- numprocs=4
5+ # Enable only after installing yiisoft/yii2-queue; flipped on via image build or entrypoint.
6+ autostart=false
7+ # Keep demo light; can be raised later.
8+ numprocs=1
9+ stopasgroup=true
10+ killasgroup=true
11+ stopsignal=TERM
712stderr_logfile=/dev/stderr
813stderr_logfile_maxbytes=0
914stdout_logfile=/dev/stdout
You can’t perform that action at this time.
0 commit comments