Sheriff is a tool for easy and secure guest registration during the coronavirus pandemic.
- Verification of EU Health Certificates
You can set which certificates you want to allow for each facility individually - Asymmetric encryption after data validation
The personal data is stored encrypted with a public key. The private key is not stored on the server and has to be entered when decryption is requested. - Progressive Web App: No app download or dedicated QR scanner app required
Users don't need to download an app or have a dedicated QR scanner installed. The web app takes care of this and runs in all recent versions of major mobile browsers. - Cross registration with other organisations
Users can use the registration website of one single organisation for other organisations as well, so they don't have to enter their data for each one. This needs to be enabled explicitly for each 3rd party organisation. - Automatic data deletion after 21 days
- Easy administration interface suitable for organisations with many locations
- Docker
- Docker Compose
- public IP
- (sub)domain pointing to that IP
- Create a directory named
sheriffsomewhere on your server. We will use/srv/sheriffin this guide. - Copy
docker-compose.prod.ymlto/srv/sheriff/docker-compose.yml - Copy
.env.exampleto/srv/sheriff/.env - Edit
/srv/sheriff/.env:- Set
APP_KEYto a random 32-char string (pwgen -s 32 1) - Set
SHERIFF_HOSTto the domain you want to use for Sheriff (e.g.checkin.example.com) - Set
LETSENCRYPT_EMAILto your email address. This is used for generating a Let's Encrypt HTTPS certificate - Set
DB_PASSWORDto a random string (pwgen -s 32 1) - (optional) Set
SHERIFF_EXTERNAL_ORIGINSto a comma separated list of domains of 3rd party organisations you want to enable cross registration with. Note that you need to enable this on both instances for the other respectively.
- Set
- Run
docker-compose up -dto start the stack in background. Make sure your working directory is/srv/sheriff. - View the logs with
docker-compose logs -f. - Visit your domain and verify you can access the site. It may take a while to generate the certificate.
- Run
docker-compose exec app php artisan user:createand create a user with all permissions. - Run
docker-compose exec app php artisan keypair:generateand follow the steps to generate a key pair.
IMPORTANT: Store the private key in multiple, physically separate safe locations (e.g. a text file on a USB flash drive). DO NOT store it on the server. You will NOT see it again after running the above command. You NEED this key to decrypt all saved data. - Run
docker-compose exec app php artisan keypair:generate --signto generate a signing keypair. You don't need to save that one. You can generate new ones at any time. - Run
docker-compose exec app php artisan trust-anchors:fetchto fetch the latest list of trust anchors for EU Health Certificate verification. The application will check for new certificates every three hours. - Visit
<your domain>/admin, log in and create a new location - Generate a QR code for the new location and try to register with your phone
- Run
docker-compose exec app php artisan visits:export, enter the key and verify that the data you just submitted with your phone is correctly exported.
If everything works as expected, you can start customizing your instance. Remember to modify the privacy policy accordingly!
You can customize the user interface of your Sheriff instance using environment variables and mounted files. Using ConfigMaps in Kubernetes is also possible.
To customize the theme color and/or logo you can set the following environment variables in your .env file:
SHERIFF_THEME_COLOR=#2342de
SHERIFF_LOGO_URL=https://example.com/my-logo.svgApply the new Docker Compose config by running docker-compose up -d.
- Create a new file
strings.yml - Insert your custom strings into that file. Take a look at the bundled
strings.ymlfor reference. You do not need to supply all strings in your custom file as it will be merged with the bundled one. - Mount your
strings.ymlto/app/strings.yml. In yourdocker-compose.yml, add a volume like this for theappservice:volumes: - ./strings.yml:/app/strings.yml:ro - Apply the new Docker Compose config by running
docker-compose up -d.
Future changes to your strings.yml should be online immediately though you might have to clear your browser cache.
