- PHP 7.2+
- Composer
- Symfony CLI
If you need to make asset changes:
composer install
npm install
- Add the missing values from
.env
to a.env.local
file- Enable the Cloud Vision API at https://console.cloud.google.com/apis/api/vision.googleapis.com/overview
- Create a new Google service account at https://console.cloud.google.com/iam-admin/serviceaccounts Google gives you 1,000 free lookups per month.
- Give the service account the Compute Engine Service Account role.
- Add a new key for the service account, and download the key's JSON file. Nothing needs to be changed in this file.
- Add the path of that file to your
.env.local
asAPP_GOOGLE_KEYFILE
.
- Install Tesseract and make sure it's in your
$PATH
You can create a free account for Transkribus, and get a small number of free credits.
You will also need to set the username and password of your Transkribus account in .env.local
:
APP_TRANSKRIBUS_USERNAME=username
APP_TRANSKRIBUS_PASSWORD=password
Note: You will require sufficient credits in your account to use the Transkribus API.
symfony serve
to start the applicationnpm run watch
if you need to make JS/CSS changes. Compiled assets are not committed.
The application caches some data.
In development this is done on the filesystem (in the var/cache/dev/pools/
directory),
and in production in Redis
(the Toolforge installation).
To test the Redis configuration locally, open an SSH tunnel to Toolforge's Redis server:
$ ssh -N -L 6379:redis.svc.tools.eqiad1.wikimedia.cloud:6379 login.toolforge.org
And set the following in .env.local
:
APP_ENV=prod
REDIS_HOST=localhost
Then clear the application cache with
$ ./bin/console c:c
(beta: this is a very raw setup and needs improvements)
Setup container
./docker/setup.sh
Run container
./docker/run.sh