diff options
author | Daniil Baturin <daniil@baturin.org> | 2013-11-02 02:34:11 +0100 |
---|---|---|
committer | Daniil Baturin <daniil@baturin.org> | 2013-11-02 02:34:11 +0100 |
commit | 341fc313c73737399dd7ac186adfac787580bf2a (patch) | |
tree | a93998c9587ca8f25c66fe4ade2a175a31a387b0 | |
parent | 5b2cff2ebaf20b9757b18901f263997bbb43f31d (diff) | |
download | vyatta-cfg-system-341fc313c73737399dd7ac186adfac787580bf2a.tar.gz vyatta-cfg-system-341fc313c73737399dd7ac186adfac787580bf2a.zip |
Set User-Agent: to VyOS/$version for statistics collection.
-rwxr-xr-x | scripts/install/install-image | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/scripts/install/install-image b/scripts/install/install-image index d89a0c54..aa423f73 100755 --- a/scripts/install/install-image +++ b/scripts/install/install-image @@ -62,12 +62,12 @@ fetch_iso_by_url () auth="" fi - client_hdr="-HVyatta-Client: install-image" - vyatta_version=`dpkg-query --showformat='${Version}' --show vyatta-version` - vers_hdr="-HVyatta-Version: $vyatta_version" + # This is for statistics collection + vyos_version=`dpkg-query --showformat='${Version}' --show vyatta-version` + user_agent="-H \"User-Agent: VyOS/$vyos_version\"" filename="${TEMP_DIR}/${NEW_ISO##*/}" - curl "$client_hdr" "$vers_hdr" $auth -f -o $filename $NEW_ISO + curl $user_agent $auth -f -o $filename $NEW_ISO curlerror=$? if [ $curlerror -eq 51 ]; then host=${NEW_ISO##scp://} |