"Fossies" - the Fresh Open Source Software Archive

Member "magnum-8.2.0/devstack/plugin.sh" (6 Dec 2019, 1622 Bytes) of package /linux/misc/openstack/magnum-8.2.0.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Bash source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file. See also the latest Fossies "Diffs" side-by-side code changes report for "plugin.sh": 8.1.0_vs_8.2.0.

    1 # magnum.sh - Devstack extras script to install magnum
    2 
    3 # Save trace setting
    4 XTRACE=$(set +o | grep xtrace)
    5 set -o xtrace
    6 
    7 echo_summary "magnum's plugin.sh was called..."
    8 source $DEST/magnum/devstack/lib/magnum
    9 (set -o posix; set)
   10 
   11 if is_service_enabled magnum-api magnum-cond; then
   12     if [[ "$1" == "stack" && "$2" == "install" ]]; then
   13         echo_summary "Installing magnum"
   14         install_magnum
   15 
   16         MAGNUM_GUEST_IMAGE_URL=${MAGNUM_GUEST_IMAGE_URL:-"https://dl.fedoraproject.org/pub/alt/atomic/stable/Fedora-29-updates-20190820.0/AtomicHost/x86_64/images/Fedora-AtomicHost-29-20190820.0.x86_64.qcow2"}
   17         IMAGE_URLS+=",${MAGNUM_GUEST_IMAGE_URL}"
   18 
   19         LIBS_FROM_GIT="${LIBS_FROM_GIT},python-magnumclient"
   20 
   21         install_magnumclient
   22         cleanup_magnum
   23     elif [[ "$1" == "stack" && "$2" == "post-config" ]]; then
   24         echo_summary "Configuring magnum"
   25         configure_magnum
   26 
   27         # Hack a large timeout for now
   28         iniset /etc/keystone/keystone.conf token expiration 7200
   29 
   30         if is_service_enabled key; then
   31             create_magnum_accounts
   32         fi
   33 
   34     elif [[ "$1" == "stack" && "$2" == "extra" ]]; then
   35         # Initialize magnum
   36         init_magnum
   37         magnum_register_image
   38         magnum_configure_flavor
   39 
   40         # Start the magnum API and magnum taskmgr components
   41         echo_summary "Starting magnum"
   42         start_magnum
   43 
   44         configure_iptables_magnum
   45         configure_apache_magnum
   46     fi
   47 
   48     if [[ "$1" == "unstack" ]]; then
   49         stop_magnum
   50     fi
   51 
   52     if [[ "$1" == "clean" ]]; then
   53         cleanup_magnum
   54     fi
   55 fi
   56 
   57 # Restore xtrace
   58 $XTRACE