Permalink
Browse files

Separate home/ for standalone broker. Some code dupe at the moment bu…

…t pynimbusconfig should be what everything uses going foward.
  • Loading branch information...
1 parent b4def17 commit dd82e1a6abab67621fdc7c1e60b46fff6aeb1038 @timf timf committed Jun 10, 2011
Showing with 3,293 additions and 0 deletions.
  1. +38 −0 ctx-broker/home/bin/broker-configure
  2. +28 −0 ctx-broker/home/bin/brokerctl
  3. +594 −0 ctx-broker/home/lib/ProcessManager.py
  4. +83 −0 ctx-broker/home/lib/brokerctl.py
  5. +3 −0 ctx-broker/home/lib/pynimbusconfig/README
  6. 0 ctx-broker/home/lib/pynimbusconfig/__init__.py
  7. +273 −0 ctx-broker/home/lib/pynimbusconfig/autoca.py
  8. 0 ctx-broker/home/lib/pynimbusconfig/broker/__init__.py
  9. +579 −0 ctx-broker/home/lib/pynimbusconfig/broker/main.py
  10. +92 −0 ctx-broker/home/lib/pynimbusconfig/checkssl.py
  11. +72 −0 ctx-broker/home/lib/pynimbusconfig/ezpz_ca.py
  12. +29 −0 ctx-broker/home/lib/pynimbusconfig/forcessl.py
  13. +133 −0 ctx-broker/home/lib/pynimbusconfig/gtcontainer.py
  14. 0 ctx-broker/home/lib/pynimbusconfig/iaas/__init__.py
  15. +85 −0 ctx-broker/home/lib/pynimbusconfig/iaas/derbyutil.py
  16. +169 −0 ctx-broker/home/lib/pynimbusconfig/iaas/groupauthz.py
  17. +422 −0 ctx-broker/home/lib/pynimbusconfig/iaas/main.py
  18. +39 −0 ctx-broker/home/lib/pynimbusconfig/javautil.py
  19. +194 −0 ctx-broker/home/lib/pynimbusconfig/pathutil.py
  20. +196 −0 ctx-broker/home/lib/pynimbusconfig/runutil.py
  21. +57 −0 ctx-broker/home/lib/pynimbusconfig/setuperrors.py
  22. 0 ctx-broker/home/lib/pynimbusconfig/test/__init__.py
  23. +73 −0 ctx-broker/home/lib/pynimbusconfig/test/test_groupauthz.py
  24. 0 ctx-broker/home/lib/pynimbusconfig/web/__init__.py
  25. +95 −0 ctx-broker/home/lib/pynimbusconfig/web/newconf.py
  26. +17 −0 ctx-broker/home/lib/run-broker.sh
  27. +22 −0 ctx-broker/home/lib/run-pynimbusconfig-tests.sh
@@ -0,0 +1,38 @@
+#!/bin/bash
+
+PYTHON_EXE="/usr/bin/env python -Wignore::DeprecationWarning"
+
+NIMBUS_HOME_REL="`dirname $0`/.."
+NIMBUS_HOME=`cd $NIMBUS_HOME_REL; pwd`
+
+if [ -d $NIMBUS_HOME/lib/pynimbusconfig ]; then
+ NIMBUS_PYLIB=$NIMBUS_HOME/lib
+else
+ echo "Cannot locate Python lib directory"
+ exit 1
+fi
+
+PYTHONPATH="$NIMBUS_PYLIB:$PYTHONPATH"
+export PYTHONPATH
+
+# returns 0 if Python 2.5+
+$PYTHON_EXE -c "import sys; sys.exit(sys.version_info < (2,5))"
+if [ $? -ne 0 ]; then
+ echo "ERROR: Your system must have Python version 2.5 or later."
+ exit 1
+fi
+
+$PYTHON_EXE $NIMBUS_HOME/lib/pynimbusconfig/broker/main.py --basedir $NIMBUS_HOME $@
+EXITCODE=$?
+if [ $EXITCODE -ne 42 ]; then
+
+ if [ $EXITCODE -eq 0 ]; then
+ exit 0
+ else
+ echo ""
+ echo "Nimbus is not set up properly, exiting."
+ exit 2
+ fi
+fi
+
+
@@ -0,0 +1,28 @@
+#!/bin/bash
+
+PYTHON_EXE="/usr/bin/env python -Wignore::DeprecationWarning"
+
+NIMBUS_HOME_REL="`dirname $0`/.."
+NIMBUS_HOME=`cd $NIMBUS_HOME_REL; pwd`
+
+export NIMBUS_HOME
+
+if [ -d $NIMBUS_HOME/lib/pynimbusconfig ]; then
+ NIMBUS_PYLIB=$NIMBUS_HOME/lib
+else
+ echo "Cannot locate Python lib directory"
+ exit 1
+fi
+
+PYTHONPATH="$NIMBUS_PYLIB:$PYTHONPATH"
+export PYTHONPATH
+
+# returns 0 if Python 2.5+
+$PYTHON_EXE -c "import sys; sys.exit(sys.version_info < (2,5))"
+if [ $? -ne 0 ]; then
+ echo "ERROR: Your system must have Python version 2.5 or later."
+ exit 1
+fi
+
+$PYTHON_EXE $NIMBUS_HOME/lib/brokerctl.py $@
+exit $?
Oops, something went wrong.

0 comments on commit dd82e1a

Please sign in to comment.