Bonjour à tous, j'ai une nouvelle idée de paquet wapt et donc une nouvelle problématique :
Objectif : Lancer un bat qui permet la mise à jour d'un logiciel sur les postes client, pour l'instant les users le lance manuellement si nécessaire. Celui çi, à chaque maj du soft, est générer et stocker par le serveur ainsi que les fichiers à copier via le batch. Pour simplifier les manipulation users (et être sur que les majs clientes soit faites ) , je veux faire un simple paquet qui à a chaque changement de version relance ce bat.
Je voudrait donc créer un paquet qui lance un .bat qui se trouve sur un partage réseau. Ce .bat fait un xcopy de fichiers se trouvant sur un partage smb vers le poste en local.
Problème : Comme le service waptservice tourne en compte system, il n'a pas accès au partage smb. Avez vous une idée pour faire un authentification en python pour arriver à lancer le batch, puis le lancer en "run as" avec un compte qui à les droits sur le partage ( pour que le xcopy est les droits ncessaire) ?
Merci pour vos idées.
Cordialement.
J'ai relue plusieurs fois mais je n'ai pas compris l'objectif.
Quelle est le but final ?
Simon
Le 27/08/2015 12:03, Didier Paulin a écrit :
Bonjour à tous, j'ai une nouvelle idée de paquet wapt et donc une nouvelle problématique :
Objectif : /Lancer un bat qui permet la mise à jour d'un logiciel sur les postes client, pour l'instant les users le lance manuellement si nécessaire. Celui çi, à chaque maj du soft, est générer et stocker par le serveur ainsi que les fichiers à copier via le batch./ /Pour simplifier les manipulation users (et être sur que les majs clientes soit faites ) , je veux faire un simple paquet qui à a chaque changement de version relance ce bat./
Je voudrait donc créer un paquet qui lance un .bat qui se trouve sur un partage réseau. Ce .bat fait un xcopy de fichiers se trouvant sur un partage smb vers le poste en local.
Problème : Comme le service /waptservice/ tourne en compte system, il n'a pas accès au partage smb. Avez vous une idée pour faire un authentification en python pour arriver à lancer le batch, puis le lancer en "run as" avec un compte qui à les droits sur le partage ( pour que le xcopy est les droits ncessaire) ?
Merci pour vos idées.
Cordialement.
WAPT mailing list WAPT@lists.tranquil.it http://lists.tranquil.it/listinfo/wapt
Je crois que je viens de comprendre a force de re-lecture
Je n'ai pas la problematique complete mais le wapt-get session-setup
pourrais être une bonne solution
Simon
Le 27/08/2015 12:09, Fonteneau Simon a écrit :
J'ai relue plusieurs fois mais je n'ai pas compris l'objectif.
Quelle est le but final ?
Simon
Le 27/08/2015 12:03, Didier Paulin a écrit :
Bonjour à tous, j'ai une nouvelle idée de paquet wapt et donc une nouvelle problématique :
Objectif : /Lancer un bat qui permet la mise à jour d'un logiciel sur les postes client, pour l'instant les users le lance manuellement si nécessaire. Celui çi, à chaque maj du soft, est générer et stocker par le serveur ainsi que les fichiers à copier via le batch./ /Pour simplifier les manipulation users (et être sur que les majs clientes soit faites ) , je veux faire un simple paquet qui à a chaque changement de version relance ce bat./
Je voudrait donc créer un paquet qui lance un .bat qui se trouve sur un partage réseau. Ce .bat fait un xcopy de fichiers se trouvant sur un partage smb vers le poste en local.
Problème : Comme le service /waptservice/ tourne en compte system, il n'a pas accès au partage smb. Avez vous une idée pour faire un authentification en python pour arriver à lancer le batch, puis le lancer en "run as" avec un compte qui à les droits sur le partage ( pour que le xcopy est les droits ncessaire) ?
Merci pour vos idées.
Cordialement.
WAPT mailing list WAPT@lists.tranquil.it http://lists.tranquil.it/listinfo/wapt
Bonjour , pour faire plus simple :
J'essaye de lancer un batch qui se trouve sur un partage réseau, un truc du style : run(\monserveur\monpartage\monbat.bat)
Ce bat contient : xcopy \monserveur\monpartage\monfichier.txt c:\test\
Le problème c'est que le paquet est déployé avec le compte "system" du poste local, il ne peux donc lancer un programme stocké sur un partage samba faute de droits. Il faudrait que le le script python lance le bat via un compte ayant les droit sur le partage.
J'ai réussi en faisant une bidouille : Via mon paquet python je lance un exe compilé en autoit qui lui même lance mon bat avec un runas... C'est pas très propre... mais ça fonctionne.
Connaissez vous un solutions pour accéder à un partage via un script python ? l'idée serait de faire un truc du genre :
open.authentification (\monserveur\monpartage, user: toto , pwd : password) run(\monserveur\monpartage\monbat.bat)
Cordialement.
De: "Fonteneau Simon" sfonteneau@stemarie-aizenay.fr À: wapt@lists.tranquil.it Envoyé: Jeudi 27 Août 2015 12:43:14 Objet: <!>Re: [Wapt] Paquet lancement .bat sur un partage smb
Je crois que je viens de comprendre a force de re-lecture
Je n'ai pas la problematique complete mais le wapt-get session-setup
pourrais être une bonne solution
Simon
Le 27/08/2015 12:09, Fonteneau Simon a écrit :
J'ai relue plusieurs fois mais je n'ai pas compris l'objectif.
Quelle est le but final ?
Simon
Le 27/08/2015 12:03, Didier Paulin a écrit :
BQ_BEGIN
Bonjour à tous, j'ai une nouvelle idée de paquet wapt et donc une nouvelle problématique :
Objectif : Lancer un bat qui permet la mise à jour d'un logiciel sur les postes client, pour l'instant les users le lance manuellement si nécessaire. Celui çi, à chaque maj du soft, est générer et stocker par le serveur ainsi que les fichiers à copier via le batch. Pour simplifier les manipulation users (et être sur que les majs clientes soit faites ) , je veux faire un simple paquet qui à a chaque changement de version relance ce bat.
Je voudrait donc créer un paquet qui lance un .bat qui se trouve sur un partage réseau. Ce .bat fait un xcopy de fichiers se trouvant sur un partage smb vers le poste en local.
Problème : Comme le service waptservice tourne en compte system, il n'a pas accès au partage smb. Avez vous une idée pour faire un authentification en python pour arriver à lancer le batch, puis le lancer en "run as" avec un compte qui à les droits sur le partage ( pour que le xcopy est les droits ncessaire) ?
Merci pour vos idées.
Cordialement.
_______________________________________________ WAPT mailing list WAPT@lists.tranquil.it http://lists.tranquil.it/listinfo/wapt
BQ_END
_______________________________________________ WAPT mailing list WAPT@lists.tranquil.it http://lists.tranquil.it/listinfo/wapt
Bonjour
La sécurité serait compromise pusique le mot de passe serait en claire dans le paquet wapt ...
Non par contre le session setup serait un bonne solution puisque effectuée avec la session de l'utilisateur en cour et donc l'accès au partage normalement.
Simon
Le 28/08/2015 12:01, Didier Paulin a écrit :
Bonjour , pour faire plus simple :
J'essaye de lancer un batch qui se trouve sur un partage réseau, un truc du style : /run(\monserveur\monpartage\monbat.bat)/
Ce *bat* contient : /xcopy \monserveur\monpartage\monfichier.txt c:\test/
Le problème c'est que le paquet est déployé avec le compte "system" du poste local, il ne peux donc lancer un programme stocké sur un partage samba faute de droits. Il faudrait que le le script python lance le bat via un compte ayant les droit sur le partage.
J'ai réussi en faisant une bidouille : Via mon paquet python je lance un exe compilé en autoit qui lui même lance mon bat avec un runas... C'est pas très propre... mais ça fonctionne.
Connaissez vous un solutions pour accéder à un partage via un script python ? l'idée serait de faire un truc du genre :
/open.authentification (\monserveur\monpartage, user: toto , pwd : password)/ /run(\monserveur\monpartage\monbat.bat)/
Cordialement.
*De: *"Fonteneau Simon" sfonteneau@stemarie-aizenay.fr *À: *wapt@lists.tranquil.it *Envoyé: *Jeudi 27 Août 2015 12:43:14 *Objet: *<!>Re: [Wapt] Paquet lancement .bat sur un partage smb
Je crois que je viens de comprendre a force de re-lecture
Je n'ai pas la problematique complete mais le wapt-get session-setup
pourrais être une bonne solution
Simon
Le 27/08/2015 12:09, Fonteneau Simon a écrit :
J'ai relue plusieurs fois mais je n'ai pas compris l'objectif. Quelle est le but final ? Simon Le 27/08/2015 12:03, Didier Paulin a écrit : Bonjour à tous, j'ai une nouvelle idée de paquet wapt et donc une nouvelle problématique : Objectif : /Lancer un bat qui permet la mise à jour d'un logiciel sur les postes client, pour l'instant les users le lance manuellement si nécessaire. Celui çi, à chaque maj du soft, est générer et stocker par le serveur ainsi que les fichiers à copier via le batch./ /Pour simplifier les manipulation users (et être sur que les majs clientes soit faites ) , je veux faire un simple paquet qui à a chaque changement de version relance ce bat./ Je voudrait donc créer un paquet qui lance un .bat qui se trouve sur un partage réseau. Ce .bat fait un xcopy de fichiers se trouvant sur un partage smb vers le poste en local. Problème : Comme le service /waptservice/ tourne en compte system, il n'a pas accès au partage smb. Avez vous une idée pour faire un authentification en python pour arriver à lancer le batch, puis le lancer en "run as" avec un compte qui à les droits sur le partage ( pour que le xcopy est les droits ncessaire) ? Merci pour vos idées. Cordialement. _______________________________________________ WAPT mailing list WAPT@lists.tranquil.it http://lists.tranquil.it/listinfo/wapt
WAPT mailing list WAPT@lists.tranquil.it http://lists.tranquil.it/listinfo/wapt
Bonjour,
Pourquoi ne pas contourner le problème :
mettre le fichier /monfichier.txt dans le répertoire de création du paquet et écrire dans le setup.py une commande du type : filecopyto(filename, target)/
En faite pour diverses raisons je suis obligé de laisser le bat sur le serveur.
Effectivement comme le soulevé Simon, mettre le mot de passe en clair dans un script, niveau sécurité ça peux faire bondir... Toutefois, j'utilise un compte limité, privé de tout droits, sauf d’ouvrir ce partage ou rien de confidentiel n'est exposé.
Si j'ai bien compris on peux exécuter en cli avec l'option "session setup" pour utiliser les droits de la session en cours et effectivement ça fonctionne. Mais si j'upgrade mon paquet via la console et que j’attends le déploiement, c'est le compte "system" qui l'exécute... je pense que quelques choses m’échappes.. pouvez vous m'éclairer ?
Cordialement.
De: "LECLERCQ Johann" johann.leclercq@culture.gouv.fr À: wapt@lists.tranquil.it Envoyé: Vendredi 28 Août 2015 13:48:44 Objet: <!>Re: [Wapt] <!>Re: Paquet lancement .bat sur un partage smb
Bonjour,
Pourquoi ne pas contourner le problème :
mettre le fichier monfichier.txt dans le répertoire de création du paquet et écrire dans le setup.py une commande du type : filecopyto(filename, target)
Je n'ai pas essayée mais :
Utiliser ces commandes dans un fichier .bat.
Pour connecter un lecteur réseau, utilisez la commande : net use X: \nom de l'ordinateur\nom du partage où X: est la lettre de lecteur que vous souhaitez affecter à la ressource partagée.
Pour déconnecter un lecteur, utilisez la commande : net use X: /delete où X: est la lettre de lecteur de la ressource partagée.
Avec compte utilisateur automatique : net use X: \nom_ordinateur\nom_partage /USER:username password Attribution de lettre automatique : net use * \nom_ordinateur\nom_partage
Simon
Le 28/08/2015 14:28, Didier Paulin a écrit :
En faite pour diverses raisons je suis obligé de laisser le bat sur le serveur.
Effectivement comme le soulevé Simon, mettre le mot de passe en clair dans un script, niveau sécurité ça peux faire bondir... Toutefois, j'utilise un compte limité, privé de tout droits, sauf d’ouvrir ce partage ou rien de confidentiel n'est exposé.
Si j'ai bien compris on peux exécuter en cli avec l'option "session setup" pour utiliser les droits de la session en cours et effectivement ça fonctionne. Mais si j'upgrade mon paquet via la console et que j’attends le déploiement, c'est le compte "system" qui l'exécute... je pense que quelques choses m’échappes.. pouvez vous m'éclairer ?
Cordialement.
*De: *"LECLERCQ Johann" johann.leclercq@culture.gouv.fr *À: *wapt@lists.tranquil.it *Envoyé: *Vendredi 28 Août 2015 13:48:44 *Objet: *<!>Re: [Wapt] <!>Re: Paquet lancement .bat sur un partage smb
Bonjour,
Pourquoi ne pas contourner le problème :
mettre le fichier /monfichier.txt dans le répertoire de création
du paquet et écrire dans le setup.py une commande du type : filecopyto(filename, target)/ -- Cordialement, LECLERCQ Johann Responsable Informatique et AQSSI de la DRAC Pays de la Loire Ministère de la Culture et de la Communication -- Koan du jour Lorsqu'il n'y a plus rien à faire, que faites-vous ? Le 28/08/2015 12:01, Didier Paulin a écrit :
Bonjour , pour faire plus simple : J'essaye de lancer un batch qui se trouve sur un partage réseau, un truc du style : /run(\\monserveur\monpartage\monbat.bat)/ Ce *bat* contient : /xcopy \\monserveur\monpartage\monfichier.txt c:\test\/ Le problème c'est que le paquet est déployé avec le compte "system" du poste local, il ne peux donc lancer un programme stocké sur un partage samba faute de droits. Il faudrait que le le script python lance le bat via un compte ayant les droit sur le partage. J'ai réussi en faisant une bidouille : Via mon paquet python je lance un exe compilé en autoit qui lui même lance mon bat avec un runas... C'est pas très propre... mais ça fonctionne. Connaissez vous un solutions pour accéder à un partage via un script python ? l'idée serait de faire un truc du genre : /open.authentification (\\monserveur\monpartage\, user: toto , pwd : password)/ /run(\\monserveur\monpartage\monbat.bat)/ Cordialement. ------------------------------------------------------------------------ *De: *"Fonteneau Simon" <sfonteneau@stemarie-aizenay.fr> *À: *wapt@lists.tranquil.it *Envoyé: *Jeudi 27 Août 2015 12:43:14 *Objet: *<!>Re: [Wapt] Paquet lancement .bat sur un partage smb Je crois que je viens de comprendre a force de re-lecture Je n'ai pas la problematique complete mais le wapt-get session-setup pourrais être une bonne solution Simon Le 27/08/2015 12:09, Fonteneau Simon a écrit : J'ai relue plusieurs fois mais je n'ai pas compris l'objectif. Quelle est le but final ? Simon Le 27/08/2015 12:03, Didier Paulin a écrit : Bonjour à tous, j'ai une nouvelle idée de paquet wapt et donc une nouvelle problématique : Objectif : /Lancer un bat qui permet la mise à jour d'un logiciel sur les postes client, pour l'instant les users le lance manuellement si nécessaire. Celui çi, à chaque maj du soft, est générer et stocker par le serveur ainsi que les fichiers à copier via le batch./ /Pour simplifier les manipulation users (et être sur que les majs clientes soit faites ) , je veux faire un simple paquet qui à a chaque changement de version relance ce bat./ Je voudrait donc créer un paquet qui lance un .bat qui se trouve sur un partage réseau. Ce .bat fait un xcopy de fichiers se trouvant sur un partage smb vers le poste en local. Problème : Comme le service /waptservice/ tourne en compte system, il n'a pas accès au partage smb. Avez vous une idée pour faire un authentification en python pour arriver à lancer le batch, puis le lancer en "run as" avec un compte qui à les droits sur le partage ( pour que le xcopy est les droits ncessaire) ? Merci pour vos idées. Cordialement. _______________________________________________ WAPT mailing list WAPT@lists.tranquil.it http://lists.tranquil.it/listinfo/wapt _______________________________________________ WAPT mailing list WAPT@lists.tranquil.it http://lists.tranquil.it/listinfo/wapt _______________________________________________ WAPT mailing list WAPT@lists.tranquil.it http://lists.tranquil.it/listinfo/wapt
Merci de nous aider à préserver l'environnement en n'imprimant ce courriel et les documents joints que si nécessaire.
WAPT mailing list WAPT@lists.tranquil.it http://lists.tranquil.it/listinfo/wapt
WAPT mailing list WAPT@lists.tranquil.it http://lists.tranquil.it/listinfo/wapt