Using rclone via environment variables

What is the problem you are having with rclone?

I can't seem to get rclone working when using it with environment-variable config only. It does not seem to authorize properly. I'm using this config:

export RCLONE_CONFIG_DAVINT_TYPE="webdav"
export RCLONE_CONFIG_DAVINT_URL="https://webdav-int.cluster.somewhere.org/mydir"
export RCLONE_CONFIG_DAVINT_VENDOR="other"
export RCLONE_CONFIG_DAVINT_USER="myuser"
export RCLONE_CONFIG_DAVINT_PASSWORD="somepassword"

The same config from a configuration file works fine. I tried both with plaintext password and with the encrypted password string from the config file.

What is your rclone version (output from rclone version)

rclone v1.45
- os/arch: linux/amd64
- go version: go1.11.6

Which OS you are using and how many bits (eg Windows 7, 64 bit)

Linux/64

Which cloud storage system are you using? (eg Google Drive)

WebDAV

The command you were trying to run (eg rclone copy /tmp remote:tmp)

rclone ls DAVINT:

A log from the command with the -vv flag (eg output from rclone -vv copy /tmp remote:tmp)

2019/11/03 07:17:28 DEBUG : rclone: Version "v1.45" starting with parameters ["rclone" "-vv" "ls" "DAVINT:"]
2019/11/03 07:17:28 DEBUG : Using config file from "/root/.config/rclone/rclone.conf"
2019/11/03 07:17:29 ERROR : : error listing: couldn't list files: 401 Unauthorized
2019/11/03 07:17:29 Failed to ls: couldn't list files: 401 Unauthorized

1.45 is pretty old. Do you want to validate the same issue happens with the latest?

welcome to the forum.
this could be a simple typo or misspelling,

  1. double check the information,
  2. cut and paste directly from rclone config dump.

This is probably the problem...

The password needs to be run through rclone osbscure first, so

export RCLONE_CONFIG_DAVINT_PASSWORD=`rclone obscure "somepassword"`

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.