This repository contains the code responsible for https://plugins.cakephp.org
The public package listing has query validation and an IP-based rate limit. It
uses Dokku's REDIS_URL by default. RATE_LIMIT_CACHE_URL can override it if
you later want a dedicated Redis database or service.
The container includes the PHP Redis extension. TRUSTED_PROXY_IPS must list
only proxies that overwrite X-Forwarded-For; for the current Dokku setup its
default is 172.17.0.1. Set RATE_LIMIT_ENABLED=false only for temporary
maintenance or local development. The defaults are 90 listing views/minute,
15 filtered listings/minute, and 30 autocomplete requests/minute per client IP.
You need DDEV installed and configured on your machine.
After that start the app via ddev start
Next you need to apply migrations to create the database tables:
ddev exec bin/cake migrations migrate
ddev exec bin/cake migrations migrate -p Tags
ddev exec bin/cake migrations migrate -p ADmad/SocialAuthAfter that you can perform a fresh sync via
ddev exec bin/cake sync_packagesWhile that is running (takes quite a while) you should install node modules and start the dev server via
ddev exec npm i
ddev exec bin/cake devserverWith that you should now see what is currently on the production site.
If you want to test/develop social auth via Github you need to set the following 2 environment variables in your config/.env file:
export AUTH_ID_GITHUB="someid"
export AUTH_SECRET_GITHUB="somesecret"
You can get these tokens via creating a Github OAuth App on https://github.com/settings/developers
If you want to clean up package data, you can run the following command:
ddev exec bin/cake cleanIf you want to start with a fresh DB, you can run the following command:
ddev exec -s db mysql -uroot -proot -e "DROP DATABASE IF EXISTS db; CREATE DATABASE db; CREATE DATABASE testdb;"Note
Don't forget to apply migrations again.