Tuto : comment installer WPKG (serveur – client)
- Samedi 24 janvier 2009
- Ecrire commentaire
Une solution de télé déploiement assez sympa pour les possesseurs de serveur Linux avec des clients Windows
Pré requis : Un serveur Linux avec apt://LAMP + apt://Samba, un client Windows
Installation du client :
Télécharger la dernière version stable depuis l’adresse : http://wpkg.org/Download
WPKG Client 1.2.1.msi
Paramétrage
Rubrique WPKG source
Dans le champ WPKG file path (required), indiquer où se trouve le script wpkg.js.
ex : \serveurpartagewpkg.js
Dans le champ WPKG parameters, mettre les options qui vous conviennent. Par défaut :
/synchronize /nonotify /quiet
Dans le champs WPKG path user, renseigner l’utilisateur ayant les droits de lecture sur le répertoire partagé, ex :
user
Dans le champs WPKG path password, renseigner le mot de passe de votre utilisateur, ex :
mot de passe
Rubrique WPKG execution context
Dans le champs user, mettre le compte avec lequel sera installer les applications, ex :
sytem
Dans le champs password, laisser vide pour le compte system
Installation du serveur :
Télécharger la dernière version stable depuis l’adresse : http://wpkg.org/Download
wget http://wpkg.org/files/stable/WPKG-1.0.2.zip
Déziper le contenu :
unzip WPKG-1.0.2.zip
Paramétrage du serveur SAMBA
Maintenant, sur le serveur où vous voulez installer WPKG, créez un répertoire nommé /wpkg.
mkdir /wpkg
Editer votre fichier de configuration pour Samba
vi /etc/samba.smb.conf
Samba avec security = share :
[wpkg]
comment = Windows Packager
path = /wpkg
read only = yes
browseable = no
valid users = guest, nobody # Note permettre à tout le monde de se connecter
guest ok = yes
Samba avec security = user :
[wpkg]
comment = Windows Packager
path = /wpkg
read only = yes
browseable = no
Redémarrer votre serveur Samba :
/etc/init.d/samba restart
Paramétrage du service WPKG
Depuis le répertoire où vous avez dézippé les sources, copier ces quatre fichiers dans le répertoire partagé /wpkg :
- wpkg.js
- hosts.xml
- profiles.xml
- packages.xml
cp wpkg.js hosts.xml profiles.xml packages.xml /wpkg/
cd /wpkg
Maintenant, éditer le premier fichier hosts.xml pour ajouter un ordinateur afin d’effectuer les premiers tests.
Entre les balises [code lang="xml"] et [/code] remplacer la variable yourcomputer dans host name= par le nom réseau de votre poste de travail :
[code lang="xml"]
[/code]
Ok, maintenant que nous avons attribué notre ordinateur à un profil, il faut créer le profil, puis lui ajouter un paquet, éditer maintenant le fichier profiles.xml
[code lang="xml"]
[/code]
Donc maintenant nous avons un hôte liée à un profil. Et le profil contient un paquet appelé « dia ».
Maintenant, nous devons créer notre package, donc nous allons éditer le fichier packages.xml. Le fichier packages.xml contient un tas d’exemples, alors éditer le pour obtenir ceci :
[code lang="xml"]
[/code]
Je vous conseille de ne laisser que la ligne correspondante à l’installation, ainsi vous n’obtiendrez pas d’erreur sur les tests de vérification pour checker la version ou la desinstallation.
[code lang="xml"]
[/code]
Le plus facile est derrière nous
Installation du client WPKG
Commande pour tester la synchronisation :
cscript \serverwpkgwpkg.js /synchronize /debug
Télécharger le dernier client stable à cette adresse : http://www1.wpkg.org/files/client/stable/ et installer le.
Next Part to translate…
[code lang="java"]
I got this install definition from http://wpkg.org/Dia there is also a larger list of installers here: http://wpkg.org/Category:Silent_Installers
Download a copy of Dia from http://dia-installer.de/index_en.html
(dia-setup-0.96.1-8.exe)
Create a folder inside your WPKG share named graphics and copy the dia-setup-0.96.1-8.exe into it.
Edit the settings of the package so that the install cmd= and upgrade cmd path is the direct path to where you copied the files.
That finishes our Server Install.
Client Install
Download the stable WPKG Client from http://wpkg.org/Download
Should be something like WPKG Client 1.2.1 (Not development release)
On your machine run the WPKG Client 1.2.1.msi (we will use it to create a config file to be pushed out to all the other machines)
You need to create a domain user with low user rights or use any old generic one if you have one. Basically this user needs to be able to read from the WPKG share.
So the first parameter you need to set is the remote path to your WPKG share. (Where wpkg.js resides)
This will be something like \yourserverWPKGwpkg.js
You could also use the IP address which would look like \172.168.10.1WPKGwpkg.js (I recommend using the IP address and making sure your server has a hard coded static IP address)
Ok, leave the WPKG parameters as they are (/synchronize /nonotify /quiet)
For the WPKG path user:
NOTE: you have to add WORKSTATION, WORKGROUP or DOMAIN before the username):
192.168.1.1username
DOMAINuser
For the WPKG path password: the password for this user account.
For the WPKG execution context, leave the User as SYSTEM and the password blank. This is the user that will be installing your packages.
Now hit the Test settings to verify your settings. If you run into trouble, double check all of your paths. If you run into the infamous “Multiple connections to a server or shared resource by the same user” error, then try referring to the server by a different name. For example use the ip address, or a full DNS name i.e. yourserver.yourdomain
You should not receive any [FAILED] results. When your settings are as you like them, press the export settings button to save them for later use. Now press Save. This will install the WPKG Service
Ok, let’s test to see if everything is working. We have our host defined, a profile assigned to a host, and packages as part of a profile. So, when we start the WPKG Service it should go and find our computer name, match it to the Test profile, and install the Dia package.
The quickest way to test is to go to start, run, type services.msc and then press ok. Scroll down to the very bottom and click on WPKG Service, and the start button. If everything is working as it should within a few moments you should see the Dia shortcut appear on your desktop.
Now you should install the WPKG client on all of your workstations using the settings.xml file.
One way is Push Install WPKG with Psexec
--Mellerbeck 23:12, 19 December 2008 (CET)
[/code]