diff --git a/configure-syslog.py b/configure-syslog.py index 82215e9..def542b 100755 --- a/configure-syslog.py +++ b/configure-syslog.py @@ -4,7 +4,7 @@ # Loggly Syslog configuration script. # # This script automatically configures a syslog-ng or rsyslog -# installation such that it sends all logs from this system to Loggly. +# setup such that it sends all logs from this system to Loggly. # # For this to work you must have an account on the Loggly system. Sign # up for one at http://www.loggly.com. @@ -976,8 +976,7 @@ def modify_syslog_config_file(syslog_id, syslog_configuration_details, if len(syslog_configuration_details.get("token")) <= 0: question = ("\nThe Loggly configuration will be appended to (%s) file." - "\n\nDo you want this installer to modify " - "the configuration file?" + "\n\nWould you like to have the configuration file modified?" % default_config_file_name.get(syslog_id)) modify = noconfirm or confirm(question) if modify: @@ -1249,7 +1248,7 @@ def perform_sanity_check_and_get_product_for_configuration(current_environment, return syslog_name_for_configuration def install(current_environment): - printLog("Installation started") + printLog("Setup started") # 1. Determine user type. user_type = get_user_type() # 2. Determine the environment in which it was invoked @@ -1289,10 +1288,10 @@ def verify(current_environment): printLog("Verification completed") def uninstall(current_environment): - printLog("Uninstall started") + printLog("Revert started") user_type = get_user_type() if user_type == NON_ROOT_USER: - printLog("Please become root to uninstall") + printLog("Please become root to revert") sys.exit() #No need to check syslog service for uninstall syslog_name_for_configuration = \ @@ -1303,7 +1302,7 @@ def uninstall(current_environment): if not selinux_status: noconfirm = current_environment['options'].noconfirm confirm_syslog_restart(syslog_name_for_configuration, noconfirm) - printLog("Uninstall completed") + printLog("Revert completed") def rsyslog_dryrun(): results = get_stderr_from_process('rsyslogd -N1') @@ -1370,8 +1369,8 @@ def dryrun(current_environment): module_dict = { 'sysinfo' : write_env_details, - 'install' :install, - 'uninstall' : uninstall, + 'setup' :install, + 'revert' : uninstall, 'verify' : verify, 'dryrun' : dryrun } @@ -1382,7 +1381,7 @@ def loggly_help(): loggly_user, loggly_password, loggly_subdomain = login() auth_tokens = get_auth(loggly_user, loggly_password, loggly_subdomain) logglyhelp = LOGGLY_HELP % { - 'subdomain': loggly_subdomain, + 'account': loggly_subdomain, 'token': auth_tokens[-1], 'dist_id': DISTRIBUTION_ID, 'syslog_server': LOGGLY_SYSLOG_SERVER, @@ -1427,14 +1426,14 @@ def parse_args(self, *args, **kwargs): CMD_USAGE = ''' %prog [option] Action: -\tinstall Configure the syslog -\tuninstall Remove changes made by the syslog configuration script +\tsetup Configure your syslog setup +\trevert Revert changes made by this syslog configuration script \tverify Verify the configuration explicitly \tsysinfo Print, write system information \tloggly_help Guideline for users for each step to configure syslog \tdryrun Perform configuration steps without modifying anything Option: -\tsubdomain Name of loggly account being connected to +\taccount Name of loggly account being connected to \tauth Loggly auth token to use for logging \tyes Skip confirmations -- assume yes '''.lstrip() @@ -1446,10 +1445,10 @@ def parse_options(): parser = PAOptionParser(usage=CMD_USAGE) parser.add_posarg("action", dest='action', type="choice", - choices=('install', 'uninstall', 'verify', + choices=('setup', 'revert', 'verify', 'sysinfo', 'loggly_help', 'dryrun')) parser.add_option("-y", "--yes", action="store_true", dest='noconfirm') - parser.add_option("-s", "--subdomain") + parser.add_option("-s", "--account") parser.add_option("-a", "--auth") (options, args) = parser.parse_args() return options