def __init__(self, parent=None): super(DatabasePage, self).__init__(parent) self.liderdb_path = os.path.join( os.path.dirname(os.path.abspath(__file__)), '../../dist/liderdb.json') self.server_list_path = os.path.join( os.path.dirname(os.path.abspath(__file__)), '../../dist/server_list.json') if not os.path.exists( os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist')): os.makedirs( os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist')) self.status = StatusPage() self.im = InstallManager() self.msg_box = MessageBox() self.data = None ## database parameters self.dbNameLabel = QLabel("Veritabanı Adı:") self.db_name = QLineEdit() self.db_name.setPlaceholderText("liderdb") self.dbUsernameLabel = QLabel("Veritabanı Kullanıcı Adı:") self.db_username = QLineEdit() self.db_username.setPlaceholderText("root") self.dbPwdLabel = QLabel("Veritabanı Kullanıcı Parolası:") self.db_password = QLineEdit() self.db_password.setEchoMode(QLineEdit.Password) self.db_password.setPlaceholderText("****") self.startUpdateButton = QPushButton("Kuruluma Başla") ## Database Layout self.dbGroup = QGroupBox("Veritabanı Konfigürasyon Bilgileri") self.dbLayout = QGridLayout() self.dbLayout.addWidget(self.dbNameLabel, 0, 0) self.dbLayout.addWidget(self.db_name, 0, 1) self.dbLayout.addWidget(self.dbUsernameLabel, 1, 0) self.dbLayout.addWidget(self.db_username, 1, 1) self.dbLayout.addWidget(self.dbPwdLabel, 2, 0) self.dbLayout.addWidget(self.db_password, 2, 1) self.dbGroup.setLayout(self.dbLayout) # Install Status Layout self.statusGroup = QGroupBox() self.status.statusLabel.setText("Veritabanı Kurulum Durumu:") self.statusGroup.setLayout(self.status.statusLayout) self.mainLayout = QVBoxLayout() self.mainLayout.addWidget(self.dbGroup) self.mainLayout.addSpacing(12) self.mainLayout.addWidget(self.startUpdateButton) self.mainLayout.addWidget(self.statusGroup) self.mainLayout.addStretch(1) self.setLayout(self.mainLayout) self.startUpdateButton.clicked.connect(self.save_db_data)
def __init__(self, parent=None): super(LiderPage, self).__init__(parent) self.liderldap_path = os.path.join( os.path.dirname(os.path.abspath(__file__)), '../../dist/lider_ldap.json') self.liderejabberd_path = os.path.join( os.path.dirname(os.path.abspath(__file__)), '../../dist/lider_ejabberd.json') self.liderdb_path = os.path.join( os.path.dirname(os.path.abspath(__file__)), '../../dist/liderdb.json') self.lider_path = os.path.join( os.path.dirname(os.path.abspath(__file__)), '../../dist/lider.json') self.server_list_path = os.path.join( os.path.dirname(os.path.abspath(__file__)), '../../dist/server_list.json') self.log_path = os.path.join( os.path.dirname(os.path.abspath(__file__)), '../../dist/installer.log') if not os.path.exists( os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist')): os.makedirs( os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist')) self.ldap_layout = OpenLdapPage() self.ejabberd_layout = EjabberdPage() self.db_layout = DatabasePage() self.im = InstallManager() self.msg_box = MessageBox() self.status = StatusPage() self.lider_sunucu_pwd = None self.db_password = None self.util = Util() ## db parameters self.dbServerLabel = QLabel("Veritabanı Sunucu Adresi:") self.db_server_layout = QLineEdit() self.db_server_layout.setPlaceholderText("192.168.*.*") # OpenLDAP parameters self.ldapServerLabel = QLabel("LDAP Sunucu Adresi:") self.ldap_server = QLineEdit() self.ldap_server.setPlaceholderText("192.168.*.*") # Ejabberd parameters self.ejabberdServerLabel = QLabel("XMPP Sunucu Adresi:") self.ejabberd_server = QLineEdit() self.ejabberd_server.setPlaceholderText("192.168.*.*") self.fileServerLabel = QLabel("Dosya Sunucu Adresi:") self.file_server = QLineEdit() self.file_server.setPlaceholderText("192.168.*.*") # self.file_server.setDisabled(True) self.file_server.setVisible(False) self.fileServerLabel.setVisible(False) self.installButton = QPushButton("Kuruluma Başla") # if not os.path.exists(self.server_list_path): # self.installButton.setDisabled(True) self.installButton.clicked.connect(self.lider_ahenk_install) self.liderLdapGroup = QGroupBox( "Lider Ahenk Sunucu Konfigürasyon Bilgileri") self.liderXmppGroup = QGroupBox("XMPP Konfigürasyon Bilgileri") self.liderDbGroup = QGroupBox("Veritabanı Konfigürasyon Bilgileri") # Install Status Layout statusGroup = QGroupBox() self.status.statusLabel.setText("Lider Kurulum Durumu:") statusGroup.setLayout(self.status.statusLayout) # add server ip to database layout self.liderDbGroup.setLayout(self.db_layout.dbLayout) # add server ip to ldap layout self.liderLdapGroup.setLayout(self.ldap_layout.ldapLayout) # add server ip to ejabberd layout self.ejabberd_layout.ejabberdLayout.removeWidget( self.ejabberd_layout.ldapServerLabel) self.ejabberd_layout.ejabberdLayout.removeWidget( self.ejabberd_layout.ldap_server) # self.ejabberd_layout.ejabberdLayout.addWidget(self.ejabberdServerLabel, 8, 0) # self.ejabberd_layout.ejabberdLayout.addWidget(self.ejabberd_server, 8, 1) self.liderXmppGroup.setLayout(self.ejabberd_layout.ejabberdLayout) self.liderGroup = QGroupBox() # liderLayout = QVBoxLayout() liderLayout = QGridLayout() # liderLayout.addSpacing(12) liderLayout.addWidget(self.installButton, 0, 1) # liderLayout.addStretch(1) self.liderGroup.setLayout(liderLayout) mainLayout = QVBoxLayout() # mainLayout.addWidget(self.liderDbGroup) mainLayout.addWidget(self.liderLdapGroup) # mainLayout.addWidget(self.liderXmppGroup) mainLayout.addWidget(self.liderGroup) mainLayout.addWidget(statusGroup) mainLayout.addSpacing(12) mainLayout.addStretch(1) self.setLayout(mainLayout) if self.util.is_exist(self.liderldap_path): with open(self.liderldap_path) as f: data = json.load(f) self.ldap_layout.ldap_base_dn.setText(data["l_base_dn"]) self.ldap_layout.ldap_admin_pwd.setText(data["l_admin_pwd"]) self.ldap_layout.ladmin_user.setText(data["ladmin_user"]) self.ldap_layout.ladmin_pwd.setText(data["l_admin_pwd"])
def __init__(self, parent=None): super(LiderConsolePage, self).__init__(parent) self.liderdb_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist/liderdb.json') self.server_list_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist/server_list.json') self.log_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist/installer.log') if not os.path.exists(os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist')): os.makedirs(os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist')) self.status = StatusPage() self.im = InstallManager() self.msg_box = MessageBox() self.data = None ## repository parameters self.repoMainBox = QCheckBox("Ana Paket Deposu") self.repoTestBox = QCheckBox("Test Paket Deposu") self.repoMainBox.setChecked(True) self.repoLabel = QLabel("Depo Adresi:") self.repo_addr = QLineEdit("deb [arch=amd64] http://repo.liderahenk.org/liderahenk stable main") self.repoKeyLdabel = QLabel("Depo Key Dosyası:") self.repo_key = QLineEdit("http://repo.liderahenk.org/liderahenk-archive-keyring.asc") self.repoMainBox.stateChanged.connect(self.main_repo) self.repoTestBox.stateChanged.connect(self.test_repo) ## Repository Layout self.repoGroup = QGroupBox("Lider Ahenk Paket Deposu Ayarları") self.repoLayout = QGridLayout() self.repoLayout.addWidget(self.repoMainBox, 0, 0) self.repoLayout.addWidget(self.repoTestBox, 0, 1) self.repoLayout.addWidget(self.repoLabel, 1, 0) self.repoLayout.addWidget(self.repo_addr, 1, 1) self.repoLayout.addWidget(self.repoKeyLdabel, 2, 0) self.repoLayout.addWidget(self.repo_key, 2, 1) self.repoGroup.setLayout(self.repoLayout) #self.serverIpLabel = QLabel("Sunucu Adresi:") #self.server_ip = QLineEdit() #self.server_ip.setPlaceholderText("192.168.*.*") self.usernameLabel = QLabel("Kullanıcı Adı:") self.username = QLineEdit() self.username.setPlaceholderText("lider") self.passwordLabel = QLabel("Kullanıcı Parolası:") self.password = QLineEdit() self.password.setPlaceholderText("****") self.password.setEchoMode(QLineEdit.Password) self.addButton = QPushButton("Ekle") #self.checkControlButton = QPushButton("Bağlantıyı Kontrol Et") self.saveButton = QPushButton("Ayarları Kaydet") # disabled by default saveButton # self.saveButton.setDisabled(True) self.addButton.setVisible(False) ## Connect Layout self.connectGroup = QGroupBox("Lider Arayüz Erişim Bilgileri") self.connectLayout = QGridLayout() #self.connectLayout.addWidget(self.serverIpLabel, 2, 0) #self.connectLayout.addWidget(self.server_ip, 2, 1) self.connectLayout.addWidget(self.usernameLabel, 3, 0) self.connectLayout.addWidget(self.username, 3, 1) self.connectLayout.addWidget(self.passwordLabel, 4, 0) self.connectLayout.addWidget(self.password, 4, 1) self.connectLayout.addWidget(self.addButton, 5, 2) #self.connectLayout.addWidget(self.checkControlButton, 5, 1) self.connectGroup.setLayout(self.connectLayout) self.installButton = QPushButton("Kuruluma Başla") # Install Status Layout #self.statusGroup = QGroupBox() #self.status.statusLabel.setText("Lİder Arayüz Kurulum Durumu:") #self.statusGroup.setLayout(self.status.statusLayout) self.mainLayout = QVBoxLayout() self.mainLayout.addWidget(self.repoGroup) self.mainLayout.addWidget(self.connectGroup) self.mainLayout.addSpacing(12) self.mainLayout.addWidget(self.installButton) #self.mainLayout.addWidget(self.statusGroup) self.mainLayout.addStretch(1) self.setLayout(self.mainLayout) self.installButton.clicked.connect(self.install_lider_console)
def __init__(self, parent=None): super(AhenkPage, self).__init__(parent) self.ahenk_list_file = os.path.join( os.path.dirname(os.path.abspath(__file__)), '../../dist/ahenk_list.txt') self.log_path = os.path.join( os.path.dirname(os.path.abspath(__file__)), '../../dist/installer.log') if not os.path.exists( os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist')): os.makedirs( os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist')) self.status = StatusPage() self.im = InstallManager() self.msg_box = MessageBox() self.data = None ## client settings parameters self.serverIpLabel = QLabel("İstemci Adresi:") self.server_ip = QLineEdit() self.server_ip.setPlaceholderText("192.168.*.*") self.usernameLabel = QLabel("Kullanıcı Adı:") self.username = QLineEdit() self.username.setPlaceholderText("lider") self.passwordLabel = QLabel("Kullanıcı Parolası:") self.password = QLineEdit() # self.password.setPlaceholderText("****") self.password.setEchoMode(QLineEdit.Password) self.addButton = QPushButton("Ekle") ## Connect Layout self.connectGroup = QGroupBox( "Ahenk Kurulacak İstemci Erişim Bilgileri") self.connectLayout = QGridLayout() self.connectLayout.addWidget(self.serverIpLabel, 0, 0) self.connectLayout.addWidget(self.server_ip, 0, 1) self.connectLayout.addWidget(self.usernameLabel, 1, 0) self.connectLayout.addWidget(self.username, 1, 1) self.connectLayout.addWidget(self.passwordLabel, 2, 0) self.connectLayout.addWidget(self.password, 2, 1) self.connectLayout.addWidget(self.addButton, 0, 2) self.connectGroup.setLayout(self.connectLayout) ## repository layout self.repoMainBox = QCheckBox("Ana Paket Deposu") self.repoTestBox = QCheckBox("Test Paket Deposu") self.repoMainBox.setChecked(True) self.repoLabel = QLabel("Depo Adresi:") self.repo_addr = QLineEdit( "deb [arch=amd64] http://repo.liderahenk.org/liderahenk stable main" ) self.repoKeyLdabel = QLabel("Depo Key Dosyası:") self.repo_key = QLineEdit( "http://repo.liderahenk.org/liderahenk-archive-keyring.asc") self.repoMainBox.stateChanged.connect(self.main_repo) self.repoTestBox.stateChanged.connect(self.test_repo) ## Repository Layout self.repoGroup = QGroupBox("Lider Ahenk Paket Deposu Ayarları") self.repoLayout = QGridLayout() self.repoLayout.addWidget(self.repoMainBox, 0, 0) self.repoLayout.addWidget(self.repoTestBox, 0, 1) self.repoLayout.addWidget(self.repoLabel, 1, 0) self.repoLayout.addWidget(self.repo_addr, 1, 1) self.repoLayout.addWidget(self.repoKeyLdabel, 2, 0) self.repoLayout.addWidget(self.repo_key, 2, 1) self.repoGroup.setLayout(self.repoLayout) ## ahenk parameters self.hostLabel = QLabel("XMPP Sunucu Adresi:") self.host = QLineEdit() self.host.setPlaceholderText("192.168.*.*") # self.serviceNameLabel = QLabel("XMPP Servis Adı:") # self.service_name = QLineEdit() # self.service_name.setPlaceholderText("im.liderahenk.org") self.startUpdateButton = QPushButton("Kuruluma Başla") ## ahenk Layout self.ahenkGroup = QGroupBox("Ahenk Konfigürasyon Bilgileri") self.ahenkLayout = QGridLayout() self.ahenkLayout.addWidget(self.hostLabel, 0, 0) self.ahenkLayout.addWidget(self.host, 0, 1) # self.ahenkLayout.addWidget(self.serviceNameLabel, 1, 0) # self.ahenkLayout.addWidget(self.service_name, 1, 1) self.ahenkGroup.setLayout(self.ahenkLayout) ## ahenk list table self.ahenklistGroup = QGroupBox("Ahenk Kurulacak İstemci Listesi") self.ahenklistLayout = QGridLayout() self.tableWidget = QTableWidget() # self.tableWidget.setMinimumHeight(250) ## set read only table self.tableWidget.setEditTriggers(QTableWidget.NoEditTriggers) # set column count self.tableWidget.setColumnCount(4) headers = self.tableWidget.horizontalHeader() headers.setSectionResizeMode(0, QHeaderView.Stretch) headers.setSectionResizeMode(1, QHeaderView.Stretch) headers.setSectionResizeMode(2, QHeaderView.Stretch) self.tableWidget.setHorizontalHeaderLabels( ["İstemci Adresi", "Kullanıcı Adı", "Kullanıcı Parolası", "İşlem"]) self.ahenklistLayout.addWidget(self.tableWidget) self.ahenklistGroup.setLayout(self.ahenklistLayout) # Install Status Layout statusGroup = QGroupBox() self.status.statusLabel.setText("Ahenk Kurulum Durumu:") statusGroup.setLayout(self.status.statusLayout) mainLayout = QVBoxLayout() mainLayout.addWidget(self.ahenkGroup) mainLayout.addWidget(self.repoGroup) mainLayout.addWidget(self.connectGroup) mainLayout.addWidget(self.ahenklistGroup) mainLayout.addSpacing(12) mainLayout.addWidget(self.startUpdateButton) mainLayout.addWidget(statusGroup) mainLayout.addStretch(1) self.setLayout(mainLayout) self.startUpdateButton.clicked.connect(self.install_ahenk) self.addButton.clicked.connect(self.add_ahenk)
def __init__(self, parent=None): super(EjabberdPage, self).__init__(parent) self.liderejabberd_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist/lider_ejabberd.json') self.liderldap_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist/lider_ldap.json') self.server_list_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist/server_list.json') if not os.path.exists(os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist')): os.makedirs(os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist')) self.data = None self.im = InstallManager() self.msg_box = MessageBox() self.status = StatusPage() self.startUpdateButton = QPushButton("Kuruluma Başla") ## Ejabberd parameters self.ejabberdServiceLabel = QLabel("XMPP Servis Adı:") self.e_service_name = QLineEdit() self.e_service_name.setPlaceholderText("im.liderahenk.org") self.ejabberdAdminLabel = QLabel("XMPP Admin Kullanıcı Adı:") self.e_username = QLineEdit() self.e_username.setPlaceholderText("admin") self.ejabberdAdminPwdLabel = QLabel("XMPP Admin Kullanıcı Parolası:") self.e_user_pwd = QLineEdit() self.e_user_pwd.setEchoMode(QLineEdit.Password) self.e_user_pwd.setPlaceholderText("****") self.ejabberdLiderUserLabel = QLabel("XMPP Lider Kullanıcı Adı:") self.lider_username = QLineEdit() self.lider_username.setPlaceholderText("lider_sunucu") self.ejabberdLiderPwdLAbel = QLabel("XMPP Lider Kullanıcı Parolası:") self.lider_user_pwd = QLineEdit() self.lider_user_pwd.setPlaceholderText("****") self.lider_user_pwd.setEchoMode(QLineEdit.Password) self.ldapServerLabel = QLabel("LDAP Sunucu Adresi:") self.ldap_server = QLineEdit() self.ldap_server.setPlaceholderText("192.168.*.*") self.ldapBaseDnLabel = QLabel("LDAP Base DN:") self.ldap_base_dn = QLineEdit() self.ldap_base_dn.setPlaceholderText("liderahenk.org") self.ldapAdminPwdLabel = QLabel("Ldap Admin Parolası:") self.ldap_admin_pwd = QLineEdit() self.ldap_admin_pwd.setPlaceholderText("****") self.ldap_admin_pwd.setEchoMode(QLineEdit.Password) # Install Status Layout statusGroup = QGroupBox() self.status.statusLabel.setText("XMPP Kurulum Durumu:") statusGroup.setLayout(self.status.statusLayout) ## XMPP configuration Layout self.ejabberdGroup = QGroupBox("XMPP Sunucu Konfigürasyon Bilgileri") self.ejabberdLayout = QGridLayout() # self.ejabberdLayout.addWidget(self.ejabberdServiceLabel, 0, 0) # self.ejabberdLayout.addWidget(self.e_service_name, 0, 1) # self.ejabberdLayout.addWidget(self.ejabberdAdminLabel, 1, 0) # self.ejabberdLayout.addWidget(self.e_username, 1, 1) self.ejabberdLayout.addWidget(self.ejabberdAdminPwdLabel, 2, 0) self.ejabberdLayout.addWidget(self.e_user_pwd, 2, 1) # self.ejabberdLayout.addWidget(self.ejabberdLiderUserLabel, 3, 0) # self.ejabberdLayout.addWidget(self.lider_username, 3, 1) # self.ejabberdLayout.addWidget(self.ejabberdLiderPwdLAbel, 4, 0) # self.ejabberdLayout.addWidget(self.lider_user_pwd, 4, 1) self.ejabberdGroup.setLayout(self.ejabberdLayout) self.ldapLayout = QGridLayout() self.ldapGroup = QGroupBox() self.ldapSelection = QCheckBox("Başka LDAP Kullan") self.ldapLayout.addWidget(self.ldapSelection, 0, 0) self.ldapLayout.addWidget(self.ldapServerLabel, 1, 0) self.ldapLayout.addWidget(self.ldap_server, 1, 1) self.ldapLayout.addWidget(self.ldapBaseDnLabel, 2, 0) self.ldapLayout.addWidget(self.ldap_base_dn, 2, 1) self.ldapLayout.addWidget(self.ldapAdminPwdLabel, 3, 0) self.ldapLayout.addWidget(self.ldap_admin_pwd, 3, 1) self.ldapGroup.setLayout(self.ldapLayout) mainLayout = QVBoxLayout() mainLayout.addWidget(self.ejabberdGroup) mainLayout.addWidget(self.ldapGroup) mainLayout.addSpacing(12) mainLayout.addWidget(self.startUpdateButton) mainLayout.addWidget(statusGroup) mainLayout.addStretch(1) self.setLayout(mainLayout) self.startUpdateButton.clicked.connect(self.save_ejabberd_data) self.ldapSelection.stateChanged.connect(self.get_ldap_data) self.ldapSelection.setChecked(False)
def __init__(self, parent=None): super(OpenLdapPage, self).__init__(parent) self.liderldap_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist/lider_ldap.json') self.log_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist/installer.log') self.server_list_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist/server_list.json') if not os.path.exists(os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist')): os.makedirs(os.path.join(os.path.dirname(os.path.abspath(__file__)), '../../dist')) self.im = InstallManager() self.msg_box = MessageBox() self.status = StatusPage() self.data = None #OpenLDAP parameters self.ldapStatusLabel = QLabel("LDAP İçin İşlem Seçiniz:") self.ldapStatusCombo = QComboBox() self.ldapStatusCombo.addItem("OpenLDAP Kur") self.ldapStatusCombo.addItem("OpenLDAP Güncelle") self.ldapAdminLabel = QLabel("LDAP Admin:") self.ldap_admin = QLineEdit() self.ldapAdminPwdLabel = QLabel("Sistem Admin Parolası:") self.ldap_admin_pwd = QLineEdit() self.ldap_admin_pwd.setPlaceholderText("****") self.ldap_admin_pwd.setEchoMode(QLineEdit.Password) self.ldapBaseDnLabel = QLabel("LDAP Base DN:") self.ldap_base_dn = QLineEdit() self.ldap_base_dn.setPlaceholderText("liderahenk.org") self.ldapConfigPwdLabel = QLabel("LDAP Config Kullanıcı Parolası:") self.l_config_pwd = QLineEdit() self.l_config_pwd.setPlaceholderText("****") self.l_config_pwd.setEchoMode(QLineEdit.Password) self.ladminLabel = QLabel("Lider Arayüz Kullanıcı Adı:") self.ladmin_user = QLineEdit() self.ladmin_user.setPlaceholderText("lider_console") self.ladminPwdLabel = QLabel("Lider Arayüz Kullanıcı Parolası:") self.ladmin_pwd = QLineEdit() self.ladmin_pwd.setPlaceholderText("****") self.ladmin_pwd.setEchoMode(QLineEdit.Password) self.startUpdateButton = QPushButton("Kuruluma Başla") ## LDAP configuration Layout ldapGroup = QGroupBox("OpenLDAP Konfigürasyon Bilgileri") self.ldapLayout = QGridLayout() # Install Status Layout statusGroup = QGroupBox() self.status.statusLabel.setText("OpenLDAP Kurulum Durumu:") statusGroup.setLayout(self.status.statusLayout) self.ldapLayout.addWidget(self.ldapStatusLabel, 0, 0) self.ldapLayout.addWidget(self.ldapStatusCombo, 0, 1) self.ldapLayout.addWidget(self.ldapBaseDnLabel, 1, 0) self.ldapLayout.addWidget(self.ldap_base_dn, 1, 1) #self.ldapLayout.addWidget(self.ldapAdminLabel, 2, 0) #self.ldapLayout.addWidget(self.ldap_admin, 2, 1) self.ldapLayout.addWidget(self.ldapAdminPwdLabel, 3, 0) self.ldapLayout.addWidget(self.ldap_admin_pwd, 3, 1) #self.ldapLayout.addWidget(self.ldapConfigPwdLabel, 4, 0) #self.ldapLayout.addWidget(self.l_config_pwd, 4, 1) self.ldapLayout.addWidget(self.ladminLabel, 5, 0) self.ldapLayout.addWidget(self.ladmin_user, 5, 1) self.ldapLayout.addWidget(self.ladminPwdLabel, 6, 0) self.ldapLayout.addWidget(self.ladmin_pwd, 6, 1) ldapGroup.setLayout(self.ldapLayout) mainLayout = QVBoxLayout() mainLayout.addWidget(ldapGroup) # mainLayout.addWidget(packageGroup) mainLayout.addSpacing(12) mainLayout.addWidget(self.startUpdateButton) mainLayout.addWidget(statusGroup) mainLayout.addStretch(1) self.setLayout(mainLayout) self.startUpdateButton.clicked.connect(self.save_ldap_data)