Created
January 12, 2019 22:38
-
-
Save joseb0rges/d77ea1341870ce436f47d6ffed63feee to your computer and use it in GitHub Desktop.
Change_Account - Zimbra .py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
## | |
# Script Em pyhon | |
# Autor -> José Borges | |
## | |
import os | |
import csv | |
class Import: | |
def __init__(self,file): | |
self.__file = file | |
def ImportContas(self): | |
dataset = csv.reader(open(self.__file,'r')) | |
for data in dataset: | |
idlogin = data[0] | |
idloginnew = data[1] | |
os.system("su zimbra /opt/zabbix/bin/zmprov ra"+idlogin+" "+idloginnew) | |
I = Import('teste.csv') | |
I.ImportContas() | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment