[Python-apps-commits] r7205 - in packages/slapos.core/trunk/debian/patches (1 file)

arnau at users.alioth.debian.org arnau at users.alioth.debian.org
Sat Jun 18 07:31:05 UTC 2011


    Date: Saturday, June 18, 2011 @ 07:31:04
  Author: arnau
Revision: 7205

Fix patch for slapgrid-supervisor* system configuration file.

Modified:
  packages/slapos.core/trunk/debian/patches/system_configuration_file_by_default.patch

Modified: packages/slapos.core/trunk/debian/patches/system_configuration_file_by_default.patch
===================================================================
--- packages/slapos.core/trunk/debian/patches/system_configuration_file_by_default.patch	2011-06-18 07:17:09 UTC (rev 7204)
+++ packages/slapos.core/trunk/debian/patches/system_configuration_file_by_default.patch	2011-06-18 07:31:04 UTC (rev 7205)
@@ -5,10 +5,10 @@
  the configuration file options are set up through debconf, fallback
  on /etc/slapos/slapos.cfg generated upon package installation.
 
-Index: slapos.core-0.3~20110608+1.git9496d81/slapos/format/__init__.py
+Index: slapos.core-0.3~20110608+1.git9496d81.obsolete.0.260002630137937/slapos/format/__init__.py
 ===================================================================
---- slapos.core-0.3~20110608+1.git9496d81.orig/slapos/format/__init__.py	2011-06-09 00:39:16.000000000 +0900
-+++ slapos.core-0.3~20110608+1.git9496d81/slapos/format/__init__.py	2011-06-18 15:59:22.068004898 +0900
+--- slapos.core-0.3~20110608+1.git9496d81.obsolete.0.260002630137937.orig/slapos/format/__init__.py	2011-06-09 00:39:16.000000000 +0900
++++ slapos.core-0.3~20110608+1.git9496d81.obsolete.0.260002630137937/slapos/format/__init__.py	2011-06-18 15:59:22.068004898 +0900
 @@ -715,8 +715,10 @@
      """
      (options, args) = self.parse_args()
@@ -35,10 +35,10 @@
  
    try:
      # Parse arguments
-Index: slapos.core-0.3~20110608+1.git9496d81/slapos/grid/slapgrid.py
+Index: slapos.core-0.3~20110608+1.git9496d81.obsolete.0.260002630137937/slapos/grid/slapgrid.py
 ===================================================================
---- slapos.core-0.3~20110608+1.git9496d81.orig/slapos/grid/slapgrid.py	2011-06-09 00:39:16.000000000 +0900
-+++ slapos.core-0.3~20110608+1.git9496d81/slapos/grid/slapgrid.py	2011-06-18 15:59:22.072004898 +0900
+--- slapos.core-0.3~20110608+1.git9496d81.obsolete.0.260002630137937.orig/slapos/grid/slapgrid.py	2011-06-09 00:39:16.000000000 +0900
++++ slapos.core-0.3~20110608+1.git9496d81.obsolete.0.260002630137937/slapos/grid/slapgrid.py	2011-06-18 15:59:22.072004898 +0900
 @@ -103,8 +103,8 @@
        help="Enables console output and live output from subcommands.")
    parser.add_argument("-v", "--verbose", action="store_true", default=False,
@@ -59,10 +59,10 @@
    # Loads config (if config specified)
    slapgrid_configuration = ConfigParser.SafeConfigParser()
    slapgrid_configuration.readfp(configuration_file)
-Index: slapos.core-0.3~20110608+1.git9496d81/slapos/proxy/__init__.py
+Index: slapos.core-0.3~20110608+1.git9496d81.obsolete.0.260002630137937/slapos/proxy/__init__.py
 ===================================================================
---- slapos.core-0.3~20110608+1.git9496d81.orig/slapos/proxy/__init__.py	2011-06-18 16:09:38.604004909 +0900
-+++ slapos.core-0.3~20110608+1.git9496d81/slapos/proxy/__init__.py	2011-06-18 16:10:22.708004911 +0900
+--- slapos.core-0.3~20110608+1.git9496d81.obsolete.0.260002630137937.orig/slapos/proxy/__init__.py	2011-06-18 16:09:38.604004909 +0900
++++ slapos.core-0.3~20110608+1.git9496d81.obsolete.0.260002630137937/slapos/proxy/__init__.py	2011-06-18 16:10:22.708004911 +0900
 @@ -38,9 +38,11 @@
      """
      (options, args) = self.parse_args()
@@ -77,10 +77,10 @@
  
  class Config:
    def setConfig(self, option_dict, configuration_file_path):
-Index: slapos.core-0.3~20110608+1.git9496d81/slapos/grid/svcbackend.py
+Index: slapos.core-0.3~20110608+1.git9496d81.obsolete.0.260002630137937/slapos/grid/svcbackend.py
 ===================================================================
---- slapos.core-0.3~20110608+1.git9496d81.orig/slapos/grid/svcbackend.py	2011-06-18 16:11:55.392004911 +0900
-+++ slapos.core-0.3~20110608+1.git9496d81/slapos/grid/svcbackend.py	2011-06-18 16:14:07.700004916 +0900
+--- slapos.core-0.3~20110608+1.git9496d81.obsolete.0.260002630137937.orig/slapos/grid/svcbackend.py	2011-06-18 16:11:55.392004911 +0900
++++ slapos.core-0.3~20110608+1.git9496d81.obsolete.0.260002630137937/slapos/grid/svcbackend.py	2011-06-18 16:29:08.476004929 +0900
 @@ -124,6 +124,8 @@
  Typical usage:
   * %prog CONFIGURATION_FILE [arguments passed to supervisor]
@@ -90,15 +90,25 @@
  """.strip()
  
    parser = OptionParser(usage=usage)
-@@ -137,7 +139,10 @@
+@@ -135,9 +137,9 @@
+     (argument_option_instance, argument_list) = \
+       parser.parse_args(list(argument_tuple))
    if len(argument_list) == 0:
-     parser.error("Configuration file is obligatory. Consult documentation by "
-         "calling with -h.")
+-    parser.error("Configuration file is obligatory. Consult documentation by "
+-        "calling with -h.")
 -  configuration_file = argument_list[0]
-+  try:
-+    configuration_file = argument_list[0]
-+  except IndexError:
 +    configuration_file = '/etc/slapos/slapos.cfg'
++  else:
++    configuration_file = argument_list.pop(0)
    if not os.path.exists(configuration_file):
      parser.error("Could not read configuration file : %s" \
          % configuration_file)
+@@ -153,7 +155,7 @@
+   if not option_dict.get('supervisord_socket'):
+     option_dict['supervisord_socket'] = \
+       os.path.join(option_dict['instance_root'], 'supervisord.socket')
+-  return option_dict, argument_list[1:]
++  return option_dict, argument_list
+ 
+ 
+ def supervisorctl(*argument_tuple):




More information about the Python-apps-commits mailing list