diff --git a/tasks/main.yml b/tasks/main.yml
index f88cc293bd6d033641dbdb49a1b7e49b39a2e2e5..dc6b6934a4f32d2ec65f483e49a141897b445515 100644
--- a/tasks/main.yml
+++ b/tasks/main.yml
@@ -51,9 +51,12 @@
 
 # Set correct variables in configuration files
 # TODO : replace by writing on nextcloud volume configuration file and restart nextcloud
-- name: set trusted domain
+- name: set trusted domain 1
   command: docker exec -u www-data nextcloud php occ --no-warnings "config:system:set" trusted_domains 1 --value="{{ cloud_url }}"
 
+- name: set trusted domain 2
+  command: docker exec -u www-data nextcloud php occ --no-warnings "config:system:set" trusted_domains 1 --value="nextcloud"
+
 - name: overwrite protocol
   command: docker exec -u www-data nextcloud php occ --no-warnings "config:system:set" overwriteprotocol --value="https"