Deployment
Requirements
- Ubuntu 22.04 / 24.04 (or any Linux), Apache 2.4 with
mod_rewriteor nginx - PHP 8.1 or newer with
pdo_mysql,mbstring,gd,curl,openssl,json,fileinfo - MariaDB 10.6+ / MySQL 8
- HTTPS (Let's Encrypt)
Files and permissions
Upload the contents of public_html/ into the document root of the domain. Then run the included script as root:
sudo bash /var/www/allgameclub.com/public_html/dateirechte.sh
It sets owner planet24, group www-data, 755/644 for code, group-writable storage/ and a read-only config/. Pass OWNER= / GROUP= to override.
Apache
The shipped .htaccess does everything: HTTPS redirect, Authorization header pass-through, routing to index.php, protection of app/, config/, storage/, games/ and friends. Make sure AllowOverride All is set for the document root and mod_rewrite, mod_headers, mod_deflate are enabled.
nginx
server {
listen 443 ssl http2;
server_name allgameclub.com;
root /var/www/allgameclub.com/public_html;
index index.php;
location ~ ^/(app|config|database|storage|docs|bin|cron|games)/ { return 404; }
location ~ /\. { deny all; }
location ~* \.(md|sql|log|lock|env|ini)$ { deny all; }
location /public/ { expires 1y; add_header Cache-Control "public, immutable"; try_files $uri =404; }
location /sdk/ { expires 1h; try_files $uri =404; }
location / { try_files $uri /index.php?$query_string; }
location ~ ^/index\.php(/|$) {
include fastcgi_params;
fastcgi_pass unix:/run/php/php8.3-fpm.sock;
fastcgi_param SCRIPT_FILENAME $document_root/index.php;
fastcgi_param HTTP_AUTHORIZATION $http_authorization;
}
location ~ \.php$ { return 404; }
client_max_body_size 8m;
}
Configuration checklist
app.urlset to the public URL (used in emails and API responses)app.debugfalse in productionapp.trust_proxytrue only behind a load balancer that setsX-Forwarded-*mail.drivermail(sendmail/postfix) orsmtpwith credentials; test withphp bin/console.php mail:test you@example.compayments.gatewaypaypal(live) orstripe.- PayPal: create a REST app under <https://developer.paypal.com/dashboard/applications/live> with the Subscriptions feature, put client id and secret into
payments.paypal, add a webhook with the URLhttps://allgameclub.com/webhooks/paypaland the events Billing subscription (all) plus Payment sale completed / denied / refunded / reversed, and put the webhook id intopayments.paypal.webhook_id(without it events are accepted unverified). Then runphp bin/console.php paypal:plansonce: it creates the catalog product and one billing plan per entry inplansand stores the plan ids in the settings table (paypal:statusshows them). Members manage a PayPal subscription under Account → Membership → Manage in your PayPal account; a cancelled PayPal subscription keeps its paid period but cannot be resumed. - Stripe: secret key, webhook secret and the two Price IDs. Webhook URL:
https://allgameclub.com/webhooks/stripe, events:checkout.session.completed,invoice.paid,invoice.payment_failed,customer.subscription.updated,customer.subscription.deleted - Trial codes (
/admin/codes) need no payment provider: a code grants a plan for free for N days (providerpromo, €0 order); the cron mails members whose trial ended and the site shows them a "continue with Unlimited?" prompt for 30 days. app.companyfor the imprint, terms and emails
Sign in with Google / Facebook
- Google: create an OAuth client (type "Web application") in the Google Cloud console, add
https://allgameclub.com/auth/google/callbackas authorised redirect URI, and put the client id and secret intosocial_login.googleinconfig/config.php. - Facebook: create an app with "Facebook Login", add
https://allgameclub.com/auth/facebook/callbackas a valid OAuth redirect URI, request theemailpermission, and put the app id and secret intosocial_login.facebook.
The buttons appear on the login and registration pages as soon as a provider is configured. Existing members can link providers under Account → Security → Linked accounts. Accounts created via a provider get a verified email and a random unusable password (they can set one through "Forgot password"). If the provider does not vouch for the address, the member gets the normal confirmation mail and, like every new sign-up, cannot start a game before clicking it (auth.require_verified_to_play, on by default; /verify-email explains the step and offers a resend).
Cron
*/15 * * * * php /var/www/allgameclub.com/public_html/bin/console.php cron >> /var/www/allgameclub.com/public_html/storage/logs/cron.log 2>&1
Updating
- Upload changed files (keep
config/config.phpandstorage/). php bin/console.php migrateapplies new files fromdatabase/migrations/.php bin/console.php games:sync.
Backups
Back up the database (all tables) and storage/uploads/. Everything else is code.
Logs
storage/logs/app.logapplication errors and warningsstorage/logs/php-error.logPHP errorsstorage/logs/mail.logemails whenmail.driver = logstorage/logs/cron.logif you redirect cron output there
Last updated October 21, 2026.