Changes

From SME Server
Jump to navigationJump to search
How to push an install of Thunderbird out to clients.
== Overview ==
This push install of Thunderbird is not unique to SME but it is very useful in the SME environment.
This method uses the netlogon.bat file too automatically:
*Check to see if a local install of Thunderbird is the same as the server install. If not it will copy over the server install.
*Check to see if a local user Thunderbird profile exists. If not it will copy over a default, pre-configured profile.
*The installed application is run locally.

Notes:
*This method manually modifies the Thunderbird configuration files and may break the Thunderbird application. There are no guarantees.
*This has been used in production and tested on Windows XP Professional only.
*This requires downloading executable files from the MS Windows XP Resource Kit.

== Instructions ==
*Install Thunderbird:
**Log into a client computer as “admin”.
**Download and install Thunderbird to a local folder that is writable by all users. This example uses “c:\Applications\Thunderbird”
**Start Thunderbird and configure it using the “admin” email account (Using IMAPS or POPS, SMTPS and the full external SME server name is recommended so this configuration will work outside the network). Do not subscribe to IMAP folders or save your password at this time.
**Install and configure any Thunderbird Extensions. Note: This method will replace any instance of "admin" with the user's login. Do not use any other name than "admin" in settings where you want the user's information to appear. For example in Thunderbird the user's name should be "admin" and not "SME Administrator". User's can change these configurations later if desired.
**Configure any shared address books and calendars (using https addresses to keep the user’s credentials secure).
*Setup SME server:
**Create and ibay with Write access “admin” and read access “everyone”.
**Applications:
***Copy the local install folder (“c:\Applications”) of to this new share (“\\<server>\<share>\Applications”).
**Installs:
***Create a “Installs” folder on the server share (“\\<server>\<share>\Installs”).
***Create a folder for your desktop shortcuts (“\\<server>\<share>\Installs\Desktop Shortcuts”).
***Copy the Thunderbird Desktop Shortcut to the server shortcuts folder.
***Copy “C:\Documents and Settings\admin\Application Data\Thunderbird” to this new folder. There will now be a folder “\\<server>\<share>\Installs\Thunderbird”. Note: the “Application Data” folder is a hidden folder.
***Uninstall Thunderbird from the client computer.
**Utilities:
***Create a “Utilities” folder on the server share (“\\<server>\<share>\Utilities”).
***Search the internet and download “munge.exe” (part of the MS Windows XP Resource Kit) and place it in your “Utilities” folder.
*Create an Install Thunderbird batch file:
**Create a batch file in the “Utilites” folder (“\\<server>\<share>\Utilities\Thunderbird_Install.bat”).
**Edit this file with notepad and add the following:

title DO NOT CLOSE THIS WINDOW! - Installing Thunderbird

echo.
echo.
set SOURCE=\\<server>\<share>
set AppsLocal=c:\Applications
set AppsRemote=%SOURCE%\Applications
if not exist "%AppsLocal%" md "%AppsLocal%"

echo. Copy Links to Desktop
xcopy "%SOURCE%\Installations\Desktop Files\*" "%userprofile%\Desktop\" /v /c /i /h /r /y /z
echo. End Copy Links to Desktop

echo.
echo. Begin Thunderbird install
set ThunderbirdLocal=%AppsLocal%\Thunderbird
set ThunderbirdRemote=%AppsRemote%\Thunderbird
set ThunderbirdLocalVersion=1
set ThunderbirdRemoteVersion=1
for /F "usebackq tokens=1,2 delims=:" %%A in ("%ThunderbirdLocal%\install.log") do (
if /i "%%A"==" App Version" (
set ThunderbirdLocalVersion=%%B
goto :TBLDone
)
)
:TBLDone
for /F "usebackq tokens=1,2 delims=:" %%A in ("%ThunderbirdRemote%\install.log") do (
if /i "%%A"==" App Version" (
set ThunderbirdRemoteVersion=%%B
goto :TBRDone
)
)
:TBRDone
if not %ThunderbirdLocalVersion%==%ThunderbirdRemoteVersion% (
If exist "%ThunderbirdLocal%" rd /s /q "%ThunderbirdLocal%"
xcopy "%ThunderbirdRemote%" "%ThunderbirdLocal%" /e /c /i /y
)
echo. End Thunderbird install
echo.
echo.
echo. Begin Thunderbird profile install or update

rem TBInstallFlag is used force an update of a profile.
rem If a new profile is copied over from the server the user’s customizations and personal contacts and calendar will be removed.
rem To force a global update just change the value of the this variable.

set TBInstalFlag=2009-05-03.txt
if not exist "%USERPROFILE%\Application Data\Thunderbird\%TBInstalFlag%" (

rem The next line moves an existing profile to the user’s desktop to be deleted manually later.

if exist "%USERPROFILE%\Application Data\Thunderbird" move /y "%USERPROFILE%\Application Data\Thunderbird" "%USERPROFILE%\Desktop\Old Thunderbird Settings - You Can Delete"
xcopy "%SOURCE%\Installations\Thunderbird" "%USERPROFILE%\Application Data\Thunderbird" /e /c /i /y
echo."admin" "%username%">"%USERPROFILE%\Application Data\Thunderbird\ReplaceName.txt"

rem The next two lines update the Thunderbird profile and replace “admin” with the user’s login.
rem You must enter the profile name that Thunderbird created for <your profile name>

"%SOURCE%\Utilities\Munge.exe" "%USERPROFILE%\Application Data\Thunderbird\ReplaceName.txt" -l "%USERPROFILE%\Application Data\Thunderbird\Profiles\<your profile name>\prefs.js"
"%SOURCE%\Utilities\Munge.exe" "%USERPROFILE%\Application Data\Thunderbird\ReplaceName.txt" -l "%USERPROFILE%\Application Data\Thunderbird\Profiles\<your profile name>\extensions.ini"
move /y "%USERPROFILE%\Application Data\Thunderbird\ReplaceName.txt" "%USERPROFILE%\Application Data\Thunderbird\%TBInstalFlag%"
)
echo. End Thunderbird profile install or update
echo.

*Modify the netlogin.bat file on the SME server to call the Thunderbird install batch file just created and redirect the output to a log file either locally or on the server.
call "\\<server>\<share>\Utilities\Thunderbird_Install.bat" >"c:\Applications\Thunderbird_Install-%username%.log" 2>&1

--[[User:Kevinb|Kevinb]] 06:18, 4 June 2009 (UTC)
[[Category:Howto]]
6

edits

Navigation menu