diff options
author | Renato Botelho <renato@netgate.com> | 2017-01-02 12:54:26 -0200 |
---|---|---|
committer | Renato Botelho <renato@netgate.com> | 2017-01-02 12:58:41 -0200 |
commit | 3705d2637e127238aaa015e7763e3245fea62ec3 (patch) | |
tree | 85b2d331bbd693e0a482adb22fd012eab9ea2d74 /src/etc/skel | |
parent | 1494b4fa1582ea7a58f66dc8df7d29e1814a52bc (diff) | |
download | pfsense-3705d2637e127238aaa015e7763e3245fea62ec3.zip pfsense-3705d2637e127238aaa015e7763e3245fea62ec3.tar.gz |
Ticket #6096: Add PKG_DBDIR and PKG_CACHEDIR to user environment
Diffstat (limited to 'src/etc/skel')
-rw-r--r-- | src/etc/skel/dot.shrc | 6 | ||||
-rw-r--r-- | src/etc/skel/dot.tcshrc | 6 |
2 files changed, 12 insertions, 0 deletions
diff --git a/src/etc/skel/dot.shrc b/src/etc/skel/dot.shrc index 3854b0b..a16dd70 100644 --- a/src/etc/skel/dot.shrc +++ b/src/etc/skel/dot.shrc @@ -58,6 +58,12 @@ if [ "${HTTP_PROXY}" != "" ]; then export HTTP_PROXY fi +USE_MFS_TMPVAR=$(/usr/local/sbin/read_xml_tag.sh boolean system/use_mfs_tmpvar) +if [ "${USE_MFS_TMPVAR}" = "true" ]; then + export PKG_DBDIR='/root/var/db/pkg' + export PKG_CACHEDIR='/root/var/cache/pkg' +fi + # Detect interactive logins and display the shell if [ -n "${SSH_TTY}" -o "${TERM}" = "cons25" ]; then /etc/rc.initial diff --git a/src/etc/skel/dot.tcshrc b/src/etc/skel/dot.tcshrc index c4f2867..46e6c0b 100644 --- a/src/etc/skel/dot.tcshrc +++ b/src/etc/skel/dot.tcshrc @@ -79,3 +79,9 @@ if (${http_proxy} != "") then endif setenv HTTP_PROXY ${http_proxy} endif + +set use_mfs_tmpvar=`/usr/local/sbin/read_xml_tag.sh boolean system/use_mfs_tmpvar` +if ( $use_mfs_tmpvar == "true" ) then + setenv PKG_DBDIR '/root/var/db/pkg' + setenv PKG_CACHEDIR '/root/var/cache/pkg' +endif |