aboutsummaryrefslogtreecommitdiffstats
path: root/functest/cli/functest-complete.sh
diff options
context:
space:
mode:
authorMorgan Richomme <morgan.richomme@orange.com>2016-11-08 14:18:12 +0100
committerMorgan Richomme <morgan.richomme@orange.com>2016-11-09 16:55:45 +0100
commit107e61635c2ab1feb5263380ea63e21cf2e6e65b (patch)
tree4966b77605bd34a40f452b1d268868691e84d008 /functest/cli/functest-complete.sh
parente74c9b347f2623eb1a3c477921a84da4c31b364f (diff)
Repo structure modification
- create functest subdirectory - rename unit tests - adapt path in exec and config files JIRA: FUNCTEST-525 Change-Id: Ifd5c6edfb5bda1b09f82848e2269ad5fbeb84d0a Signed-off-by: Morgan Richomme <morgan.richomme@orange.com>
Diffstat (limited to 'functest/cli/functest-complete.sh')
-rw-r--r--functest/cli/functest-complete.sh8
1 files changed, 8 insertions, 0 deletions
diff --git a/functest/cli/functest-complete.sh b/functest/cli/functest-complete.sh
new file mode 100644
index 00000000..f0149071
--- /dev/null
+++ b/functest/cli/functest-complete.sh
@@ -0,0 +1,8 @@
+_functest_completion() {
+ COMPREPLY=( $( env COMP_WORDS="${COMP_WORDS[*]}" \
+ COMP_CWORD=$COMP_CWORD \
+ _FUNCTEST_COMPLETE=complete $1 ) )
+ return 0
+}
+
+complete -F _functest_completion -o default functest;
*/ .highlight .se { color: #ae81ff } /* Literal.String.Escape */ .highlight .sh { color: #e6db74 } /* Literal.String.Heredoc */ .highlight .si { color: #e6db74 } /* Literal.String.Interpol */ .highlight .sx { color: #e6db74 } /* Literal.String.Other */ .highlight .sr { color: #e6db74 } /* Literal.String.Regex */ .highlight .s1 { color: #e6db74 } /* Literal.String.Single */ .highlight .ss { color: #e6db74 } /* Literal.String.Symbol */ .highlight .bp { color: #f8f8f2 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #a6e22e } /* Name.Function.Magic */ .highlight .vc { color: #f8f8f2 } /* Name.Variable.Class */ .highlight .vg { color: #f8f8f2 } /* Name.Variable.Global */ .highlight .vi { color: #f8f8f2 } /* Name.Variable.Instance */ .highlight .vm { color: #f8f8f2 } /* Name.Variable.Magic */ .highlight .il { color: #ae81ff } /* Literal.Number.Integer.Long */ } @media (prefers-color-scheme: light) { .highlight .hll { background-color: #ffffcc } .highlight .c { color: #888888 } /* Comment */ .highlight .err { color: #a61717; background-color: #e3d2d2 } /* Error */ .highlight .k { color: #008800; font-weight: bold } /* Keyword */ .highlight .ch { color: #888888 } /* Comment.Hashbang */ .highlight .cm { color: #888888 } /* Comment.Multiline */ .highlight .cp { color: #cc0000; font-weight: bold } /* Comment.Preproc */ .highlight .cpf { color: #888888 } /* Comment.PreprocFile */ .highlight .c1 { color: #888888 } /* Comment.Single */ .highlight .cs { color: #cc0000; font-weight: bold; background-color: #fff0f0 } /* Comment.Special */ .highlight .gd { color: #000000; background-color: #ffdddd } /* Generic.Deleted */ .highlight .ge { font-style: italic } /* Generic.Emph */ .highlight .gr { color: #aa0000 } /* Generic.Error */ .highlight .gh { color: #333333 } /* Generic.Heading */ .highlight .gi { color: #000000; background-color: #ddffdd } /* Generic.Inserted */ .highlight .go { color: #888888 } /* Generic.Output */ .highlight .gp { color: #555555 } /* Generic.Prompt */ .highlight .gs { font-weight: bold } /* Generic.Strong */ .highlight .gu { color: #666666 } /* Generic.Subheading */ .highlight .gt { color: #aa0000 } /* Generic.Traceback */ .highlight .kc { color: #008800; font-weight: bold } /* Keyword.Constant */ .highlight .kd { color: #008800; font-weight: bold } /* Keyword.Declaration */ .highlight .kn { color: #008800; font-weight: bold } /* Keyword.Namespace */ .highlight .kp { color: #008800 } /* Keyword.Pseudo */ .highlight .kr { color: #008800; font-weight: bold } /* Keyword.Reserved */ .highlight .kt { color: #888888; font-weight: bold } /* Keyword.Type */ .highlight .m { color: #0000DD; font-weight: bold } /* Literal.Number */ .highlight .s { color: #dd2200; background-color: #fff0f0 } /* Literal.String */ .highlight .na { color: #336699 } /* Name.Attribute */ .highlight .nb { color: #003388 } /* Name.Builtin */ .highlight .nc { color: #bb0066; font-weight: bold } /* Name.Class */ .highlight .no { color: #003366; font-weight: bold } /* Name.Constant */ .highlight .nd { color: #555555 } /* Name.Decorator */ .highlight .ne { color: #bb0066; font-weight: bold } /* Name.Exception */ .highlight .nf { color: #0066bb; font-weight: bold } /* Name.Function */ .highlight .nl { color: #336699; font-style: italic } /* Name.Label */ .highlight .nn { color: #bb0066; font-weight: bold } /* Name.Namespace */ .highlight .py { color: #336699; font-weight: bold } /* Name.Property */ .highlight .nt { color: #bb0066; font-weight: bold } /* Name.Tag */ .highlight .nv { color: #336699 } /* Name.Variable */ .highlight .ow { color: #008800 } /* Operator.Word */ .highlight .w { color: #bbbbbb } /* Text.Whitespace */ .highlight .mb { color: #0000DD; font-weight: bold } /* Literal.Number.Bin */ .highlight .mf { color: #0000DD; font-weight: bold } /* Literal.Number.Float */ .highlight .mh { color: #0000DD; font-weight: bold } /* Literal.Number.Hex */ .highlight .mi { color: #0000DD; font-weight: bold } /* Literal.Number.Integer */ .highlight .mo { color: #0000DD; font-weight: bold } /* Literal.Number.Oct */ .highlight .sa { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Affix */ .highlight .sb { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Backtick */ .highlight .sc { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Char */ .highlight .dl { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Delimiter */ .highlight .sd { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Doc */ .highlight .s2 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Double */ .highlight .se { color: #0044dd; background-color: #fff0f0 } /* Literal.String.Escape */ .highlight .sh { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Heredoc */ .highlight .si { color: #3333bb; background-color: #fff0f0 } /* Literal.String.Interpol */ .highlight .sx { color: #22bb22; background-color: #f0fff0 } /* Literal.String.Other */ .highlight .sr { color: #008800; background-color: #fff0ff } /* Literal.String.Regex */ .highlight .s1 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Single */ .highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */ }
# Copyright 2014 Hewlett-Packard Development Company, L.P.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
#
heat_template_version: 2013-05-23
description: Deploy Nagios
parameters:
  adm_web_passwd:
    type: string
    description: Password for initial admin user
    hidden: true
  external_network:
    type: string
    description: Network to attach floating ips to.
    default: ext-net
  flavor:
    type: string
    description: What flavor to use for the nagios server.
    default: m1.small
  image:
    type: string
    description: Image for Nagios.
    default: nagios
  key_name:
    type: string
    description: What Nova SSH key to use for the nagios server.
    default: default
  monitor_networks:
    type: json
    description: Neutron networks to monitor.
    default: []
  nova_os_auth_url:
    type: string
    default: ''
    description: URL for Keystone to access Nova.
  nova_os_password:
    type: string
    hidden: true
    description: password to present to nova_host_ip.
    default: ''
  nova_os_username:
    type: string
    description: username to present to nova_host_ip.
    default: ''
  nova_os_tenant_name:
    type: string
    description: tenant name to present to nova_host_ip.
    default: ''
  server_network:
    type: string
    description: Network id for server.
    default: default-net
resources:
  nagios_config:
    type: OS::Heat::StructuredConfig
    properties:
      config:
        nagios3:
          adm_web_passwd: { get_input: adm_web_passwd }
          os_auth_url: { get_input: nova_os_auth_url }
          os_password: { get_input: nova_os_password }
          os_username: { get_input: nova_os_username }
          os_tenant_name: { get_input: nova_os_tenant_name }
          monitor_networks: { get_input: monitor_networks }
        completion-signal: { get_input: deploy_signal_id }
  nagios_security_group:
    type: OS::Neutron::SecurityGroup
    properties:
      name: monitoring
      rules:
        - direction: ingress
          port_range_max: 22
          port_range_min: 22
          protocol: tcp
        - direction: ingress
          port_range_max: 80
          port_range_min: 80
          protocol: tcp
        - direction: ingress
          protocol: icmp
        - direction: egress
          protocol: tcp
        - direction: egress
          protocol: udp
        - direction: egress
          protocol: icmp
  nagios_net_port:
    type: OS::Neutron::Port
    properties:
      network_id: { get_param: server_network }
      security_groups: [ { get_resource: nagios_security_group } ]
  nagios_server:
    type: OS::Nova::Server
    properties:
      flavor: { get_param: flavor }
      image: { get_param: image }
      key_name: { get_param: key_name }
      user_data_format: SOFTWARE_CONFIG
      networks:
        - network: { get_param: server_network }
          port: { get_resource: nagios_net_port }
  nagios_floating_ip:
    type: OS::Neutron::FloatingIP
    properties:
      floating_network_id: { get_param: external_network }
      port_id: { get_resource: nagios_net_port }
  nagios_deploy:
    type: OS::Heat::StructuredDeployment
    properties:
      server: { get_resource: nagios_server }
      config: { get_resource: nagios_config }
      input_values:
        adm_web_passwd: { get_param: adm_web_passwd }
        nova_os_auth_url: { get_param: nova_os_auth_url }
        nova_os_password: { get_param: nova_os_password }
        nova_os_username: { get_param: nova_os_username }
        nova_os_tenant_name: { get_param: nova_os_tenant_name }
        monitor_networks: { get_param: monitor_networks }
outputs:
  nagios_address:
    description: Address of Nagios admin interface.
    value: { get_attr: [ nagios_floating_ip, floating_ip_address ] }