| Working with Watchfolders | |
Watchfolder services must be run under a user with access to every area of your file system in which you intend to create a watch folder. Watchfolders allows you to run multiple instances of these services under different users. Most users run these services under one user. Choose a user that has access to your entire file system.
If you need to run multiple instances of these services to access every area of your file system, see Choosing User Accounts to Run Watchfolder Services.
Set the user's docroot by running the following command:
> asconfigurator -x "set_user_data;user_name,username;absolute,docroot"
For example:
> asconfigurator -x "set_user_data;user_name,svcAspera;absolute,C:\\" success user_name: svcAspera
The following commands add the services in the asperarund database; asperarund automatically starts and preserves services in its database. The asperarund service must be running.
Windows Node:
> asperawatchd --user username > asperawatchfolderd --user username
Windows requires a password when running services as other users. Enter the password when prompted.
OS X Node:
$ /Library/Aspera/sbin/asperawatchd --user username $ /Library/Aspera/sbin/asperawatchfolderd --user username
Linux Node:
# /opt/aspera/sbin/asperawatchd --user username # /opt/aspera/sbin/asperawatchfolderd --user username
Use the aswatchadmin and aswatchfolderadmin admin tools to retrieve a list of running daemons. Daemons are named with the username you passed in when starting the service. For example, if you used the svcAspera user to run your services, you should see the svcaspera daemon listed in the output.
Windows Node:
> aswatchadmin query-daemons [aswatchadmin query-daemons] Found a single daemon: svcaspera > aswatchfolderadmin query-daemons [aswatchfolderadmin query-daemons] Found a single daemon: svcaspera
Windows requires a password when running services as other users. Enter the password when prompted.
Linux Node:
$ /opt/aspera/bin/aswatchadmin query-daemons [aswatchadmin query-daemons] Found a single daemon: root $ /opt/aspera/bin/aswatchfolderadmin query-daemons [aswatchfolderadmin query-daemons] Found a single daemon: root
Windows Node:
> asnodeadmin -a -u node_username -p node_password -x admin_user --acl-set "admin,impersonation"
Linux Node:
# /opt/aspera/binasnodeadmin-a -u node_username -p node_password -x admin_user --acl-set "admin,impersonation"
For example:
Windows Node:
> asnodeadmin -a -u watchfolder_user -p X245lskd3 -x svcaspera --acl-set "admin,impersonation"
Linux Node:
# /opt/aspera/bin/asnodeadmin -a -u watchfolder_user -p X245lskd3 -x svcaspera --acl-set "admin,impersonation"
> asnodeadmin -l
List of node user(s):
user system/transfer user acls
==================== ======================= ====================
node_api_user system_user [admin]
Given
the example in the previous step, the output should look like the
following:> asnodeadmin -l user system/transfer user acls ==================== ======================= ==================== watchfolder_user svcAspera [admin,impersonation]