Updates
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
{
|
||||
"aio_services_v1": [
|
||||
{
|
||||
"container_name": "nextcloud-aio-facerecognition",
|
||||
"display_name": "Computing container for facerecognition",
|
||||
"documentation": "https://github.com/nextcloud/all-in-one/tree/main/community-containers/facerecognition",
|
||||
"image": "matiasdelellis/facerecognition-external-model",
|
||||
"image_tag": "v1",
|
||||
"internal_port": "5000",
|
||||
"restart": "unless-stopped",
|
||||
"environment": [
|
||||
"TZ=%TIMEZONE%",
|
||||
"API_KEY=%FACERECOGNITION_API_KEY%",
|
||||
"FACE_MODEL=3"
|
||||
],
|
||||
"aio_variables": [
|
||||
"nextcloud_memory_limit=2048M"
|
||||
],
|
||||
"secrets": [
|
||||
"FACERECOGNITION_API_KEY"
|
||||
],
|
||||
"enable_nvidia_gpu": false,
|
||||
"nextcloud_exec_commands": [
|
||||
"php /var/www/html/occ app:install facerecognition",
|
||||
"php /var/www/html/occ app:enable facerecognition",
|
||||
"php /var/www/html/occ config:system:set facerecognition.external_model_url --value nextcloud-aio-facerecognition:5000",
|
||||
"php /var/www/html/occ config:system:set facerecognition.external_model_api_key --value %FACERECOGNITION_API_KEY%",
|
||||
"php /var/www/html/occ face:setup -m 5",
|
||||
"php /var/www/html/occ face:setup -M 1G",
|
||||
"php /var/www/html/occ config:app:set facerecognition analysis_image_area --value 4320000",
|
||||
"php /var/www/html/occ config:system:set enabledFaceRecognitionMimetype 0 --value image/jpeg",
|
||||
"php /var/www/html/occ config:system:set enabledFaceRecognitionMimetype 1 --value image/png",
|
||||
"php /var/www/html/occ config:system:set enabledFaceRecognitionMimetype 2 --value image/heic",
|
||||
"php /var/www/html/occ config:system:set enabledFaceRecognitionMimetype 3 --value image/tiff",
|
||||
"php /var/www/html/occ config:system:set enabledFaceRecognitionMimetype 4 --value image/webp",
|
||||
"php /var/www/html/occ face:background_job --defer-clustering &"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
34
nextcloud-aio/community-containers/facerecognition/readme.md
Normal file
34
nextcloud-aio/community-containers/facerecognition/readme.md
Normal file
@@ -0,0 +1,34 @@
|
||||
## Facerecognition
|
||||
This container bundles the external model of facerecognition and auto-configures it for you.
|
||||
|
||||
### Notes
|
||||
- This container needs imaginary in order to analyze modern file format images. Make sure to enable imaginary in the AIO interface before adding this container.
|
||||
- The image analysis is currently set to fixed value of `1G`. See [this](https://github.com/search?q=repo%3Anextcloud%2Fall-in-one+1G+path%3A%2F%5Ecommunity-containers%5C%2Ffacerecognition%5C%2F%2F&type=code)
|
||||
- Facerecognition is by default disabled for all users. If you want to enable facerecognition for all users, you can run the following commands before adding this container:<br>
|
||||
**Please note:** If you do not have CLI access to the server, you can now run docker commands via a web session by using this community container: https://github.com/nextcloud/all-in-one/tree/main/community-containers/container-management. This script below can be run from inside the container-management container via `bash /facerecognition.sh`.
|
||||
```bash
|
||||
# Go into the container
|
||||
sudo docker exec --user www-data -it nextcloud-aio-nextcloud bash
|
||||
```
|
||||
Now inside the container:
|
||||
```bash
|
||||
NC_USERS_NEW=$(php occ user:list | sed 's|^ - ||g' | sed 's|:.*||')
|
||||
mapfile -t NC_USERS_NEW <<< "$NC_USERS_NEW"
|
||||
for user in "${NC_USERS_NEW[@]}"
|
||||
do
|
||||
php occ user:setting "$user" facerecognition full_image_scan_done false
|
||||
php occ user:setting "$user" facerecognition enabled true
|
||||
done
|
||||
|
||||
# Exit the container shell
|
||||
exit
|
||||
```
|
||||
- If facerecognition shall analyze shared files & folders (`sudo docker exec --user www-data -it nextcloud-aio-nextcloud php occ config:app:set facerecognition handle_shared_files --value true`), groupfolders (`sudo docker exec --user www-data -it nextcloud-aio-nextcloud php occ config:app:set facerecognition handle_group_files --value true`) and/or external storages (`sudo docker exec --user www-data -it nextcloud-aio-nextcloud php occ config:app:set facerecognition handle_external_files --value true`) in Nextcloud, you need to enable support for it manually first by running the mentioned commands before adding this container. See https://github.com/matiasdelellis/facerecognition/wiki/Settings#hidden-settings for further notes on each of these settings.<br>
|
||||
**Please note:** If you do not have CLI access to the server, you can now run docker commands via a web session by using this community container: https://github.com/nextcloud/all-in-one/tree/main/community-containers/container-management
|
||||
- See https://github.com/nextcloud/all-in-one/tree/main/community-containers#community-containers how to add it to the AIO stack
|
||||
|
||||
### Repository
|
||||
https://github.com/matiasdelellis/facerecognition-external-model
|
||||
|
||||
### Maintainer
|
||||
https://github.com/matiasdelellis
|
||||
Reference in New Issue
Block a user