├── web ├── .idea │ ├── .name │ ├── vcs.xml │ ├── modules.xml │ ├── web.iml │ └── misc.xml ├── app │ ├── core │ │ ├── __init__.py │ │ ├── base.pyc │ │ └── __init__.pyc │ ├── templates.bak │ │ ├── 500.html │ │ ├── 404.html │ │ ├── resource │ │ │ ├── index.html │ │ │ ├── resources_index.html │ │ │ ├── service_index.html │ │ │ ├── server_add_iptype.html │ │ │ ├── server_add_supplier.html │ │ │ ├── server_add_power.html │ │ │ ├── server_add_raid.html │ │ │ ├── server_add_status.html │ │ │ ├── server_add_raidcardtype.html │ │ │ ├── server_add_manufacturers.html │ │ │ ├── server_add_managementcardtype.html │ │ │ ├── server_list_os.html │ │ │ ├── server_add_servertype.html │ │ │ ├── server_vmlist.html │ │ │ ├── server_add_cabinet.html │ │ │ └── server_list_hardware.html │ │ ├── dashboard.html │ │ └── public │ │ │ ├── dashboard.html │ │ │ ├── footer.html │ │ │ └── success.html │ ├── templates │ │ ├── 500.html │ │ ├── 404.html │ │ ├── resource │ │ │ ├── index.html │ │ │ ├── resources_index.html │ │ │ ├── service_index.html │ │ │ ├── server_add_iptype.html │ │ │ ├── server_add_supplier.html │ │ │ ├── server_add_power.html │ │ │ ├── server_add_raid.html │ │ │ ├── server_add_status.html │ │ │ ├── server_add_raidcardtype.html │ │ │ ├── server_add_manufacturers.html │ │ │ ├── server_add_managementcardtype.html │ │ │ ├── server_list_os.html │ │ │ ├── server_add_servertype.html │ │ │ ├── server_vmlist.html │ │ │ ├── server_add_cabinet.html │ │ │ └── server_list_hardware.html │ │ ├── dashboard.html │ │ ├── public │ │ │ ├── dashboard.html │ │ │ ├── footer.html │ │ │ └── success.html │ │ └── groups │ │ │ ├── server_group.html │ │ │ └── groups_zabbix.html │ ├── static │ │ ├── css │ │ │ ├── resources │ │ │ │ ├── service_add.css │ │ │ │ ├── ._service_add.css │ │ │ │ ├── .service_add.css.swp │ │ │ │ └── ._.service_add.css.swp │ │ │ ├── ._public.css │ │ │ ├── ._resources │ │ │ ├── ._bootstrap.css │ │ │ ├── ._datepicker.css │ │ │ ├── ._multi-select.css │ │ │ ├── ._sweetalert.css │ │ │ ├── ._zTreeStyle.css │ │ │ ├── ._bootstrap.css.map │ │ │ ├── ._bootstrap.min.css │ │ │ ├── ._autocomplete.min.css │ │ │ ├── ._bootstrap-theme.css │ │ │ ├── ._jquery.dataTables.css │ │ │ ├── ._bootstrap-theme.css.map │ │ │ ├── ._bootstrap-theme.min.css │ │ │ ├── ._bootstrap-treeview.css │ │ │ ├── ._dataTables.bootstrap.css │ │ │ ├── bootstrap-datetimepicker.min.css │ │ │ ├── ._bootstrap-datetimepicker.min.css │ │ │ ├── public.css │ │ │ ├── autocomplete.min.css │ │ │ ├── bootstrap-treeview.css │ │ │ └── multi-select.css │ │ ├── plugin │ │ │ └── multi-select │ │ │ │ ├── .gitignore │ │ │ │ ├── img │ │ │ │ └── switch.png │ │ │ │ ├── README.markdown │ │ │ │ ├── bower.json │ │ │ │ ├── multi-select.jquery.json │ │ │ │ ├── LICENSE.txt │ │ │ │ └── css │ │ │ │ └── multi-select.css │ │ ├── ._js │ │ ├── ._css │ │ ├── ._fonts │ │ ├── .DS_Store │ │ ├── ._images │ │ ├── ._.DS_Store │ │ ├── images │ │ │ ├── ._img │ │ │ ├── .DS_Store │ │ │ ├── ._logo.jpg │ │ │ ├── logo.jpg │ │ │ ├── logo1.jpg │ │ │ ├── logo1.png │ │ │ ├── switch.png │ │ │ ├── ._.DS_Store │ │ │ ├── ._logo1.jpg │ │ │ ├── ._logo1.png │ │ │ ├── ._switch.png │ │ │ ├── loading.jpg │ │ │ ├── sort_asc.png │ │ │ ├── ._sort_asc.png │ │ │ ├── ._sort_both.png │ │ │ ├── ._sort_desc.png │ │ │ ├── img │ │ │ │ ├── ._close.png │ │ │ │ ├── apiMenu.gif │ │ │ │ ├── apiMenu.png │ │ │ │ ├── chinese.png │ │ │ │ ├── close.png │ │ │ │ ├── english.png │ │ │ │ ├── loading.gif │ │ │ │ ├── ._apiMenu.gif │ │ │ │ ├── ._apiMenu.png │ │ │ │ ├── ._chinese.png │ │ │ │ ├── ._english.png │ │ │ │ ├── ._loading.gif │ │ │ │ ├── header-bg.png │ │ │ │ ├── lightbulb.png │ │ │ │ ├── line_conn.png │ │ │ │ ├── ._background.jpg │ │ │ │ ├── ._contact-bg.png │ │ │ │ ├── ._header-bg.png │ │ │ │ ├── ._lightbulb.png │ │ │ │ ├── ._line_conn.png │ │ │ │ ├── ._overlay_bg.png │ │ │ │ ├── background.jpg │ │ │ │ ├── contact-bg.png │ │ │ │ ├── overlay_bg.png │ │ │ │ ├── overlay_arrow.gif │ │ │ │ ├── overlay_arrow.png │ │ │ │ ├── zTreeStandard.gif │ │ │ │ ├── zTreeStandard.png │ │ │ │ ├── ._overlay_arrow.gif │ │ │ │ ├── ._overlay_arrow.png │ │ │ │ ├── ._zTreeStandard.gif │ │ │ │ ├── ._zTreeStandard.png │ │ │ │ ├── overlay_close_IE6.gif │ │ │ │ └── ._overlay_close_IE6.gif │ │ │ ├── logo1.jpg.bak │ │ │ ├── logo1.png.bak │ │ │ ├── sort_both.png │ │ │ ├── sort_desc.png │ │ │ ├── sort_asc_disabled.png │ │ │ ├── sort_desc_disabled.png │ │ │ ├── ._sort_asc_disabled.png │ │ │ └── ._sort_desc_disabled.png │ │ ├── js │ │ │ ├── ._npm.js │ │ │ ├── ._bootstrap.js │ │ │ ├── ._bootstrap.min.js │ │ │ ├── ._sweetalert.min.js │ │ │ ├── ._autocomplete.min.js │ │ │ ├── ._jquery-1.8.3.min.js │ │ │ ├── ._jquery-1.9.1.min.js │ │ │ ├── ._bootstrap-treeview.js │ │ │ ├── ._html5shiv.3.7.2.min.js │ │ │ ├── ._jquery.dataTables.js │ │ │ ├── ._jquery.multi-select.js │ │ │ ├── ._jquery.validate.min.js │ │ │ ├── ._respond.1.4.2.min.js │ │ │ ├── ._dataTables.bootstrap.js │ │ │ ├── ._jquery.dataTables.min.js │ │ │ ├── ._jquery.ztree.core-3.5.js │ │ │ ├── ._bootstrap-datetimepicker.js │ │ │ ├── ._jquery.ztree.excheck-3.5.js │ │ │ ├── ._bootstrap-datetimepicker.fr.js │ │ │ ├── ._bootstrap-datetimepicker.min.js │ │ │ ├── ._bootstrap-datetimepicker.zh-CN.js │ │ │ ├── npm.js │ │ │ ├── bootstrap-datetimepicker.zh-CN.js │ │ │ ├── bootstrap-datetimepicker.fr.js │ │ │ ├── autocomplete.min.js │ │ │ └── html5shiv.3.7.2.min.js │ │ ├── ._jquery-ui-1.11.4 │ │ ├── ._bootstrap-datetimepicker │ │ ├── jquery-ui-1.11.4 │ │ │ ├── ._external │ │ │ ├── ._images │ │ │ ├── ._index.html │ │ │ ├── ._jquery-ui.css │ │ │ ├── ._jquery-ui.js │ │ │ ├── external │ │ │ │ ├── ._jquery │ │ │ │ └── jquery │ │ │ │ │ └── ._jquery.js │ │ │ ├── ._jquery-ui.min.css │ │ │ ├── ._jquery-ui.min.js │ │ │ ├── ._jquery-ui.theme.css │ │ │ ├── ._jquery-ui.structure.css │ │ │ ├── ._jquery-ui.theme.min.css │ │ │ ├── ._jquery-ui.structure.min.css │ │ │ └── images │ │ │ │ ├── ui-icons_222222_256x240.png │ │ │ │ ├── ui-icons_228ef1_256x240.png │ │ │ │ ├── ui-icons_ef8c08_256x240.png │ │ │ │ ├── ui-icons_ffd27a_256x240.png │ │ │ │ ├── ui-icons_ffffff_256x240.png │ │ │ │ ├── ._ui-icons_222222_256x240.png │ │ │ │ ├── ._ui-icons_228ef1_256x240.png │ │ │ │ ├── ._ui-icons_ef8c08_256x240.png │ │ │ │ ├── ._ui-icons_ffd27a_256x240.png │ │ │ │ ├── ._ui-icons_ffffff_256x240.png │ │ │ │ ├── ._ui-bg_flat_10_000000_40x100.png │ │ │ │ ├── ._ui-bg_glass_65_ffffff_1x400.png │ │ │ │ ├── ui-bg_flat_10_000000_40x100.png │ │ │ │ ├── ui-bg_glass_100_f6f6f6_1x400.png │ │ │ │ ├── ui-bg_glass_100_fdf5ce_1x400.png │ │ │ │ ├── ui-bg_glass_65_ffffff_1x400.png │ │ │ │ ├── ._ui-bg_glass_100_f6f6f6_1x400.png │ │ │ │ ├── ._ui-bg_glass_100_fdf5ce_1x400.png │ │ │ │ ├── ui-bg_gloss-wave_35_f6a828_500x100.png │ │ │ │ ├── ._ui-bg_gloss-wave_35_f6a828_500x100.png │ │ │ │ ├── ui-bg_highlight-soft_75_ffe45c_1x100.png │ │ │ │ ├── ._ui-bg_diagonals-thick_18_b81900_40x40.png │ │ │ │ ├── ._ui-bg_diagonals-thick_20_666666_40x40.png │ │ │ │ ├── ._ui-bg_highlight-soft_100_eeeeee_1x100.png │ │ │ │ ├── ._ui-bg_highlight-soft_75_ffe45c_1x100.png │ │ │ │ ├── ui-bg_diagonals-thick_18_b81900_40x40.png │ │ │ │ ├── ui-bg_diagonals-thick_20_666666_40x40.png │ │ │ │ └── ui-bg_highlight-soft_100_eeeeee_1x100.png │ │ ├── fonts │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ ├── ._glyphicons-halflings-regular.eot │ │ │ ├── ._glyphicons-halflings-regular.svg │ │ │ ├── ._glyphicons-halflings-regular.ttf │ │ │ ├── ._glyphicons-halflings-regular.woff │ │ │ ├── ._glyphicons-halflings-regular.woff2 │ │ │ └── glyphicons-halflings-regular.woff2 │ │ └── bootstrap-tagsinput │ │ │ └── bootstrap-tagsinput.css │ ├── ._static │ ├── models.pyc │ ├── __init__.pyc │ ├── main │ │ ├── views.pyc │ │ ├── errors.pyc │ │ ├── monitor.pyc │ │ ├── zabbix.pyc │ │ ├── __init__.pyc │ │ ├── resource.pyc │ │ ├── __init__.py │ │ ├── errors.py │ │ ├── zabbix.py │ │ └── views.py │ ├── common │ │ ├── tree.pyc │ │ ├── .tree.py.swp │ │ ├── __init__.pyc │ │ ├── monitor.pyc │ │ ├── zabbix.pyc │ │ ├── performance.pyc │ │ ├── __init__.py │ │ ├── get_tree_class.py │ │ ├── tree.py │ │ ├── performance.py │ │ ├── monitor.py │ │ └── get_tree.py │ ├── modules │ │ ├── idc.pyc │ │ ├── raid.pyc │ │ ├── user.pyc │ │ ├── cabinet.pyc │ │ ├── ipinfo.pyc │ │ ├── power.pyc │ │ ├── product.pyc │ │ ├── server.pyc │ │ ├── status.pyc │ │ ├── switch.pyc │ │ ├── raidtype.pyc │ │ ├── supplier.pyc │ │ ├── department.pyc │ │ ├── servertype.pyc │ │ ├── manufacturers.pyc │ │ ├── managementcardtype.pyc │ │ ├── raid.py │ │ ├── idc.py │ │ ├── power.py │ │ ├── status.py │ │ ├── raidtype.py │ │ ├── supplier.py │ │ ├── manufacturers.py │ │ ├── user.py │ │ ├── managementcardtype.py │ │ ├── servertype.py │ │ ├── cabinet.py │ │ ├── server.py │ │ ├── product.py │ │ ├── department.py │ │ ├── switch.py │ │ └── ipinfo.py │ ├── utils │ │ ├── __init__.pyc │ │ └── __init__.py │ ├── templates.2016-03-08.tar.gz │ ├── __init__.py │ └── tree.py ├── migrations │ ├── README │ ├── env.pyc │ ├── versions │ │ ├── 05994d747975_.pyc │ │ ├── 0f18cf4ae43a_.pyc │ │ ├── 10f5c6fec536_.pyc │ │ ├── 155783ce6964_.pyc │ │ ├── 2294cb4ebe5f_.pyc │ │ ├── 23b57cb458b1_.pyc │ │ ├── 34b85bb91295_.pyc │ │ ├── 3c458ab7ad8c_.pyc │ │ ├── 3cd77cb465be_.pyc │ │ ├── 3f20a8a72d0a_.pyc │ │ ├── 447d1743e0de_.pyc │ │ ├── 7de1ffb7774f_.pyc │ │ ├── 968c5bad1e86_.pyc │ │ ├── a290aa576ceb_.pyc │ │ ├── a7642d8ec071_.pyc │ │ ├── d62dd02d6e94_.pyc │ │ ├── dd85fa7bd6cf_.pyc │ │ ├── e226c50ee645_.pyc │ │ ├── e8ed4b55f520_.pyc │ │ ├── fb6e7286d572_.pyc │ │ ├── 05994d747975_.py │ │ ├── 447d1743e0de_.py │ │ ├── 3f20a8a72d0a_.py │ │ ├── a7642d8ec071_.py │ │ ├── 3cd77cb465be_.py │ │ ├── a290aa576ceb_.py │ │ ├── 34b85bb91295_.py │ │ ├── fb6e7286d572_.py │ │ ├── 968c5bad1e86_.py │ │ ├── 10f5c6fec536_.py │ │ ├── 23b57cb458b1_.py │ │ ├── 3c458ab7ad8c_.py │ │ ├── d62dd02d6e94_.py │ │ ├── dd85fa7bd6cf_.py │ │ ├── 7de1ffb7774f_.py │ │ ├── e226c50ee645_.py │ │ ├── 155783ce6964_.py │ │ ├── e8ed4b55f520_.py │ │ └── 2294cb4ebe5f_.py │ ├── script.py.mako │ └── alembic.ini ├── config.pyc ├── manage.py └── config.py ├── README.md ├── bootstrapptime ├── bootstrap-datetimepicker.zh-CN.js └── index.txt ├── json笔记.txt ├── sock.py └── monitor.py /web/.idea/.name: -------------------------------------------------------------------------------- 1 | web -------------------------------------------------------------------------------- /web/app/core/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /web/app/templates.bak/500.html: -------------------------------------------------------------------------------- 1 | 500 2 | -------------------------------------------------------------------------------- /web/app/templates/500.html: -------------------------------------------------------------------------------- 1 | 500 2 | -------------------------------------------------------------------------------- /web/app/templates/404.html: -------------------------------------------------------------------------------- 1 | 404404404404 2 | -------------------------------------------------------------------------------- /web/app/static/css/resources/service_add.css: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /web/app/templates.bak/404.html: -------------------------------------------------------------------------------- 1 | 404404404404 2 | -------------------------------------------------------------------------------- /web/app/static/plugin/multi-select/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store -------------------------------------------------------------------------------- /web/migrations/README: -------------------------------------------------------------------------------- 1 | Generic single-database configuration. -------------------------------------------------------------------------------- /web/app/templates/resource/index.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} -------------------------------------------------------------------------------- /web/app/templates.bak/resource/index.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | -------------------------------------------------------------------------------- /web/config.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/config.pyc -------------------------------------------------------------------------------- /web/app/._static: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/._static -------------------------------------------------------------------------------- /web/app/models.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/models.pyc -------------------------------------------------------------------------------- /web/app/static/._js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/._js -------------------------------------------------------------------------------- /web/app/__init__.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/__init__.pyc -------------------------------------------------------------------------------- /web/app/core/base.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/core/base.pyc -------------------------------------------------------------------------------- /web/app/main/views.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/main/views.pyc -------------------------------------------------------------------------------- /web/app/static/._css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/._css -------------------------------------------------------------------------------- /web/app/static/._fonts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/._fonts -------------------------------------------------------------------------------- /web/migrations/env.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/env.pyc -------------------------------------------------------------------------------- /web/app/common/tree.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/common/tree.pyc -------------------------------------------------------------------------------- /web/app/main/errors.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/main/errors.pyc -------------------------------------------------------------------------------- /web/app/main/monitor.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/main/monitor.pyc -------------------------------------------------------------------------------- /web/app/main/zabbix.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/main/zabbix.pyc -------------------------------------------------------------------------------- /web/app/modules/idc.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/idc.pyc -------------------------------------------------------------------------------- /web/app/modules/raid.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/raid.pyc -------------------------------------------------------------------------------- /web/app/modules/user.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/user.pyc -------------------------------------------------------------------------------- /web/app/static/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/.DS_Store -------------------------------------------------------------------------------- /web/app/static/._images: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/._images -------------------------------------------------------------------------------- /web/app/common/.tree.py.swp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/common/.tree.py.swp -------------------------------------------------------------------------------- /web/app/common/__init__.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/common/__init__.pyc -------------------------------------------------------------------------------- /web/app/common/monitor.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/common/monitor.pyc -------------------------------------------------------------------------------- /web/app/common/zabbix.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/common/zabbix.pyc -------------------------------------------------------------------------------- /web/app/core/__init__.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/core/__init__.pyc -------------------------------------------------------------------------------- /web/app/main/__init__.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/main/__init__.pyc -------------------------------------------------------------------------------- /web/app/main/resource.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/main/resource.pyc -------------------------------------------------------------------------------- /web/app/modules/cabinet.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/cabinet.pyc -------------------------------------------------------------------------------- /web/app/modules/ipinfo.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/ipinfo.pyc -------------------------------------------------------------------------------- /web/app/modules/power.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/power.pyc -------------------------------------------------------------------------------- /web/app/modules/product.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/product.pyc -------------------------------------------------------------------------------- /web/app/modules/server.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/server.pyc -------------------------------------------------------------------------------- /web/app/modules/status.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/status.pyc -------------------------------------------------------------------------------- /web/app/modules/switch.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/switch.pyc -------------------------------------------------------------------------------- /web/app/static/._.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/._.DS_Store -------------------------------------------------------------------------------- /web/app/static/images/._img: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/._img -------------------------------------------------------------------------------- /web/app/static/js/._npm.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._npm.js -------------------------------------------------------------------------------- /web/app/utils/__init__.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/utils/__init__.pyc -------------------------------------------------------------------------------- /web/app/modules/raidtype.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/raidtype.pyc -------------------------------------------------------------------------------- /web/app/modules/supplier.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/supplier.pyc -------------------------------------------------------------------------------- /web/app/common/performance.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/common/performance.pyc -------------------------------------------------------------------------------- /web/app/modules/department.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/department.pyc -------------------------------------------------------------------------------- /web/app/modules/servertype.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/servertype.pyc -------------------------------------------------------------------------------- /web/app/static/css/._public.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._public.css -------------------------------------------------------------------------------- /web/app/static/css/._resources: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._resources -------------------------------------------------------------------------------- /web/app/static/images/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/.DS_Store -------------------------------------------------------------------------------- /web/app/static/images/._logo.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/._logo.jpg -------------------------------------------------------------------------------- /web/app/static/images/logo.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/logo.jpg -------------------------------------------------------------------------------- /web/app/static/images/logo1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/logo1.jpg -------------------------------------------------------------------------------- /web/app/static/images/logo1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/logo1.png -------------------------------------------------------------------------------- /web/app/static/images/switch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/switch.png -------------------------------------------------------------------------------- /web/app/static/js/._bootstrap.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._bootstrap.js -------------------------------------------------------------------------------- /web/app/modules/manufacturers.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/manufacturers.pyc -------------------------------------------------------------------------------- /web/app/static/._jquery-ui-1.11.4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/._jquery-ui-1.11.4 -------------------------------------------------------------------------------- /web/app/static/css/._bootstrap.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._bootstrap.css -------------------------------------------------------------------------------- /web/app/static/images/._.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/._.DS_Store -------------------------------------------------------------------------------- /web/app/static/images/._logo1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/._logo1.jpg -------------------------------------------------------------------------------- /web/app/static/images/._logo1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/._logo1.png -------------------------------------------------------------------------------- /web/app/static/images/._switch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/._switch.png -------------------------------------------------------------------------------- /web/app/static/images/loading.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/loading.jpg -------------------------------------------------------------------------------- /web/app/static/images/sort_asc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/sort_asc.png -------------------------------------------------------------------------------- /web/app/templates.bak/dashboard.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | 3 | {% block sidebar %} 4 | {% endblock %} 5 | -------------------------------------------------------------------------------- /web/app/templates/dashboard.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | 3 | {% block sidebar %} 4 | {% endblock %} 5 | -------------------------------------------------------------------------------- /web/app/static/css/._datepicker.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._datepicker.css -------------------------------------------------------------------------------- /web/app/static/css/._multi-select.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._multi-select.css -------------------------------------------------------------------------------- /web/app/static/css/._sweetalert.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._sweetalert.css -------------------------------------------------------------------------------- /web/app/static/css/._zTreeStyle.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._zTreeStyle.css -------------------------------------------------------------------------------- /web/app/static/images/._sort_asc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/._sort_asc.png -------------------------------------------------------------------------------- /web/app/static/images/._sort_both.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/._sort_both.png -------------------------------------------------------------------------------- /web/app/static/images/._sort_desc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/._sort_desc.png -------------------------------------------------------------------------------- /web/app/static/images/img/._close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._close.png -------------------------------------------------------------------------------- /web/app/static/images/img/apiMenu.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/apiMenu.gif -------------------------------------------------------------------------------- /web/app/static/images/img/apiMenu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/apiMenu.png -------------------------------------------------------------------------------- /web/app/static/images/img/chinese.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/chinese.png -------------------------------------------------------------------------------- /web/app/static/images/img/close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/close.png -------------------------------------------------------------------------------- /web/app/static/images/img/english.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/english.png -------------------------------------------------------------------------------- /web/app/static/images/img/loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/loading.gif -------------------------------------------------------------------------------- /web/app/static/images/logo1.jpg.bak: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/logo1.jpg.bak -------------------------------------------------------------------------------- /web/app/static/images/logo1.png.bak: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/logo1.png.bak -------------------------------------------------------------------------------- /web/app/static/images/sort_both.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/sort_both.png -------------------------------------------------------------------------------- /web/app/static/images/sort_desc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/sort_desc.png -------------------------------------------------------------------------------- /web/app/static/js/._bootstrap.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._bootstrap.min.js -------------------------------------------------------------------------------- /web/app/static/js/._sweetalert.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._sweetalert.min.js -------------------------------------------------------------------------------- /web/app/templates.2016-03-08.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/templates.2016-03-08.tar.gz -------------------------------------------------------------------------------- /web/app/modules/managementcardtype.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/modules/managementcardtype.pyc -------------------------------------------------------------------------------- /web/app/static/css/._bootstrap.css.map: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._bootstrap.css.map -------------------------------------------------------------------------------- /web/app/static/css/._bootstrap.min.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._bootstrap.min.css -------------------------------------------------------------------------------- /web/app/static/images/img/._apiMenu.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._apiMenu.gif -------------------------------------------------------------------------------- /web/app/static/images/img/._apiMenu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._apiMenu.png -------------------------------------------------------------------------------- /web/app/static/images/img/._chinese.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._chinese.png -------------------------------------------------------------------------------- /web/app/static/images/img/._english.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._english.png -------------------------------------------------------------------------------- /web/app/static/images/img/._loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._loading.gif -------------------------------------------------------------------------------- /web/app/static/images/img/header-bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/header-bg.png -------------------------------------------------------------------------------- /web/app/static/images/img/lightbulb.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/lightbulb.png -------------------------------------------------------------------------------- /web/app/static/images/img/line_conn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/line_conn.png -------------------------------------------------------------------------------- /web/app/static/js/._autocomplete.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._autocomplete.min.js -------------------------------------------------------------------------------- /web/app/static/js/._jquery-1.8.3.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._jquery-1.8.3.min.js -------------------------------------------------------------------------------- /web/app/static/js/._jquery-1.9.1.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._jquery-1.9.1.min.js -------------------------------------------------------------------------------- /web/app/static/._bootstrap-datetimepicker: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/._bootstrap-datetimepicker -------------------------------------------------------------------------------- /web/app/static/css/._autocomplete.min.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._autocomplete.min.css -------------------------------------------------------------------------------- /web/app/static/css/._bootstrap-theme.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._bootstrap-theme.css -------------------------------------------------------------------------------- /web/app/static/css/._jquery.dataTables.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._jquery.dataTables.css -------------------------------------------------------------------------------- /web/app/static/images/img/._background.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._background.jpg -------------------------------------------------------------------------------- /web/app/static/images/img/._contact-bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._contact-bg.png -------------------------------------------------------------------------------- /web/app/static/images/img/._header-bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._header-bg.png -------------------------------------------------------------------------------- /web/app/static/images/img/._lightbulb.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._lightbulb.png -------------------------------------------------------------------------------- /web/app/static/images/img/._line_conn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._line_conn.png -------------------------------------------------------------------------------- /web/app/static/images/img/._overlay_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._overlay_bg.png -------------------------------------------------------------------------------- /web/app/static/images/img/background.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/background.jpg -------------------------------------------------------------------------------- /web/app/static/images/img/contact-bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/contact-bg.png -------------------------------------------------------------------------------- /web/app/static/images/img/overlay_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/overlay_bg.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/._external: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/._external -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/._images: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/._images -------------------------------------------------------------------------------- /web/app/static/js/._bootstrap-treeview.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._bootstrap-treeview.js -------------------------------------------------------------------------------- /web/app/static/js/._html5shiv.3.7.2.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._html5shiv.3.7.2.min.js -------------------------------------------------------------------------------- /web/app/static/js/._jquery.dataTables.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._jquery.dataTables.js -------------------------------------------------------------------------------- /web/app/static/js/._jquery.multi-select.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._jquery.multi-select.js -------------------------------------------------------------------------------- /web/app/static/js/._jquery.validate.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._jquery.validate.min.js -------------------------------------------------------------------------------- /web/app/static/js/._respond.1.4.2.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._respond.1.4.2.min.js -------------------------------------------------------------------------------- /web/migrations/versions/05994d747975_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/05994d747975_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/0f18cf4ae43a_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/0f18cf4ae43a_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/10f5c6fec536_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/10f5c6fec536_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/155783ce6964_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/155783ce6964_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/2294cb4ebe5f_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/2294cb4ebe5f_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/23b57cb458b1_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/23b57cb458b1_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/34b85bb91295_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/34b85bb91295_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/3c458ab7ad8c_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/3c458ab7ad8c_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/3cd77cb465be_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/3cd77cb465be_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/3f20a8a72d0a_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/3f20a8a72d0a_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/447d1743e0de_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/447d1743e0de_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/7de1ffb7774f_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/7de1ffb7774f_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/968c5bad1e86_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/968c5bad1e86_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/a290aa576ceb_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/a290aa576ceb_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/a7642d8ec071_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/a7642d8ec071_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/d62dd02d6e94_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/d62dd02d6e94_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/dd85fa7bd6cf_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/dd85fa7bd6cf_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/e226c50ee645_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/e226c50ee645_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/e8ed4b55f520_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/e8ed4b55f520_.pyc -------------------------------------------------------------------------------- /web/migrations/versions/fb6e7286d572_.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/migrations/versions/fb6e7286d572_.pyc -------------------------------------------------------------------------------- /web/app/static/css/._bootstrap-theme.css.map: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._bootstrap-theme.css.map -------------------------------------------------------------------------------- /web/app/static/css/._bootstrap-theme.min.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._bootstrap-theme.min.css -------------------------------------------------------------------------------- /web/app/static/css/._bootstrap-treeview.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._bootstrap-treeview.css -------------------------------------------------------------------------------- /web/app/static/images/img/overlay_arrow.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/overlay_arrow.gif -------------------------------------------------------------------------------- /web/app/static/images/img/overlay_arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/overlay_arrow.png -------------------------------------------------------------------------------- /web/app/static/images/img/zTreeStandard.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/zTreeStandard.gif -------------------------------------------------------------------------------- /web/app/static/images/img/zTreeStandard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/zTreeStandard.png -------------------------------------------------------------------------------- /web/app/static/images/sort_asc_disabled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/sort_asc_disabled.png -------------------------------------------------------------------------------- /web/app/static/images/sort_desc_disabled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/sort_desc_disabled.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/._index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/._index.html -------------------------------------------------------------------------------- /web/app/static/js/._dataTables.bootstrap.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._dataTables.bootstrap.js -------------------------------------------------------------------------------- /web/app/static/js/._jquery.dataTables.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._jquery.dataTables.min.js -------------------------------------------------------------------------------- /web/app/static/js/._jquery.ztree.core-3.5.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._jquery.ztree.core-3.5.js -------------------------------------------------------------------------------- /web/app/static/css/._dataTables.bootstrap.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._dataTables.bootstrap.css -------------------------------------------------------------------------------- /web/app/static/css/resources/._service_add.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/resources/._service_add.css -------------------------------------------------------------------------------- /web/app/static/images/._sort_asc_disabled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/._sort_asc_disabled.png -------------------------------------------------------------------------------- /web/app/static/images/._sort_desc_disabled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/._sort_desc_disabled.png -------------------------------------------------------------------------------- /web/app/static/images/img/._overlay_arrow.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._overlay_arrow.gif -------------------------------------------------------------------------------- /web/app/static/images/img/._overlay_arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._overlay_arrow.png -------------------------------------------------------------------------------- /web/app/static/images/img/._zTreeStandard.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._zTreeStandard.gif -------------------------------------------------------------------------------- /web/app/static/images/img/._zTreeStandard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._zTreeStandard.png -------------------------------------------------------------------------------- /web/app/static/images/img/overlay_close_IE6.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/overlay_close_IE6.gif -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/._jquery-ui.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/._jquery-ui.css -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/._jquery-ui.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/._jquery-ui.js -------------------------------------------------------------------------------- /web/app/static/js/._bootstrap-datetimepicker.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._bootstrap-datetimepicker.js -------------------------------------------------------------------------------- /web/app/static/js/._jquery.ztree.excheck-3.5.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._jquery.ztree.excheck-3.5.js -------------------------------------------------------------------------------- /web/app/static/css/resources/.service_add.css.swp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/resources/.service_add.css.swp -------------------------------------------------------------------------------- /web/app/static/images/img/._overlay_close_IE6.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/images/img/._overlay_close_IE6.gif -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/external/._jquery: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/external/._jquery -------------------------------------------------------------------------------- /web/app/static/plugin/multi-select/img/switch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/plugin/multi-select/img/switch.png -------------------------------------------------------------------------------- /web/app/static/css/bootstrap-datetimepicker.min.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/bootstrap-datetimepicker.min.css -------------------------------------------------------------------------------- /web/app/static/css/resources/._.service_add.css.swp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/resources/._.service_add.css.swp -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/._jquery-ui.min.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/._jquery-ui.min.css -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/._jquery-ui.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/._jquery-ui.min.js -------------------------------------------------------------------------------- /web/app/static/js/._bootstrap-datetimepicker.fr.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._bootstrap-datetimepicker.fr.js -------------------------------------------------------------------------------- /web/app/static/js/._bootstrap-datetimepicker.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._bootstrap-datetimepicker.min.js -------------------------------------------------------------------------------- /web/app/static/css/._bootstrap-datetimepicker.min.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/css/._bootstrap-datetimepicker.min.css -------------------------------------------------------------------------------- /web/app/static/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /web/app/static/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /web/app/static/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/._jquery-ui.theme.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/._jquery-ui.theme.css -------------------------------------------------------------------------------- /web/app/static/js/._bootstrap-datetimepicker.zh-CN.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/js/._bootstrap-datetimepicker.zh-CN.js -------------------------------------------------------------------------------- /web/app/static/fonts/._glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/fonts/._glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /web/app/static/fonts/._glyphicons-halflings-regular.svg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/fonts/._glyphicons-halflings-regular.svg -------------------------------------------------------------------------------- /web/app/static/fonts/._glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/fonts/._glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /web/app/static/fonts/._glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/fonts/._glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /web/app/static/fonts/._glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/fonts/._glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /web/app/static/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/._jquery-ui.structure.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/._jquery-ui.structure.css -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/._jquery-ui.theme.min.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/._jquery-ui.theme.min.css -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/external/jquery/._jquery.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/external/jquery/._jquery.js -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/._jquery-ui.structure.min.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/._jquery-ui.structure.min.css -------------------------------------------------------------------------------- /web/app/templates/public/dashboard.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 |
3 | 4 |
5 | 6 | {% include "public/footer.html" %} 7 | -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-icons_222222_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-icons_222222_256x240.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-icons_228ef1_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-icons_228ef1_256x240.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-icons_ef8c08_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-icons_ef8c08_256x240.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-icons_ffd27a_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-icons_ffd27a_256x240.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-icons_ffffff_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-icons_ffffff_256x240.png -------------------------------------------------------------------------------- /web/app/templates.bak/public/dashboard.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 |
3 | 4 |
5 | 6 | {% include "public/footer.html" %} 7 | -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-icons_222222_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-icons_222222_256x240.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-icons_228ef1_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-icons_228ef1_256x240.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-icons_ef8c08_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-icons_ef8c08_256x240.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-icons_ffd27a_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-icons_ffd27a_256x240.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-icons_ffffff_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-icons_ffffff_256x240.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-bg_flat_10_000000_40x100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-bg_flat_10_000000_40x100.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-bg_glass_65_ffffff_1x400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-bg_glass_65_ffffff_1x400.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-bg_flat_10_000000_40x100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-bg_flat_10_000000_40x100.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-bg_glass_100_f6f6f6_1x400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-bg_glass_100_f6f6f6_1x400.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-bg_glass_100_fdf5ce_1x400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-bg_glass_100_fdf5ce_1x400.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-bg_glass_65_ffffff_1x400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-bg_glass_65_ffffff_1x400.png -------------------------------------------------------------------------------- /web/.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-bg_glass_100_f6f6f6_1x400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-bg_glass_100_f6f6f6_1x400.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-bg_glass_100_fdf5ce_1x400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-bg_glass_100_fdf5ce_1x400.png -------------------------------------------------------------------------------- /web/app/main/__init__.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # coding:utf-8 3 | from flask import Blueprint 4 | 5 | main = Blueprint('main', __name__) 6 | from . import views, errors, resource, monitor, zabbix 7 | -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-bg_gloss-wave_35_f6a828_500x100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-bg_gloss-wave_35_f6a828_500x100.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-bg_gloss-wave_35_f6a828_500x100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-bg_gloss-wave_35_f6a828_500x100.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-bg_highlight-soft_75_ffe45c_1x100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-bg_highlight-soft_75_ffe45c_1x100.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-bg_diagonals-thick_18_b81900_40x40.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-bg_diagonals-thick_18_b81900_40x40.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-bg_diagonals-thick_20_666666_40x40.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-bg_diagonals-thick_20_666666_40x40.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-bg_highlight-soft_100_eeeeee_1x100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-bg_highlight-soft_100_eeeeee_1x100.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/._ui-bg_highlight-soft_75_ffe45c_1x100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/._ui-bg_highlight-soft_75_ffe45c_1x100.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-bg_diagonals-thick_18_b81900_40x40.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-bg_diagonals-thick_18_b81900_40x40.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-bg_diagonals-thick_20_666666_40x40.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-bg_diagonals-thick_20_666666_40x40.png -------------------------------------------------------------------------------- /web/app/static/jquery-ui-1.11.4/images/ui-bg_highlight-soft_100_eeeeee_1x100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xiaoluoge11/Devops/HEAD/web/app/static/jquery-ui-1.11.4/images/ui-bg_highlight-soft_100_eeeeee_1x100.png -------------------------------------------------------------------------------- /web/app/templates/resource/resources_index.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 | {% include "public/cmdb_left.html" %} 3 |
4 | 5 |
6 | 7 | {% include "public/footer.html" %} 8 | -------------------------------------------------------------------------------- /web/app/templates.bak/resource/resources_index.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 | {% include "public/cmdb_left.html" %} 3 |
4 | 5 |
6 | 7 | {% include "public/footer.html" %} 8 | -------------------------------------------------------------------------------- /web/.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /web/app/static/plugin/multi-select/README.markdown: -------------------------------------------------------------------------------- 1 | # jquery.multi-select.js 2 | 3 | ### Usage and demos 4 | [http://loudev.com](http://loudev.com "jquery.multi-select.js") 5 | 6 | 7 | ### License 8 | Multi-select is released under the [MIT License](http://opensource.org/licenses/MIT "MIT License"). 9 | -------------------------------------------------------------------------------- /web/app/templates.bak/public/footer.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /web/app/templates/public/footer.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /web/app/main/errors.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # coding:utf-8 3 | 4 | from flask import render_template 5 | from . import main 6 | 7 | @main.app_errorhandler(404) 8 | def page_not_found(e): 9 | return render_template('404.html'), 404 10 | 11 | @main.app_errorhandler(500) 12 | def internal_server_error(e): 13 | return render_template('500.html'), 500 14 | -------------------------------------------------------------------------------- /web/app/static/plugin/multi-select/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "multiselect", 3 | "version": "0.9.12", 4 | "description" : "A user-friendlier drop-in replacement for the standard select with multiple attribute activated.", 5 | "license" : "WTFPL", 6 | "main": [ 7 | "./css/multi-select.css", 8 | "./img/switch.png", 9 | "./js/jquery.multi-select.js" 10 | ], 11 | "dependencies" : { 12 | "jquery" : ">= 1.7.1" 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Devops 2 | 主要是基于python的一些脚本互相交流学习
3 | 开源项目CMDB加以改进,以API接口的方式进行调用,代码持续更新中
4 | CMDB运维平台已初步完成,基于api接口调用,模仿zabbix 的API调用方式
5 | 所有的操作都记忆api与模块方便调用
6 | 脚本定时收集硬件更新到前端已完成
7 | CMDB开发已完成。实现半自动化的方式,一些人为信息需要人工通过API方式录入
8 | 硬件资产信息每隔10分钟采集一次更新到数据库并展示
9 | 10 | ##zabbix; 11 | 已完成CMDB同步主机到zabbix
12 | zabbix批量模板绑定
13 | zabbix 添加维护周期
14 | zabbix 获取历史数据
15 | 16 | ##graphite; 17 | 根据业务自定义出图,通业务再一组图形前端展示
18 | -------------------------------------------------------------------------------- /web/migrations/script.py.mako: -------------------------------------------------------------------------------- 1 | """${message} 2 | 3 | Revision ID: ${up_revision} 4 | Revises: ${down_revision} 5 | Create Date: ${create_date} 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = ${repr(up_revision)} 11 | down_revision = ${repr(down_revision)} 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | ${imports if imports else ""} 16 | 17 | def upgrade(): 18 | ${upgrades if upgrades else "pass"} 19 | 20 | 21 | def downgrade(): 22 | ${downgrades if downgrades else "pass"} 23 | -------------------------------------------------------------------------------- /web/app/static/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /web/app/__init__.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # coding:utf-8 3 | from flask import Flask 4 | from flask.ext.sqlalchemy import SQLAlchemy 5 | from config import config 6 | db = SQLAlchemy() 7 | 8 | def create_app(config_name): 9 | app = Flask(__name__) # 实例化flask 10 | app.config.from_object(config[config_name]) # 给flask加载配置文件 11 | config[config_name].init_app(app) # 初始化 12 | db.init_app(app) # 初始化数据库服务 13 | # 注册蓝图 14 | from .main import main as main_blugprint 15 | app.register_blueprint(main_blugprint) 16 | return app 17 | -------------------------------------------------------------------------------- /web/app/common/__init__.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | import requests 3 | import json 4 | 5 | def api_action(action, params={}): 6 | url = "http://127.0.0.1:5000/api" 7 | headers = {"Content-type": "application/json"} 8 | data = { 9 | "jsonrpc": 2.0, 10 | "method" : action, 11 | "id": 1, 12 | "auth": None, 13 | "params": params 14 | } 15 | r = requests.post(url, headers=headers ,json=json.dumps(data)) 16 | if str(r.status_code) == "200": 17 | ret = json.loads(r.content) 18 | if ret.has_key('result'): 19 | return ret['result'] 20 | else: 21 | return ret['error'] 22 | -------------------------------------------------------------------------------- /web/app/static/css/public.css: -------------------------------------------------------------------------------- 1 | .error{color:red;text-align:left !important;} 2 | img{outline: none;} 3 | 4 | 5 | .scroll_head { 6 | position: relative; 7 | margin-top:0; 8 | 9 | } 10 | 11 | #tab_box{ 12 | font-size: 12px; 13 | width:100%; 14 | overflow:hidden; 15 | margin-top:10px; 16 | overflow-y:scroll; 17 | box-sizing:border-box; 18 | border: 1px solid #D5D5D5; 19 | border-radius: 4px; 20 | padding:2px; 21 | } 22 | 23 | .right_content{ 24 | float:left; 25 | width:83%; 26 | font-size:12px; 27 | height:70% 28 | } 29 | .list_select_button{ 30 | width:100%; 31 | line-height: 25px; 32 | } -------------------------------------------------------------------------------- /web/manage.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # coding:utf-8 3 | 4 | import os 5 | from app import create_app, db 6 | from flask.ext.script import Manager, Shell 7 | from flask.ext.migrate import Migrate, MigrateCommand 8 | from app.models import switch_pirpost 9 | 10 | app = create_app(os.getenv('FLASK_CONFIG') or 'development') 11 | manager = Manager(app) 12 | migrate = Migrate(app, db) 13 | 14 | def make_shell_context(): 15 | return dict(app=app, db=db, switch_pirpost=switch_pirpost) 16 | manager.add_command('shell', Shell(make_context=make_shell_context)) 17 | manager.add_command('db', MigrateCommand) 18 | 19 | if __name__ == "__main__": 20 | manager.run() 21 | -------------------------------------------------------------------------------- /web/.idea/web.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 15 | 16 | -------------------------------------------------------------------------------- /bootstrapptime/bootstrap-datetimepicker.zh-CN.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Simplified Chinese translation for bootstrap-datetimepicker 3 | * Yuan Cheung 4 | */ 5 | ;(function($){ 6 | $.fn.datetimepicker.dates['zh-CN'] = { 7 | days: ["星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六", "星期日"], 8 | daysShort: ["周日", "周一", "周二", "周三", "周四", "周五", "周六", "周日"], 9 | daysMin: ["日", "一", "二", "三", "四", "五", "六", "日"], 10 | months: ["一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月"], 11 | monthsShort: ["一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月"], 12 | today: "今天", 13 | suffix: [], 14 | meridiem: ["上午", "下午"] 15 | }; 16 | }(jQuery)); 17 | -------------------------------------------------------------------------------- /web/app/templates/resource/service_index.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 | {% include "public/cmdb_left.html" %} 3 | 6 |
7 | 去添加业务线或产品线 8 |
9 | {% for service,products in services.items %} 10 |
{{ service.service_name }}
11 | {% for prod in products %} 12 |
{{ prod.service_name }}
13 | {% endfor %} 14 | {% endfor %} 15 |
16 |
17 | {% include "public/footer.html" %} 18 | -------------------------------------------------------------------------------- /web/app/templates.bak/resource/service_index.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 | {% include "public/cmdb_left.html" %} 3 | 6 |
7 | 去添加业务线或产品线 8 |
9 | {% for service,products in services.items %} 10 |
{{ service.service_name }}
11 | {% for prod in products %} 12 |
{{ prod.service_name }}
13 | {% endfor %} 14 | {% endfor %} 15 |
16 |
17 | {% include "public/footer.html" %} 18 | -------------------------------------------------------------------------------- /web/.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /web/migrations/versions/05994d747975_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: 05994d747975 4 | Revises: 968c5bad1e86 5 | Create Date: 2016-01-25 11:25:00.041630 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = '05994d747975' 11 | down_revision = '968c5bad1e86' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.add_column('server', sa.Column('uuid', sa.String(length=32), nullable=True)) 20 | ### end Alembic commands ### 21 | 22 | 23 | def downgrade(): 24 | ### commands auto generated by Alembic - please adjust! ### 25 | op.drop_column('server', 'uuid') 26 | ### end Alembic commands ### 27 | -------------------------------------------------------------------------------- /web/migrations/versions/447d1743e0de_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: 447d1743e0de 4 | Revises: 3f20a8a72d0a 5 | Create Date: 2016-01-28 10:12:43.616668 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = '447d1743e0de' 11 | down_revision = '3f20a8a72d0a' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.add_column('server', sa.Column('uuid', sa.String(length=100), nullable=True)) 20 | ### end Alembic commands ### 21 | 22 | 23 | def downgrade(): 24 | ### commands auto generated by Alembic - please adjust! ### 25 | op.drop_column('server', 'uuid') 26 | ### end Alembic commands ### 27 | -------------------------------------------------------------------------------- /web/app/static/js/bootstrap-datetimepicker.zh-CN.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Simplified Chinese translation for bootstrap-datetimepicker 3 | * Yuan Cheung 4 | */ 5 | ;(function($){ 6 | $.fn.datetimepicker.dates['zh-CN'] = { 7 | days: ["星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六", "星期日"], 8 | daysShort: ["周日", "周一", "周二", "周三", "周四", "周五", "周六", "周日"], 9 | daysMin: ["日", "一", "二", "三", "四", "五", "六", "日"], 10 | months: ["一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月"], 11 | monthsShort: ["一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月"], 12 | today: "今日", 13 | suffix: [], 14 | meridiem: ["上午", "下午"], 15 | format: "yyyy-mm-dd" /*控制显示格式*/ 16 | }; 17 | }(jQuery)); 18 | -------------------------------------------------------------------------------- /web/migrations/versions/3f20a8a72d0a_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: 3f20a8a72d0a 4 | Revises: e8ed4b55f520 5 | Create Date: 2016-01-28 10:12:14.554453 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = '3f20a8a72d0a' 11 | down_revision = 'e8ed4b55f520' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | from sqlalchemy.dialects import mysql 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.drop_column('server', 'uuid') 20 | ### end Alembic commands ### 21 | 22 | 23 | def downgrade(): 24 | ### commands auto generated by Alembic - please adjust! ### 25 | op.add_column('server', sa.Column('uuid', mysql.VARCHAR(length=32), nullable=True)) 26 | ### end Alembic commands ### 27 | -------------------------------------------------------------------------------- /web/app/templates/public/success.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 |
3 |


4 | {{ msg }}
5 | 6 |
7 | 8 | {% include "public/footer.html" %} 9 | 31 | 32 | -------------------------------------------------------------------------------- /web/app/templates.bak/public/success.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 |
3 |


4 | {{ msg }}
5 | 6 |
7 | 8 | {% include "public/footer.html" %} 9 | 31 | 32 | -------------------------------------------------------------------------------- /web/app/static/js/bootstrap-datetimepicker.fr.js: -------------------------------------------------------------------------------- 1 | /** 2 | * French translation for bootstrap-datetimepicker 3 | * Nico Mollet 4 | */ 5 | ;(function($){ 6 | $.fn.datetimepicker.dates['fr'] = { 7 | days: ["Dimanche", "Lundi", "Mardi", "Mercredi", "Jeudi", "Vendredi", "Samedi", "Dimanche"], 8 | daysShort: ["Dim", "Lun", "Mar", "Mer", "Jeu", "Ven", "Sam", "Dim"], 9 | daysMin: ["D", "L", "Ma", "Me", "J", "V", "S", "D"], 10 | months: ["Janvier", "Février", "Mars", "Avril", "Mai", "Juin", "Juillet", "Août", "Septembre", "Octobre", "Novembre", "Décembre"], 11 | monthsShort: ["Jan", "Fev", "Mar", "Avr", "Mai", "Jui", "Jul", "Aou", "Sep", "Oct", "Nov", "Dec"], 12 | today: "Aujourd'hui", 13 | suffix: [], 14 | meridiem: ["am", "pm"], 15 | weekStart: 1, 16 | format: "dd/mm/yyyy hh:ii" 17 | }; 18 | }(jQuery)); 19 | -------------------------------------------------------------------------------- /web/migrations/versions/a7642d8ec071_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: a7642d8ec071 4 | Revises: fb6e7286d572 5 | Create Date: 2016-01-22 14:47:24.116422 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = 'a7642d8ec071' 11 | down_revision = 'fb6e7286d572' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.create_table('managementcardtype', 20 | sa.Column('id', sa.Integer(), nullable=False), 21 | sa.Column('m_type', sa.String(length=50), nullable=False), 22 | sa.PrimaryKeyConstraint('id') 23 | ) 24 | ### end Alembic commands ### 25 | 26 | 27 | def downgrade(): 28 | ### commands auto generated by Alembic - please adjust! ### 29 | op.drop_table('managementcardtype') 30 | ### end Alembic commands ### 31 | -------------------------------------------------------------------------------- /web/migrations/versions/3cd77cb465be_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: 3cd77cb465be 4 | Revises: 447d1743e0de 5 | Create Date: 2016-02-16 17:23:57.468636 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = '3cd77cb465be' 11 | down_revision = '447d1743e0de' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | from sqlalchemy.dialects import mysql 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.alter_column('server', 'manufacturers', 20 | existing_type=mysql.VARCHAR(length=50), 21 | nullable=True) 22 | ### end Alembic commands ### 23 | 24 | 25 | def downgrade(): 26 | ### commands auto generated by Alembic - please adjust! ### 27 | op.alter_column('server', 'manufacturers', 28 | existing_type=mysql.VARCHAR(length=50), 29 | nullable=False) 30 | ### end Alembic commands ### 31 | -------------------------------------------------------------------------------- /web/migrations/versions/a290aa576ceb_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: a290aa576ceb 4 | Revises: a7642d8ec071 5 | Create Date: 2016-01-22 15:24:30.827576 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = 'a290aa576ceb' 11 | down_revision = 'a7642d8ec071' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | from sqlalchemy.dialects import mysql 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.alter_column('server', 'vm_status', 20 | existing_type=mysql.INTEGER(display_width=11), 21 | nullable=True) 22 | ### end Alembic commands ### 23 | 24 | 25 | def downgrade(): 26 | ### commands auto generated by Alembic - please adjust! ### 27 | op.alter_column('server', 'vm_status', 28 | existing_type=mysql.INTEGER(display_width=11), 29 | nullable=False) 30 | ### end Alembic commands ### 31 | -------------------------------------------------------------------------------- /web/migrations/versions/34b85bb91295_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: 34b85bb91295 4 | Revises: 7de1ffb7774f 5 | Create Date: 2016-01-21 14:16:24.689826 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = '34b85bb91295' 11 | down_revision = '7de1ffb7774f' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | from sqlalchemy.dialects import mysql 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.add_column('ipinfo', sa.Column('switch_port', sa.Integer(), nullable=True)) 20 | op.drop_column('ipinfo', 'swithc_port') 21 | ### end Alembic commands ### 22 | 23 | 24 | def downgrade(): 25 | ### commands auto generated by Alembic - please adjust! ### 26 | op.add_column('ipinfo', sa.Column('swithc_port', mysql.INTEGER(display_width=11), autoincrement=False, nullable=True)) 27 | op.drop_column('ipinfo', 'switch_port') 28 | ### end Alembic commands ### 29 | -------------------------------------------------------------------------------- /web/migrations/versions/fb6e7286d572_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: fb6e7286d572 4 | Revises: 34b85bb91295 5 | Create Date: 2016-01-21 15:02:38.821226 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = 'fb6e7286d572' 11 | down_revision = '34b85bb91295' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | from sqlalchemy.dialects import mysql 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.add_column('server', sa.Column('monitor_mail_group', sa.String(length=32), nullable=True)) 20 | op.drop_column('server', 'monitor_mail_gro') 21 | ### end Alembic commands ### 22 | 23 | 24 | def downgrade(): 25 | ### commands auto generated by Alembic - please adjust! ### 26 | op.add_column('server', sa.Column('monitor_mail_gro', mysql.VARCHAR(length=32), nullable=True)) 27 | op.drop_column('server', 'monitor_mail_group') 28 | ### end Alembic commands ### 29 | -------------------------------------------------------------------------------- /web/migrations/alembic.ini: -------------------------------------------------------------------------------- 1 | # A generic, single database configuration. 2 | 3 | [alembic] 4 | # template used to generate migration files 5 | # file_template = %%(rev)s_%%(slug)s 6 | 7 | # set to 'true' to run the environment during 8 | # the 'revision' command, regardless of autogenerate 9 | # revision_environment = false 10 | 11 | 12 | # Logging configuration 13 | [loggers] 14 | keys = root,sqlalchemy,alembic 15 | 16 | [handlers] 17 | keys = console 18 | 19 | [formatters] 20 | keys = generic 21 | 22 | [logger_root] 23 | level = WARN 24 | handlers = console 25 | qualname = 26 | 27 | [logger_sqlalchemy] 28 | level = WARN 29 | handlers = 30 | qualname = sqlalchemy.engine 31 | 32 | [logger_alembic] 33 | level = INFO 34 | handlers = 35 | qualname = alembic 36 | 37 | [handler_console] 38 | class = StreamHandler 39 | args = (sys.stderr,) 40 | level = NOTSET 41 | formatter = generic 42 | 43 | [formatter_generic] 44 | format = %(levelname)-5.5s [%(name)s] %(message)s 45 | datefmt = %H:%M:%S 46 | -------------------------------------------------------------------------------- /web/config.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # coding:utf-8 3 | 4 | import os 5 | basedir = os.path.abspath(os.path.dirname(__file__)) 6 | 7 | class config: 8 | SECRET_KEY = os.environ.get("SECRET_KDY") or "abcdefg" 9 | SQLALCHEMY_TRACK_MODIFICATIONS = False 10 | @staticmethod 11 | def init_app(app): 12 | pass 13 | 14 | 15 | class DevelopmentConfig(config): 16 | DEBUG = True 17 | SQLALCHEMY_ECHO = True 18 | SQLALCHEMY_DATABASE_URI = "mysql://reboot:123456@127.0.0.1/reboot" 19 | SQLALCHEMY_POOL_SIZE = 0 20 | SQLALCHEMY_ZABBIX_API_URL = "http://192.168.10.100/zabbix" 21 | SQLALCHEMY_ZABBIX_API_USER = "Admin" 22 | SQLALCHEMY_ZABBIX_API_PASS = "zabbix" 23 | # SQLALCHEMY_ZABBIX_API_HEADERS = {'Content-Type': 'application/json-rpc'} 24 | 25 | class ProductionConfig(config): 26 | SQLALCHEMY_DATABASE_URI = "mysql://reboot:123456@127.0.0.1/reboot" 27 | SQLALCHEMY_POOL_SIZE = 0 28 | 29 | 30 | config = { 31 | 'development': DevelopmentConfig, 32 | 'production': ProductionConfig 33 | } 34 | -------------------------------------------------------------------------------- /web/app/main/zabbix.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # coding:utf-8 3 | 4 | from __future__ import unicode_literals 5 | from flask import render_template, request 6 | 7 | from . import main 8 | import requests 9 | import json 10 | import time 11 | from app.common import api_action 12 | 13 | """ 14 | 获取zabbix 所有host groups 15 | 16 | """ 17 | @main.route("/monitor/ajax/get_zabbix_host_groups",methods=['POST']) 18 | def get_zabbix_host_groups(): 19 | from app.common.zabbix import zabbix_server 20 | hostgroup = zabbix_server.get_hostgroup() 21 | return json.dumps(hostgroup) 22 | 23 | @main.route("/monitor/ajax/get_zabbix_data_by_group", methods=['POST']) 24 | def get_zabbix_data_by_group(): 25 | from app.common.zabbix import get_zabbix_data,init 26 | init() 27 | params = dict(request.form) 28 | hosts = api_action("server.get",{"output":["id"],"where":{"server_purpose": params["server_purpose"][0], 29 | "service_id": params["service_id"][0] 30 | }}) 31 | ret = get_zabbix_data(hosts) 32 | return json.dumps(ret) 33 | -------------------------------------------------------------------------------- /web/migrations/versions/968c5bad1e86_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: 968c5bad1e86 4 | Revises: a290aa576ceb 5 | Create Date: 2016-01-23 10:54:37.441837 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = '968c5bad1e86' 11 | down_revision = 'a290aa576ceb' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | from sqlalchemy.dialects import mysql 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.add_column('server', sa.Column('os', sa.String(length=20), nullable=True)) 20 | op.drop_column('server', 'os_version') 21 | op.drop_column('server', 'os_type') 22 | ### end Alembic commands ### 23 | 24 | 25 | def downgrade(): 26 | ### commands auto generated by Alembic - please adjust! ### 27 | op.add_column('server', sa.Column('os_type', mysql.VARCHAR(length=20), nullable=True)) 28 | op.add_column('server', sa.Column('os_version', mysql.VARCHAR(length=10), nullable=True)) 29 | op.drop_column('server', 'os') 30 | ### end Alembic commands ### 31 | -------------------------------------------------------------------------------- /web/app/static/css/autocomplete.min.css: -------------------------------------------------------------------------------- 1 | @CHARSET "UTF-8";.autocomplete-container{position: relative;width: 283px;height: 32px;margin: 0 auto;}.autocomplete-input{padding:9px;border-radius:3px;font-family:inherit;float:left;font-size:1em;border:1px solid rgba(0,0,0,.19);margin:0}.autocomplete-button{font-family:inherit;border:none;background-color:#990101;color:#fff;padding:8px;float:left;cursor:pointer;border-radius:0 3px 3px 0;transition:all .2s ease-out 0s;margin:.5px 0 0 -1px}.autocomplete-button:HOVER{background-color:#D11E1E}.proposal-box{position:absolute;height:auto;border-left:1px solid rgba(0,0,0,.11);border-right:1px solid rgba(0,0,0,.11);left:0}.proposal-list{list-style:none;box-shadow:1px 1px 5px rgba(0,0,0,.44);-webkit-margin-before:0;-webkit-margin-after:0;-webkit-margin-start:0;-webkit-margin-end:0;-webkit-padding-start:0}.proposal-list li{text-align:left;padding:5px;font-family:inherit;border-bottom:1px solid rgba(0,0,0,.16);height:25px;line-height:25px;background-color:rgba(255,255,255,.8);cursor:pointer}li.proposal.selected{background-color:rgba(175,42,0,.52);color:#fff} -------------------------------------------------------------------------------- /web/app/static/plugin/multi-select/multi-select.jquery.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "multi-select", 3 | "title": "multiselect", 4 | "description": "This is a user-friendlier drop-in replacement for the standard 12 | 13 | 14 | 15 | 16 | 17 | jquery 插件加载: 18 | 19 | 27 | 28 | 29 | ////显示完全时间到分钟显示所有 30 | 31 | 显示日期优化: 32 | 33 | 34 | 35 | ######################################## 36 | $('#datetimepicker').datetimepicker({ 37 | minView: "month", //选择日期后,不会再跳转去选择时分秒 38 |   format: "yyyy-mm-dd", //选择日期后,文本框显示的日期格式 39 |   language: 'zh-CN', //汉化 40 |   autoclose:true //选择日期后自动关闭 41 | 42 | }); 43 | 44 | ################################### 45 | 46 | 47 | 48 | 49 | -------------------------------------------------------------------------------- /web/migrations/versions/3c458ab7ad8c_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: 3c458ab7ad8c 4 | Revises: 0f18cf4ae43a 5 | Create Date: 2016-01-21 10:38:01.508965 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = '3c458ab7ad8c' 11 | down_revision = '0f18cf4ae43a' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | from sqlalchemy.dialects import mysql 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.drop_table('product') 20 | ### end Alembic commands ### 21 | 22 | 23 | def downgrade(): 24 | ### commands auto generated by Alembic - please adjust! ### 25 | op.create_table('product', 26 | sa.Column('id', mysql.INTEGER(display_width=11), nullable=False), 27 | sa.Column('service_name', mysql.VARCHAR(length=20), nullable=False), 28 | sa.Column('pid', mysql.INTEGER(display_width=11), autoincrement=False, nullable=False), 29 | sa.Column('module_letter', mysql.VARCHAR(length=10), nullable=False), 30 | sa.Column('dev_interface', mysql.VARCHAR(length=200), nullable=False), 31 | sa.Column('op_interface', mysql.VARCHAR(length=100), nullable=True), 32 | sa.PrimaryKeyConstraint('id'), 33 | mysql_default_charset=u'utf8', 34 | mysql_engine=u'InnoDB' 35 | ) 36 | ### end Alembic commands ### 37 | -------------------------------------------------------------------------------- /web/app/modules/managementcardtype.py: -------------------------------------------------------------------------------- 1 | #coding=utf-8 2 | from app.models import db, Managementcardtype 3 | from app.utils import * 4 | 5 | def create(**kwargs): 6 | check_field_exists(Managementcardtype,kwargs) 7 | obj = Managementcardtype(**kwargs) 8 | db.session.add(obj) 9 | try: 10 | db.session.commit() 11 | except Exception,e: 12 | raise Exception(e.message.split(")")[1]) 13 | return obj.id 14 | 15 | def get(**kwargs): 16 | output = kwargs.get('output', []) 17 | limit = kwargs.get('limit', 10) 18 | order_by = kwargs.get('order_by', 'id desc') 19 | 20 | check_output_field(Managementcardtype, output) 21 | check_order_by(Managementcardtype, order_by) 22 | check_limit(limit) 23 | 24 | data = db.session.query(Managementcardtype).order_by(order_by).limit(limit).all() 25 | db.session.close() 26 | ret = process_result(data, output) 27 | return ret 28 | 29 | 30 | 31 | def update(**kwargs): 32 | data = kwargs.get('data', {}) 33 | where = kwargs.get('where', {}) 34 | 35 | check_update_params(Managementcardtype, data, where) 36 | ret = db.session.query(Managementcardtype).filter_by(**where).update(data) 37 | try: 38 | db.session.commit() 39 | except Exception,e: 40 | raise Exception(e.message.split(")")[1]) 41 | return ret 42 | 43 | -------------------------------------------------------------------------------- /web/app/modules/servertype.py: -------------------------------------------------------------------------------- 1 | #coding=utf-8 2 | from app.models import db, Servertype, Manufacturers 3 | from app.utils import * 4 | 5 | def create(**kwargs): 6 | 7 | check_field_exists(Servertype,kwargs) 8 | check_value_exists(Manufacturers, "id", kwargs.get("manufacturers_id", None)) 9 | obj = Servertype(**kwargs) 10 | db.session.add(obj) 11 | try: 12 | db.session.commit() 13 | except Exception,e: 14 | raise Exception(e.message.split(")")[1]) 15 | return obj.id 16 | 17 | def get(**kwargs): 18 | output = kwargs.get('output', []) 19 | limit = kwargs.get('limit', 10) 20 | order_by = kwargs.get('order_by', 'id desc') 21 | 22 | check_output_field(Servertype, output) 23 | check_order_by(Servertype, order_by) 24 | check_limit(limit) 25 | 26 | data = db.session.query(Servertype).order_by(order_by).limit(limit).all() 27 | db.session.close() 28 | ret = process_result(data, output) 29 | return ret 30 | 31 | def update(**kwargs): 32 | data = kwargs.get('data', {}) 33 | where = kwargs.get('where', {}) 34 | 35 | check_update_params(Servertype, data, where) 36 | ret = db.session.query(Servertype).filter_by(**where).update(data) 37 | try: 38 | db.session.commit() 39 | except Exception,e: 40 | raise Exception(e.message.split(")")[1]) 41 | return ret 42 | 43 | -------------------------------------------------------------------------------- /web/migrations/versions/d62dd02d6e94_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: d62dd02d6e94 4 | Revises: 3cd77cb465be 5 | Create Date: 2016-02-28 17:13:41.273673 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = 'd62dd02d6e94' 11 | down_revision = '3cd77cb465be' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.create_table('zbhost', 20 | sa.Column('id', sa.Integer(), nullable=False), 21 | sa.Column('cmdb_hostid', sa.Integer(), nullable=True), 22 | sa.Column('hostid', sa.Integer(), nullable=True), 23 | sa.Column('host', sa.String(length=50), nullable=True), 24 | sa.Column('ip', sa.String(length=32), nullable=True), 25 | sa.PrimaryKeyConstraint('id') 26 | ) 27 | op.create_index(op.f('ix_zbhost_cmdb_hostid'), 'zbhost', ['cmdb_hostid'], unique=True) 28 | op.create_index(op.f('ix_zbhost_hostid'), 'zbhost', ['hostid'], unique=True) 29 | ### end Alembic commands ### 30 | 31 | 32 | def downgrade(): 33 | ### commands auto generated by Alembic - please adjust! ### 34 | op.drop_index(op.f('ix_zbhost_hostid'), table_name='zbhost') 35 | op.drop_index(op.f('ix_zbhost_cmdb_hostid'), table_name='zbhost') 36 | op.drop_table('zbhost') 37 | ### end Alembic commands ### 38 | -------------------------------------------------------------------------------- /web/app/modules/cabinet.py: -------------------------------------------------------------------------------- 1 | #coding=utf-8 2 | from app.models import db, Cabinet,Power,Idc 3 | from app.utils import * 4 | 5 | def create(**kwargs): 6 | 7 | check_field_exists(Cabinet,kwargs) 8 | name = "name" 9 | check_value_exists(Idc, name, kwargs.get("idc_id", None)) 10 | check_value_exists(Power, "server_power",kwargs.get("power", None)) 11 | obj = Cabinet(**kwargs) 12 | db.session.add(obj) 13 | try: 14 | db.session.commit() 15 | except Exception,e: 16 | raise Exception(e.message.split(")")[1]) 17 | return obj.id 18 | 19 | def get(**kwargs): 20 | output = kwargs.get('output', []) 21 | limit = kwargs.get('limit', 10) 22 | order_by = kwargs.get('order_by', 'id desc') 23 | 24 | check_output_field(Cabinet, output) 25 | check_order_by(Cabinet, order_by) 26 | check_limit(limit) 27 | 28 | data = db.session.query(Cabinet).order_by(order_by).limit(limit).all() 29 | db.session.close() 30 | ret = process_result(data, output) 31 | return ret 32 | 33 | def update(**kwargs): 34 | data = kwargs.get('data', {}) 35 | where = kwargs.get('where', {}) 36 | 37 | check_update_params(Cabinet, data, where) 38 | ret = db.session.query(Cabinet).filter_by(**where).update(data) 39 | try: 40 | db.session.commit() 41 | except Exception,e: 42 | raise Exception(e.message.split(")")[1]) 43 | return ret 44 | 45 | -------------------------------------------------------------------------------- /web/migrations/versions/dd85fa7bd6cf_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: dd85fa7bd6cf 4 | Revises: 2294cb4ebe5f 5 | Create Date: 2016-01-21 14:10:38.836469 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = 'dd85fa7bd6cf' 11 | down_revision = '2294cb4ebe5f' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | from sqlalchemy.dialects import mysql 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.drop_table('ipinfo') 20 | ### end Alembic commands ### 21 | 22 | 23 | def downgrade(): 24 | ### commands auto generated by Alembic - please adjust! ### 25 | op.create_table('ipinfo', 26 | sa.Column('id', mysql.INTEGER(display_width=11), nullable=False), 27 | sa.Column('ip', mysql.VARCHAR(length=20), nullable=False), 28 | sa.Column('mac', mysql.VARCHAR(length=20), nullable=False), 29 | sa.Column('device', mysql.VARCHAR(length=20), nullable=False), 30 | sa.Column('server_id', mysql.INTEGER(display_width=11), autoincrement=False, nullable=False), 31 | sa.Column('switch_id', mysql.INTEGER(display_width=11), autoincrement=False, nullable=False), 32 | sa.Column('swithc_port', mysql.INTEGER(display_width=11), autoincrement=False, nullable=True), 33 | sa.PrimaryKeyConstraint('id'), 34 | mysql_default_charset=u'utf8', 35 | mysql_engine=u'InnoDB' 36 | ) 37 | ### end Alembic commands ### 38 | -------------------------------------------------------------------------------- /web/app/modules/server.py: -------------------------------------------------------------------------------- 1 | #coding=utf-8 2 | from app.models import db, Server, Supplier, Raid, Status, User, Product, Idc, Cabinet, Manufacturers, Power 3 | from app.utils import * 4 | 5 | def create(**kwargs): 6 | obj = Server(**kwargs) 7 | db.session.add(obj) 8 | try: 9 | db.session.commit() 10 | except Exception,e: 11 | raise Exception(e.message.split(")")[1]) 12 | return obj.id 13 | 14 | def get(**kwargs): 15 | output = kwargs.get('output', []) 16 | limit = kwargs.get('limit', 10) 17 | order_by = kwargs.get('order_by', 'id desc') 18 | where = {} 19 | if kwargs.get('where') and isinstance(kwargs['where'], dict): 20 | where =kwargs['where'] 21 | 22 | check_output_field(Server, output) 23 | check_order_by(Server, order_by) 24 | check_limit(limit) 25 | 26 | data = db.session.query(Server).filter_by(**where).order_by(order_by).limit(limit).all() 27 | db.session.close() 28 | ret = process_result(data, output) 29 | return ret 30 | 31 | 32 | 33 | def update(**kwargs): 34 | data = kwargs.get('data', {}) 35 | where = kwargs.get('where', {}) 36 | # check_update_params(Server, data, where) 37 | print data 38 | print where 39 | ret = db.session.query(Server).filter_by(**where).update(data) 40 | # try: 41 | db.session.commit() 42 | # except Exception,e: 43 | # raise Exception(e.message.split(")")[1]) 44 | return ret 45 | 46 | 47 | -------------------------------------------------------------------------------- /web/app/modules/product.py: -------------------------------------------------------------------------------- 1 | #coding=utf-8 2 | from app.models import db, Product 3 | from app.utils import * 4 | 5 | def create(**kwargs): 6 | check_field_exists(Product, kwargs) 7 | if kwargs.get("pid", 0) !=0: 8 | check_value_exists(Product, "id", kwargs.get("pid", None)) 9 | obj = Product(**kwargs) 10 | db.session.add(obj) 11 | try: 12 | db.session.commit() 13 | except Exception,e: 14 | raise Exception(e.message.split(")")[1]) 15 | return obj.id 16 | 17 | def get(**kwargs): 18 | output = kwargs.get('output', []) 19 | limit = kwargs.get('limit', 10) 20 | order_by = kwargs.get('order_by', 'id desc') 21 | 22 | check_output_field(Product, output) 23 | check_order_by(Product, order_by) 24 | check_limit(limit) 25 | 26 | data = db.session.query(Product).order_by(order_by).limit(limit).all() 27 | db.session.close() 28 | ret = process_result(data, output) 29 | return ret 30 | 31 | 32 | 33 | def update(**kwargs): 34 | data = kwargs.get('data', {}) 35 | where = kwargs.get('where', {}) 36 | 37 | check_update_params(Product, data, where) 38 | if data.get("pid", None) is not None and data['pid'] !=0: 39 | check_value_exists(Product, "id", kwargs.get("pid", None)) 40 | ret = db.session.query(Product).filter_by(**where).update(data) 41 | try: 42 | db.session.commit() 43 | except Exception,e: 44 | raise Exception(e.message.split(")")[1]) 45 | return ret 46 | 47 | -------------------------------------------------------------------------------- /web/app/templates/resource/server_add_iptype.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 |
3 |
4 |
5 | 6 |
7 |
8 | 9 |
10 | 11 |
12 | 13 |
14 |
15 |
16 | 17 |
18 |
19 |
20 |
21 | {% include "public/footer.html" %} 22 | 23 | 41 | -------------------------------------------------------------------------------- /web/app/common/get_tree_class.py: -------------------------------------------------------------------------------- 1 | # coding:utf-8 2 | from __init__ import api_action 3 | import json 4 | 5 | class Treeview(): 6 | def __init__(self): 7 | self.idc_info = api_action("idc.get", {"output":["id", "name"]}) 8 | self.product_info = api_action("product.get", {"output": ["id", "module_letter", "pid"]}) 9 | self.data = [] 10 | 11 | def get_child_node(self): 12 | ret = [] 13 | for product in filter(lambda x: True if x.get('pid', None) == 0 else False, self.product_info): 14 | node = {} 15 | node['text'] = product['module_letter'] 16 | node['id'] = product['id'] 17 | node['type'] = 'servoce' 18 | node['nodes'] = self.get_grant_node(product['id']) 19 | return ret 20 | 21 | def get_grant_node(self, pid): 22 | ret = [] 23 | for product in filter(lambda x: True if x.get('pid', None) == pid else False, self.product_info): 24 | node = {} 25 | node["text"] = product["module_letter"] 26 | node["id"] = product["id"] 27 | node["type"] = 'product' 28 | ret.append(node) 29 | return ret 30 | 31 | def get_node(self): 32 | child = self.get_child_node() 33 | ret = [] 34 | for idc in self.idc_info: 35 | node = {} 36 | node["text"] = idc["name"] 37 | node["id"] = idc["id"] 38 | node["type"] = "idc" 39 | node["nodes"] = child 40 | ret.append(node) 41 | return ret 42 | 43 | def get(self): 44 | return self.get_node() 45 | 46 | if __name__ == "__main__": 47 | print Treeview().get() 48 | 49 | -------------------------------------------------------------------------------- /web/app/templates.bak/resource/server_add_iptype.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 |
3 |
4 |
5 | 6 |
7 |
8 | 9 |
10 | 11 |
12 | 13 |
14 |
15 |
16 | 17 |
18 |
19 |
20 |
21 | {% include "public/footer.html" %} 22 | 23 | 41 | -------------------------------------------------------------------------------- /web/migrations/versions/7de1ffb7774f_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: 7de1ffb7774f 4 | Revises: dd85fa7bd6cf 5 | Create Date: 2016-01-21 14:11:29.733711 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = '7de1ffb7774f' 11 | down_revision = 'dd85fa7bd6cf' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.create_table('ipinfo', 20 | sa.Column('id', sa.Integer(), nullable=False), 21 | sa.Column('ip', sa.String(length=20), nullable=False), 22 | sa.Column('mac', sa.String(length=20), nullable=False), 23 | sa.Column('device', sa.String(length=20), nullable=False), 24 | sa.Column('server_id', sa.Integer(), nullable=False), 25 | sa.Column('switch_id', sa.Integer(), nullable=False), 26 | sa.Column('swithc_port', sa.Integer(), nullable=True), 27 | sa.PrimaryKeyConstraint('id') 28 | ) 29 | op.create_index(op.f('ix_ipinfo_server_id'), 'ipinfo', ['server_id'], unique=False) 30 | op.create_index(op.f('ix_ipinfo_switch_id'), 'ipinfo', ['switch_id'], unique=False) 31 | ### end Alembic commands ### 32 | 33 | 34 | def downgrade(): 35 | ### commands auto generated by Alembic - please adjust! ### 36 | op.drop_index(op.f('ix_ipinfo_switch_id'), table_name='ipinfo') 37 | op.drop_index(op.f('ix_ipinfo_server_id'), table_name='ipinfo') 38 | op.drop_table('ipinfo') 39 | ### end Alembic commands ### 40 | -------------------------------------------------------------------------------- /web/app/templates/resource/server_add_supplier.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | 5 | {% block body %} 6 |
7 |
8 |
9 | 10 |
11 |
12 | 13 |
14 | 15 |
16 | 17 |
18 |
19 |
20 | 21 |
22 |
23 |
24 |
25 | {% endblock %} 26 | {% block js %} 27 | 28 | 44 | {% endblock %} -------------------------------------------------------------------------------- /web/app/templates.bak/resource/server_add_supplier.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | 5 | {% block body %} 6 |
7 |
8 |
9 | 10 |
11 |
12 | 13 |
14 | 15 |
16 | 17 |
18 |
19 |
20 | 21 |
22 |
23 |
24 |
25 | {% endblock %} 26 | {% block js %} 27 | 28 | 44 | {% endblock %} -------------------------------------------------------------------------------- /sock.py: -------------------------------------------------------------------------------- 1 | # coding=utf-8 2 | import socket 3 | import time,threading 4 | 5 | html = """HTTP/1.1 200 OK\r\nContent-Type: image/jpeg\r\nConnection: close\r\nContent-Length: """ 6 | html404 = """HTTP/1.1 404 Not Found\r\nContent-Type: text/html\r\nContent-Length: 13\r\n\r\n

404

""" 7 | 8 | 9 | def run(client,address): 10 | read_data = client.recv(10000) 11 | print read_data 12 | try: 13 | pic_name = read_data.split(" ")[1][1:] 14 | print pic_name 15 | with file(pic_name) as f: 16 | pic_content = f.read() 17 | length = len(pic_content) 18 | html_resp = html 19 | html_resp += "%d\r\n\r\n" % (length) 20 | print html_resp 21 | html_resp += pic_content 22 | except: 23 | print "404 occur" 24 | html_resp = html404 25 | 26 | while len(html_resp) > 0: 27 | sent_cnt = conn.send(html_resp) 28 | print "sent:", sent_cnt 29 | html_resp = html_resp[sent_cnt:] 30 | conn.close() 31 | 32 | 33 | if __name__ == "__main__": 34 | listen_fd = socket.socket(socket.AF_INET, socket.SOCK_STREAM, 0) 35 | listen_fd.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) 36 | listen_fd.bind(("0.0.0.0", 9000)) 37 | listen_fd.listen(10) 38 | while True: 39 | conn, addr = listen_fd.accept() 40 | thread = threading.Thread(target=run, args=(conn, addr)) 41 | thread.start() 42 | -------------------------------------------------------------------------------- /web/app/modules/department.py: -------------------------------------------------------------------------------- 1 | #coding=utf-8 2 | from app.models import db, Department 3 | from app.utils import * 4 | 5 | def create(**kwargs): 6 | check_field_exists(Department,kwargs) 7 | # if kwargs.get("pid", 0) !=0: 8 | # check_value_exists(Department, "id", kwargs.get("pid", None)) 9 | 10 | obj = Department(**kwargs) 11 | db.session.add(obj) 12 | try: 13 | db.session.commit() 14 | except Exception,e: 15 | raise Exception(e.message.split(")")[1]) 16 | return obj.id 17 | 18 | def get(**kwargs): 19 | output = kwargs.get('output', []) 20 | limit = kwargs.get('limit', 10) 21 | order_by = kwargs.get('order_by', 'id desc') 22 | 23 | check_output_field(Department, output) 24 | check_order_by(Department, order_by) 25 | check_limit(limit) 26 | 27 | data = db.session.query(Department).order_by(order_by).limit(limit).all() 28 | db.session.close() 29 | ret = process_result(data, output) 30 | return ret 31 | 32 | 33 | 34 | def update(**kwargs): 35 | data = kwargs.get('data', {}) 36 | where = kwargs.get('where', {}) 37 | 38 | check_update_params(Department, data, where) 39 | # if data.get("pid", None) is not None and data['pid'] !=0: 40 | # check_value_exists(Department, "id", kwargs.get("pid", None)) 41 | ret = db.session.query(Department).filter_by(**where).update(data) 42 | try: 43 | db.session.commit() 44 | except Exception,e: 45 | raise Exception(e.message.split(")")[1]) 46 | return ret 47 | 48 | -------------------------------------------------------------------------------- /web/app/templates/resource/server_add_power.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | {% block body %} 5 |
6 |
7 |
8 | 9 |
10 |
11 | 12 |
13 | 14 |
15 | 16 |
17 |
18 |
19 | 20 |
21 |
22 |
23 |
24 | {% endblock %} 25 | {% block js %} 26 | 27 | 43 | {% endblock %} -------------------------------------------------------------------------------- /web/app/templates.bak/resource/server_add_power.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | {% block body %} 5 |
6 |
7 |
8 | 9 |
10 |
11 | 12 |
13 | 14 |
15 | 16 |
17 |
18 |
19 | 20 |
21 |
22 |
23 |
24 | {% endblock %} 25 | {% block js %} 26 | 27 | 43 | {% endblock %} -------------------------------------------------------------------------------- /web/app/templates/resource/server_add_raid.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | {% block body %} 5 |
6 |
7 |
8 | 9 |
10 |
11 | 12 |
13 | 14 |
15 | 16 |
17 |
18 |
19 | 20 |
21 |
22 |
23 |
24 | {% endblock %} 25 | {% block js %} 26 | 27 | 45 | {% endblock %} -------------------------------------------------------------------------------- /web/app/templates.bak/resource/server_add_raid.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | {% block body %} 5 |
6 |
7 |
8 | 9 |
10 |
11 | 12 |
13 | 14 |
15 | 16 |
17 |
18 |
19 | 20 |
21 |
22 |
23 |
24 | {% endblock %} 25 | {% block js %} 26 | 27 | 45 | {% endblock %} -------------------------------------------------------------------------------- /web/app/templates.bak/resource/server_add_status.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | 5 | {% block body %} 6 |
7 |
8 |
9 | 10 |
11 |
12 | 13 |
14 | 15 |
16 | 17 |
18 |
19 |
20 | 21 |
22 |
23 |
24 |
25 | {% endblock %} 26 | {% block js %} 27 | 28 | 46 | {% endblock %} -------------------------------------------------------------------------------- /web/app/templates/resource/server_add_status.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | 5 | {% block body %} 6 |
7 |
8 |
9 | 10 |
11 |
12 | 13 |
14 | 15 |
16 | 17 |
18 |
19 |
20 | 21 |
22 |
23 |
24 |
25 | {% endblock %} 26 | {% block js %} 27 | 28 | 46 | {% endblock %} -------------------------------------------------------------------------------- /web/app/templates/resource/server_add_raidcardtype.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | {% block body %} 5 |
6 |
7 |
8 | 9 |
10 |
11 | 12 |
13 | 14 |
15 | 16 |
17 |
18 |
19 | 20 |
21 |
22 |
23 |
24 | {% endblock %} 25 | {% block js %} 26 | 27 | 45 | {% endblock %} -------------------------------------------------------------------------------- /web/app/static/bootstrap-tagsinput/bootstrap-tagsinput.css: -------------------------------------------------------------------------------- 1 | .bootstrap-tagsinput { 2 | background-color: #fff; 3 | border: 1px solid #ccc; 4 | box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); 5 | display: inline-block; 6 | padding: 4px 6px; 7 | color: #555; 8 | vertical-align: middle; 9 | border-radius: 4px; 10 | max-width: 100%; 11 | line-height: 22px; 12 | cursor: text; 13 | } 14 | .bootstrap-tagsinput input { 15 | border: none; 16 | box-shadow: none; 17 | outline: none; 18 | background-color: transparent; 19 | padding: 0 6px; 20 | margin: 0; 21 | width: auto; 22 | max-width: inherit; 23 | } 24 | .bootstrap-tagsinput.form-control input::-moz-placeholder { 25 | color: #777; 26 | opacity: 1; 27 | } 28 | .bootstrap-tagsinput.form-control input:-ms-input-placeholder { 29 | color: #777; 30 | } 31 | .bootstrap-tagsinput.form-control input::-webkit-input-placeholder { 32 | color: #777; 33 | } 34 | .bootstrap-tagsinput input:focus { 35 | border: none; 36 | box-shadow: none; 37 | } 38 | .bootstrap-tagsinput .tag { 39 | margin-right: 2px; 40 | color: white; 41 | } 42 | .bootstrap-tagsinput .tag [data-role="remove"] { 43 | margin-left: 8px; 44 | cursor: pointer; 45 | } 46 | .bootstrap-tagsinput .tag [data-role="remove"]:after { 47 | content: "x"; 48 | padding: 0px 2px; 49 | } 50 | .bootstrap-tagsinput .tag [data-role="remove"]:hover { 51 | box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); 52 | } 53 | .bootstrap-tagsinput .tag [data-role="remove"]:hover:active { 54 | box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); 55 | } 56 | -------------------------------------------------------------------------------- /web/app/templates.bak/resource/server_add_raidcardtype.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | {% block body %} 5 |
6 |
7 |
8 | 9 |
10 |
11 | 12 |
13 | 14 |
15 | 16 |
17 |
18 |
19 | 20 |
21 |
22 |
23 |
24 | {% endblock %} 25 | {% block js %} 26 | 27 | 45 | {% endblock %} -------------------------------------------------------------------------------- /web/app/templates/resource/server_add_manufacturers.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | 5 | {% block body %} 6 |
7 |
8 |
9 | 10 |
11 |
12 | 13 |
14 | 15 |
16 | 17 |
18 |
19 |
20 | 21 |
22 |
23 |
24 |
25 | {% endblock %} 26 | {% block js %} 27 | 28 | 46 | {% endblock %} 47 | -------------------------------------------------------------------------------- /web/app/templates.bak/resource/server_add_manufacturers.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | 5 | {% block body %} 6 |
7 |
8 |
9 | 10 |
11 |
12 | 13 |
14 | 15 |
16 | 17 |
18 |
19 |
20 | 21 |
22 |
23 |
24 |
25 | {% endblock %} 26 | {% block js %} 27 | 28 | 46 | {% endblock %} 47 | -------------------------------------------------------------------------------- /web/app/tree.py: -------------------------------------------------------------------------------- 1 | # coding:utf-8 2 | from app.common import api_action 3 | import json 4 | 5 | """ 6 | 1 idc 7 | 2 service 8 | 3 product 9 | """ 10 | 11 | class Treeview(): 12 | def __init__(self): 13 | self.idc_info = api_action("idc.get",{"output":["id","name"]}) 14 | self.product_info = api_action("product.get",{"output":["id","module_letter","pid"]}) 15 | self.data = [] 16 | 17 | def get_child_node(self): 18 | ret = [] 19 | for product in filter(lambda x: True if x.get('pid', None) == else False, self.product_info) 20 | node = {} 21 | node['text'] = product['module_letter'] 22 | node['id'] = product['id'] 23 | node['type'] = "service" 24 | node['nodes'] = self.get_grant_node(product['id']) 25 | ret.append(node) 26 | return ret 27 | 28 | def get_grant_node(self, pid): 29 | ret = [] 30 | for product in filter(lambda x: True if x.get('pid', None) == else False, self.product_info): 31 | node = {} 32 | node['text'] = product['module_letter'] 33 | node['id'] = product['id'] 34 | node['type'] = "product" 35 | node['nodes'] = 'product' 36 | ret.append(node) 37 | return ret 38 | 39 | def get_node(self): 40 | child = self.get_child_node() 41 | ret = [] 42 | for idc in self.idc_info: 43 | node = {} 44 | node['text'] = idc['name'] 45 | node['id'] = idc['id'] 46 | node['type'] = 'idc' 47 | node['nodes'] = child 48 | ret.append(node) 49 | return ret 50 | 51 | def get(self): 52 | return self.get_node() 53 | 54 | def get_treeview(): 55 | return Treeview().get() 56 | -------------------------------------------------------------------------------- /web/app/templates.bak/resource/server_add_managementcardtype.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | {% block body %} 5 |
6 |
7 |
8 | 9 |
10 |
11 | 12 |
13 | 14 |
15 | 16 |
17 |
18 |
19 | 20 |
21 |
22 |
23 |
24 | {% endblock %} 25 | {% block js %} 26 | 27 | 45 | {% endblock %} -------------------------------------------------------------------------------- /web/app/templates/resource/server_add_managementcardtype.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | {% block body %} 5 |
6 |
7 |
8 | 9 |
10 |
11 | 12 |
13 | 14 |
15 | 16 |
17 |
18 |
19 | 20 |
21 |
22 |
23 |
24 | {% endblock %} 25 | {% block js %} 26 | 27 | 45 | {% endblock %} -------------------------------------------------------------------------------- /web/app/modules/switch.py: -------------------------------------------------------------------------------- 1 | #coding=utf-8 2 | from app.models import db, Switch, Idc, Cabinet, Status, Manufacturers, User 3 | from app.utils import * 4 | 5 | def create(**kwargs): 6 | check_field_exists(Switch, kwargs) 7 | check_value_exists(Idc, "id", kwargs.get("idc_id", None)) 8 | check_value_exists(Cabinet, "id", kwargs.get("cabinet_id", None)) 9 | check_value_exists(Status, "id", kwargs.get("status", None)) 10 | check_value_exists(Manufacturers, "id", kwargs.get("manufacturers", None)) 11 | check_value_exists(User, "id", kwargs.get("last_op_people", None)) 12 | obj = Switch(**kwargs) 13 | db.session.add(obj) 14 | try: 15 | db.session.commit() 16 | except Exception,e: 17 | raise Exception(e.message.split(")")[1]) 18 | return obj.id 19 | 20 | def get(**kwargs): 21 | output = kwargs.get('output', []) 22 | limit = kwargs.get('limit', 10) 23 | order_by = kwargs.get('order_by', 'id desc') 24 | 25 | check_output_field(Switch, output) 26 | check_order_by(Switch, order_by) 27 | check_limit(limit) 28 | 29 | data = db.session.query(Switch).order_by(order_by).limit(limit).all() 30 | db.session.close() 31 | ret = process_result(data, output) 32 | return ret 33 | 34 | 35 | 36 | def update(**kwargs): 37 | data = kwargs.get('data', {}) 38 | where = kwargs.get('where', {}) 39 | 40 | check_update_params(Switch, data, where) 41 | ret = db.session.query(Switch).filter_by(**where).update(data) 42 | try: 43 | db.session.commit() 44 | except Exception,e: 45 | raise Exception(e.message.split(")")[1]) 46 | return ret 47 | 48 | -------------------------------------------------------------------------------- /web/app/common/tree.py: -------------------------------------------------------------------------------- 1 | # coding:utf-8 2 | from __init__ import api_action 3 | import json 4 | 5 | class Treeview(): 6 | def __init__(self): 7 | self.idc_info = api_action("idc.get", {"output":["id", "name"]}) 8 | self.product_info = api_action("product.get", {"output": ["id", "module_letter", "pid"]}) 9 | self.data = [] 10 | 11 | def get_child_node(self): 12 | ret = [] 13 | for product in filter(lambda x: True if x.get('pid', None) == 0 else False, self.product_info): 14 | print product 15 | node = {} 16 | node['text'] = product['module_letter'] 17 | node['id'] = product['id'] 18 | node['type'] = 'service' 19 | node['nodes'] = self.get_grant_node(product['id']) 20 | ret.append(node) 21 | return ret 22 | 23 | def get_grant_node(self, pid): 24 | ret = [] 25 | for product in filter(lambda x: True if x.get('pid', None) == pid else False, self.product_info): 26 | node = {} 27 | node["text"] = product["module_letter"] 28 | node["id"] = product["id"] 29 | node["type"] = 'product' 30 | node['pid'] = pid 31 | ret.append(node) 32 | return ret 33 | 34 | def get_node(self): 35 | child = self.get_child_node() 36 | ret = [] 37 | for idc in self.idc_info: 38 | node = {} 39 | node["text"] = idc["name"] 40 | node["id"] = idc["id"] 41 | node["type"] = "idc" 42 | node["nodes"] = child 43 | ret.append(node) 44 | return ret 45 | 46 | def get(self): 47 | return self.get_node() 48 | # return self.get_child_node() 49 | 50 | def get_treeview(): 51 | return Treeview().get() 52 | 53 | 54 | if __name__ == "__main__": 55 | print Treeview().get() 56 | 57 | -------------------------------------------------------------------------------- /web/app/modules/ipinfo.py: -------------------------------------------------------------------------------- 1 | #coding=utf-8 2 | from app.models import db, Ipinfo, Server, Switch 3 | from app.utils import * 4 | 5 | def create(**kwargs): 6 | check_field_exists(Ipinfo,kwargs) 7 | 8 | check_value_exists(Server, "id", kwargs.get("server_id", None)) 9 | # check_value_exists(Switch, "id", kwargs.get("switch_id", None)) 10 | obj = Ipinfo(**kwargs) 11 | db.session.add(obj) 12 | try: 13 | db.session.commit() 14 | except Exception,e: 15 | raise Exception(e.message.split(")")[1]) 16 | return obj.id 17 | 18 | def get(**kwargs): 19 | output = kwargs.get('output', []) 20 | limit = kwargs.get('limit', 10) 21 | order_by = kwargs.get('order_by', 'id desc') 22 | 23 | check_update_params(Ipinfo, data, where) 24 | 25 | if data.get("server_id", None): 26 | check_value_exists(Server, "id", kwargs.get("server_id", None)) 27 | if data.get("switch_id", None): 28 | check_value_exists(Switch, "id", kwargs.get("switch_id", None)) 29 | 30 | check_output_field(Ipinfo, output) 31 | check_order_by(Ipinfo, order_by) 32 | check_limit(limit) 33 | 34 | data = db.session.query(Ipinfo).order_by(order_by).limit(limit).all() 35 | db.session.close() 36 | ret = process_result(data, output) 37 | return ret 38 | 39 | 40 | 41 | def update(**kwargs): 42 | data = kwargs.get('data', {}) 43 | where = kwargs.get('where', {}) 44 | 45 | check_update_params(Ipinfo, data, where) 46 | ret = db.session.query(Ipinfo).filter_by(**where).update(data) 47 | try: 48 | db.session.commit() 49 | except Exception,e: 50 | raise Exception(e.message.split(")")[1]) 51 | return ret 52 | 53 | -------------------------------------------------------------------------------- /web/app/common/performance.py: -------------------------------------------------------------------------------- 1 | #coding:utf-8 2 | from . import api_action 3 | from app.models import db, GraphiteGroupKey, GraphiteKeys 4 | 5 | def get_product(): 6 | products = api_action("product.get", {"output":["module_letter", "id", "pid"]}) 7 | business = [product for product in products if product["pid"] == 0] 8 | data = [] 9 | for b in business: 10 | sec_product = get_sec_product(products,b["id"]) 11 | for p in sec_product: 12 | performance_data = {} 13 | service_id = b["id"] 14 | server_purpose = p["id"] 15 | performance_data["product"] = "%s/%s"%(b["module_letter"], p["module_letter"]) 16 | performance_data["hostlist"] = get_hostlist_by_group(service_id, server_purpose) 17 | performance_data["item"] = get_graphite_key_by_group(server_purpose) 18 | data.append(performance_data) 19 | return data 20 | 21 | def get_graphite_key_by_group(server_purpose): 22 | graphite_key_ids = db.session.query(GraphiteGroupKey).filter_by(service_id=server_purpose).all() 23 | key_data = db.session.query(GraphiteKeys).filter(GraphiteKeys.id.in_([graphite.key_id for graphite in graphite_key_ids])).all() 24 | return [{"key": key.name, "type": key.type, "title": key.title} for key in key_data] 25 | 26 | def get_hostlist_by_group(service_id, server_purpose): 27 | where = { 28 | "service_id": service_id, 29 | "server_purpose": server_purpose 30 | } 31 | hostlist = api_action("server.get",{"output": ["hostname"], "where": where}) 32 | return [host["hostname"] for host in hostlist] 33 | 34 | def get_sec_product(products, pid): 35 | ret = [] 36 | for product in products: 37 | if product['pid'] == pid: 38 | ret.append(product) 39 | return ret 40 | -------------------------------------------------------------------------------- /web/migrations/versions/e226c50ee645_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: e226c50ee645 4 | Revises: d62dd02d6e94 5 | Create Date: 2016-03-09 20:57:14.340924 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = 'e226c50ee645' 11 | down_revision = 'd62dd02d6e94' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.create_table('graphite_group_key', 20 | sa.Column('id', sa.Integer(), nullable=False), 21 | sa.Column('service_id', sa.Integer(), nullable=True), 22 | sa.Column('key_id', sa.Integer(), nullable=True), 23 | sa.PrimaryKeyConstraint('id') 24 | ) 25 | op.create_index(op.f('ix_graphite_group_key_service_id'), 'graphite_group_key', ['service_id'], unique=False) 26 | op.create_table('graphite_keys', 27 | sa.Column('id', sa.Integer(), nullable=False), 28 | sa.Column('name', sa.String(length=200), nullable=True), 29 | sa.Column('type', sa.String(length=20), nullable=True), 30 | sa.Column('title', sa.String(length=50), nullable=True), 31 | sa.Column('status', sa.Integer(), nullable=True), 32 | sa.PrimaryKeyConstraint('id'), 33 | sa.UniqueConstraint('name') 34 | ) 35 | op.create_index(op.f('ix_graphite_keys_status'), 'graphite_keys', ['status'], unique=False) 36 | ### end Alembic commands ### 37 | 38 | 39 | def downgrade(): 40 | ### commands auto generated by Alembic - please adjust! ### 41 | op.drop_index(op.f('ix_graphite_keys_status'), table_name='graphite_keys') 42 | op.drop_table('graphite_keys') 43 | op.drop_index(op.f('ix_graphite_group_key_service_id'), table_name='graphite_group_key') 44 | op.drop_table('graphite_group_key') 45 | ### end Alembic commands ### 46 | -------------------------------------------------------------------------------- /web/app/templates/groups/server_group.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block custom_css %} 3 | 8 | {% endblock %} 9 | 10 | {% block body %} 11 | 12 |
13 |
14 | 22 |
23 | 24 | 25 | {% endblock %} 26 | {% block js %} 27 | 28 | 29 | 60 | 61 | {% endblock %} 62 | -------------------------------------------------------------------------------- /web/app/common/monitor.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | #coding:utf-8 3 | from . import api_action 4 | import json 5 | 6 | 7 | class Treeview(): 8 | def __init__(self): 9 | self.idc_info = api_action("idc.get",{"output":['id', 'name']}) 10 | self.product_info = api_action("product.get",{'output':['id', 'module_letter', 'pid']}) 11 | self.data = [] 12 | 13 | def get_child_node(self): 14 | ret = [] 15 | for p in filter(lambda x: True if x.get('pid', None) == 0 else False, self.product_info): 16 | node = {} 17 | node['text'] = p.get('module_letter', None) 18 | node['id'] = p.get('id', None) 19 | node['type'] = 'service' 20 | node['nodes'] = self.get_grant_node(p.get('id', None)) 21 | ret.append(node) 22 | return ret 23 | 24 | 25 | def get_grant_node(self, pid): 26 | ret = [] 27 | for p in filter(lambda x :True if x.get('pid', None) == pid else False, self.product_info): 28 | node = {} 29 | node['text'] = p.get('module_letter', None) 30 | node['id'] = p.get('id', None) 31 | node['type'] = 'product' 32 | node['pid'] = pid 33 | ret.append(node) 34 | return ret 35 | 36 | def get(self,idc): 37 | child = self.get_child_node() 38 | if not idc: 39 | return child 40 | ret = [] 41 | for idc in self.idc_info: 42 | node = {} 43 | node['text'] = idc.get('name', None) 44 | node['id'] = idc.get('id', 0) 45 | node['type'] = 'idc' 46 | node['nodes'] = child 47 | ret.append(node) 48 | print ret 49 | return ret 50 | 51 | 52 | 53 | """ 54 | 获取节点树信息 55 | """ 56 | def get_treeview_data(idc=True): 57 | treeview = Treeview() 58 | return treeview.get(idc) 59 | 60 | 61 | 62 | 63 | 64 | -------------------------------------------------------------------------------- /web/migrations/versions/155783ce6964_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: 155783ce6964 4 | Revises: 10f5c6fec536 5 | Create Date: 2016-01-21 11:30:02.730663 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = '155783ce6964' 11 | down_revision = '10f5c6fec536' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | from sqlalchemy.dialects import mysql 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.drop_table('switch') 20 | ### end Alembic commands ### 21 | 22 | 23 | def downgrade(): 24 | ### commands auto generated by Alembic - please adjust! ### 25 | op.create_table('switch', 26 | sa.Column('id', mysql.INTEGER(display_width=11), nullable=False), 27 | sa.Column('switch_name', mysql.VARCHAR(length=50), nullable=False), 28 | sa.Column('switch_type', mysql.VARCHAR(length=50), nullable=False), 29 | sa.Column('manager_ip', mysql.VARCHAR(length=50), nullable=False), 30 | sa.Column('category', mysql.VARCHAR(length=50), nullable=False), 31 | sa.Column('idc_id', mysql.VARCHAR(length=20), nullable=False), 32 | sa.Column('cabinet_id', mysql.INTEGER(display_width=11), autoincrement=False, nullable=False), 33 | sa.Column('status', mysql.INTEGER(display_width=11), autoincrement=False, nullable=False), 34 | sa.Column('expire', mysql.DATETIME(), nullable=True), 35 | sa.Column('remark', mysql.TEXT(), nullable=True), 36 | sa.Column('manufacturers', mysql.INTEGER(display_width=11), autoincrement=False, nullable=False), 37 | sa.Column('last_op_time', mysql.DATETIME(), nullable=True), 38 | sa.Column('last_op_people', mysql.INTEGER(display_width=11), autoincrement=False, nullable=False), 39 | sa.Column('switch_port_nums', mysql.INTEGER(display_width=11), autoincrement=False, nullable=True), 40 | sa.PrimaryKeyConstraint('id'), 41 | mysql_default_charset=u'utf8', 42 | mysql_engine=u'InnoDB' 43 | ) 44 | ### end Alembic commands ### 45 | -------------------------------------------------------------------------------- /web/app/static/js/autocomplete.min.js: -------------------------------------------------------------------------------- 1 | (function(e){e.fn.autocomplete=function(t){var n=-1;var r=[];t=e.extend({hints:[],placeholder:"Search",width:200,height:16,showButton:true,buttonText:"Search",onSubmit:function(e){},onBlur:function(){}},t);this.each(function(){var i=e("
").addClass("autocomplete-container").css("height",t.height*2);var s=e('').attr("placeholder",t.placeholder).addClass("autocomplete-input").css({width:t.width,height:t.height});if(t.showButton){s.css("border-radius","3px 0 0 3px")}var o=e("
").addClass("proposal-box").css("width",t.width+18).css("top",s.height()+20);var u=e("
    ").addClass("proposal-list");o.append(u);s.keydown(function(i){switch(i.which){case 38:i.preventDefault();e("ul.proposal-list li").removeClass("selected");if(n-1>=0){n--;e("ul.proposal-list li:eq("+n+")").addClass("selected")}else{n=-1}break;case 40:i.preventDefault();if(n+1-1){var o=e("ul.proposal-list li:eq("+n+")").html();s.val(o)}n=-1;u.empty();t.onSubmit(s.val());break;case 27:n=-1;u.empty();s.val("");break}});s.bind("change paste keyup",function(i){if(i.which!=13&&i.which!=27&&i.which!=38&&i.which!=40){r=[];n=-1;u.empty();if(s.val()!=""){var o="^"+s.val()+".*";u.empty();for(var a in t.hints){if(t.hints[a].match(o)){r.push(t.hints[a]);var f=e("
  • ").html(t.hints[a]).addClass("proposal").click(function(){s.val(e(this).html());u.empty();t.onSubmit(s.val())}).mouseenter(function(){e(this).addClass("selected")}).mouseleave(function(){e(this).removeClass("selected")});u.append(f)}}}}});s.blur(function(e){n=-1;t.onBlur()});i.append(s);i.append(o);if(t.showButton){var a=e("
    ").addClass("autocomplete-button").html(t.buttonText).css({height:t.height+2,"line-height":t.height+"px"}).click(function(){u.empty();t.onSubmit(s.val())});i.append(a)}e(this).append(i);if(t.showButton){i.css("width",t.width+a.width()+50)}});return this}})(jQuery) -------------------------------------------------------------------------------- /monitor.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | import socket,psutil,subprocess 3 | 4 | def command_result(cmd): 5 | output = subprocess.Popen("%s" %cmd,shell=True,stdout=subprocess.PIPE) 6 | ret = output.stdout.readlines() 7 | return ret 8 | 9 | def get_hostname(): 10 | return socket.gethostname() 11 | 12 | def get_ipinfo(): 13 | dict = {} 14 | data = psutil.net_if_addrs() 15 | for key in data: 16 | ip = psutil.net_if_addrs()[key][0][1] 17 | if ip.startswith("1"): 18 | dict[key]=ip 19 | return dict 20 | 21 | def get_Memtotal(): 22 | with open('/proc/meminfo') as mem_open: 23 | a = int(mem_open.readline().split()[1]) 24 | return a / 1025 25 | 26 | def get_Disktotal(): 27 | dict = {} 28 | cmd = "fdisk -l" 29 | line = command_result(cmd) 30 | for i in line: 31 | disk = i.strip('\n') 32 | if "/dev" in disk and disk.startswith("Disk"): 33 | data=disk.split() 34 | dict[data[1]]=data[2] 35 | return dict 36 | 37 | def get_cpuinfo(): 38 | dict = {} 39 | cpu_count = psutil.cpu_count() 40 | cmd = "cat /proc/cpuinfo | grep name" 41 | ret = command_result(cmd) 42 | data = list(set(ret)) 43 | dict["cpu_logic_num"]=cpu_count 44 | dict[data[0].split(":")[0]]=data[0].split(":")[1] 45 | return dict 46 | 47 | def get_hardware(): 48 | dict = {} 49 | cmd = "dmidecode | grep -A6 'System Information'" 50 | ret = command_result(cmd) 51 | del ret[0] 52 | for i in ret: 53 | i = i.strip("\n,\t") 54 | ret_list = i.split(":") 55 | dict[ret_list[0]]=ret_list[1] 56 | return dict 57 | 58 | def get_release(): 59 | list = [] 60 | cmd = "dmidecode | grep -i release" 61 | ret = command_result(cmd) 62 | data = ret[0].split(":")[1] 63 | rel = data.split("/") 64 | for i in rel: 65 | list.append(i.strip('\n,\t')) 66 | a,b,c = list 67 | r_list = [c,a,b] 68 | return "/".join(r_list) 69 | 70 | if __name__ == "__main__": 71 | print get_release() 72 | -------------------------------------------------------------------------------- /web/migrations/versions/e8ed4b55f520_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: e8ed4b55f520 4 | Revises: 05994d747975 5 | Create Date: 2016-01-25 11:27:34.165423 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = 'e8ed4b55f520' 11 | down_revision = '05994d747975' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | from sqlalchemy.dialects import mysql 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.alter_column('server', 'hostname', 20 | existing_type=mysql.VARCHAR(length=32), 21 | nullable=True) 22 | op.alter_column('server', 'idc_id', 23 | existing_type=mysql.VARCHAR(length=20), 24 | nullable=True) 25 | op.alter_column('server', 'inner_ip', 26 | existing_type=mysql.VARCHAR(length=32), 27 | nullable=True) 28 | op.alter_column('server', 'status', 29 | existing_type=mysql.INTEGER(display_width=11), 30 | nullable=True) 31 | op.alter_column('server', 'supplier', 32 | existing_type=mysql.INTEGER(display_width=11), 33 | nullable=True) 34 | ### end Alembic commands ### 35 | 36 | 37 | def downgrade(): 38 | ### commands auto generated by Alembic - please adjust! ### 39 | op.alter_column('server', 'supplier', 40 | existing_type=mysql.INTEGER(display_width=11), 41 | nullable=False) 42 | op.alter_column('server', 'status', 43 | existing_type=mysql.INTEGER(display_width=11), 44 | nullable=False) 45 | op.alter_column('server', 'inner_ip', 46 | existing_type=mysql.VARCHAR(length=32), 47 | nullable=False) 48 | op.alter_column('server', 'idc_id', 49 | existing_type=mysql.VARCHAR(length=20), 50 | nullable=False) 51 | op.alter_column('server', 'hostname', 52 | existing_type=mysql.VARCHAR(length=32), 53 | nullable=False) 54 | ### end Alembic commands ### 55 | -------------------------------------------------------------------------------- /web/app/templates/resource/server_list_os.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 | {% include "public/cmdb_left.html" %} 3 | 6 |
    7 |
    8 | {% include "public/server_list_type.html" %} 9 |
    10 |
    {{ num }} 台物理机 11 |
    12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | {% for server in servers %} 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | {% endfor %} 48 | 49 | 50 |
    #制造商服务器型号主机名内网IPMAC地址ip信息操作系统系统版本CPU型号硬盘信息内存信息服务器状态
    {{ loop.index }} {{ server.manufacturers }} {{ server.server_type }} {{ server.hostname }} {{ server.inner_ip }} {{ server.mac }} {{ server.ipinfo }} {{ server.os_type }} {{ server.os_version }} {{ server.server_cpu }} {{ server.server_disk }} {{ server.server_mem }} {{ server.status }}
    51 |
    52 |
    53 | {% include "public/footer.html" %} 54 | -------------------------------------------------------------------------------- /web/app/templates.bak/resource/server_list_os.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 | {% include "public/cmdb_left.html" %} 3 | 6 |
    7 |
    8 | {% include "public/server_list_type.html" %} 9 |
    10 |
    {{ num }} 台物理机 11 |
    12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | {% for server in servers %} 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | {% endfor %} 48 | 49 | 50 |
    #制造商服务器型号主机名内网IPMAC地址ip信息操作系统系统版本CPU型号硬盘信息内存信息服务器状态
    {{ loop.index }} {{ server.manufacturers }} {{ server.server_type }} {{ server.hostname }} {{ server.inner_ip }} {{ server.mac }} {{ server.ipinfo }} {{ server.os_type }} {{ server.os_version }} {{ server.server_cpu }} {{ server.server_disk }} {{ server.server_mem }} {{ server.status }}
    51 |
    52 |
    53 | {% include "public/footer.html" %} 54 | -------------------------------------------------------------------------------- /web/migrations/versions/2294cb4ebe5f_.py: -------------------------------------------------------------------------------- 1 | """empty message 2 | 3 | Revision ID: 2294cb4ebe5f 4 | Revises: 155783ce6964 5 | Create Date: 2016-01-21 11:31:18.405413 6 | 7 | """ 8 | 9 | # revision identifiers, used by Alembic. 10 | revision = '2294cb4ebe5f' 11 | down_revision = '155783ce6964' 12 | 13 | from alembic import op 14 | import sqlalchemy as sa 15 | 16 | 17 | def upgrade(): 18 | ### commands auto generated by Alembic - please adjust! ### 19 | op.create_table('switch', 20 | sa.Column('id', sa.Integer(), nullable=False), 21 | sa.Column('switch_name', sa.String(length=50), nullable=False), 22 | sa.Column('switch_type', sa.String(length=50), nullable=False), 23 | sa.Column('manager_ip', sa.String(length=50), nullable=False), 24 | sa.Column('category', sa.String(length=50), nullable=False), 25 | sa.Column('idc_id', sa.Integer(), nullable=False), 26 | sa.Column('cabinet_id', sa.Integer(), nullable=False), 27 | sa.Column('status', sa.Integer(), nullable=False), 28 | sa.Column('expire', sa.DateTime(), nullable=True), 29 | sa.Column('remark', sa.Text(), nullable=True), 30 | sa.Column('manufacturers', sa.Integer(), nullable=False), 31 | sa.Column('last_op_time', sa.DateTime(), nullable=True), 32 | sa.Column('last_op_people', sa.Integer(), nullable=False), 33 | sa.Column('switch_port_nums', sa.Integer(), nullable=True), 34 | sa.PrimaryKeyConstraint('id') 35 | ) 36 | op.create_index(op.f('ix_switch_cabinet_id'), 'switch', ['cabinet_id'], unique=False) 37 | op.create_index(op.f('ix_switch_idc_id'), 'switch', ['idc_id'], unique=False) 38 | op.create_index(op.f('ix_switch_manufacturers'), 'switch', ['manufacturers'], unique=False) 39 | ### end Alembic commands ### 40 | 41 | 42 | def downgrade(): 43 | ### commands auto generated by Alembic - please adjust! ### 44 | op.drop_index(op.f('ix_switch_manufacturers'), table_name='switch') 45 | op.drop_index(op.f('ix_switch_idc_id'), table_name='switch') 46 | op.drop_index(op.f('ix_switch_cabinet_id'), table_name='switch') 47 | op.drop_table('switch') 48 | ### end Alembic commands ### 49 | -------------------------------------------------------------------------------- /web/app/templates.bak/resource/server_add_servertype.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | 5 | {% block body %} 6 |
    7 |
    8 |
    9 | 10 |
    11 |
    12 | 13 |
    14 | 20 |
    21 |
    22 |
    23 | 24 |
    25 | 26 |
    27 | 28 |
    29 |
    30 |
    31 | 32 |
    33 |
    34 |
    35 |
    36 | {% endblock %} 37 | {% block js %} 38 | 39 | 40 | 58 | {% endblock %} -------------------------------------------------------------------------------- /web/app/templates/resource/server_add_servertype.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | 5 | {% block body %} 6 |
    7 |
    8 |
    9 | 10 |
    11 |
    12 | 13 |
    14 | 20 |
    21 |
    22 |
    23 | 24 |
    25 | 26 |
    27 | 28 |
    29 |
    30 |
    31 | 32 |
    33 |
    34 |
    35 |
    36 | {% endblock %} 37 | {% block js %} 38 | 39 | 40 | 58 | {% endblock %} -------------------------------------------------------------------------------- /web/app/common/get_tree.py: -------------------------------------------------------------------------------- 1 | #coding:utf-8 2 | import requests 3 | import json 4 | """ 5 | 1、先取父节点的idc,名称。 6 | 2、先去主业务线的名称,既pid =0 7 | 3、往后传一个id ,指定pid对应当前的id 8 | 9 | """ 10 | 11 | def api_action(action, params={}): 12 | url = "http://127.0.0.1:5000/api" 13 | headers = {"Content-type": "application/json"} 14 | data = { 15 | "jsonrpc": 2.0, 16 | "method" : action, 17 | "id": 1, 18 | "auth": None, 19 | "params": params 20 | } 21 | r = requests.post(url, headers=headers ,json=json.dumps(data)) 22 | if str(r.status_code) == "200": 23 | ret = json.loads(r.content) 24 | if ret.has_key('result'): 25 | return ret['result'] 26 | else: 27 | return ret['error'] 28 | 29 | def get_treeview(): 30 | data = get_node() 31 | print json.dumps(data) 32 | ret = [] 33 | return ret 34 | 35 | 36 | def get_node(): 37 | idc_info = api_action("idc.get",{"output":["id", "name"]}) 38 | child = get_child_node() 39 | ret = [] 40 | for idc in idc_info: 41 | node = {} 42 | node['text'] = idc['name'] 43 | node['id'] = idc['id'] 44 | node['type'] = 'idc' 45 | node['nodes'] = child 46 | ret.append(node) 47 | return ret 48 | 49 | def get_child_node(): 50 | ret = [] 51 | product_info = api_action("product.get", {"output":["id", "module_letter", "pid"]}) 52 | # print product_info 53 | for product in product_info: 54 | if product['pid'] == 0: 55 | node = {} 56 | node['text'] = product['module_letter'] 57 | node['id'] = product['id'] 58 | node['type'] = 'service' 59 | node['nodes'] = get_grantchild_node(product['id']) 60 | ret.append(node) 61 | # print get_grantchild_node(product['id']) 62 | return ret 63 | 64 | def get_grantchild_node(id): 65 | ret = [] 66 | product_info = api_action("product.get", {"output": ["id", "module_letter", "pid"]}) 67 | # print product_info 68 | for product in product_info: 69 | if product['pid'] == id: 70 | node = {} 71 | node['text'] = product['module_letter'] 72 | node['id'] = product['id'] 73 | node['type'] = 'product' 74 | ret.append(node) 75 | return ret 76 | 77 | 78 | if __name__ == "__main__": 79 | # print get_treeview() 80 | print get_node() 81 | -------------------------------------------------------------------------------- /web/app/templates/groups/groups_zabbix.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block custom_css %} 3 | 6 | {% endblock %} 7 | 8 | {% block body %} 9 | 10 |
    11 |
      12 |
      13 |
      14 | 15 | 16 |
      17 |
        18 | 19 |
      20 | {% endblock %} 21 | {% block js %} 22 | 23 | 24 | 25 | 27 | 28 | 29 | 30 | 79 | {% endblock %} 80 | -------------------------------------------------------------------------------- /web/app/utils/__init__.py: -------------------------------------------------------------------------------- 1 | #coding=utf-8 2 | def check_field_exists(obj, data, field_none=[]): 3 | """ 4 | 验证字段是否合法 5 | """ 6 | for field in data.keys(): 7 | if not hasattr(obj, field): 8 | raise Exception("params error") 9 | if not data.get(field, None): 10 | if data[field] not in field_none: 11 | raise Exception("{}不能为空".format(data[field])) 12 | 13 | def process_result(data, output): 14 | black = ["_sa_instance_state"] 15 | ret = [] 16 | for obj in data: 17 | if output: 18 | tmp = {} 19 | for f in output: 20 | tmp[f] = getattr(obj, f) 21 | ret.append(tmp) 22 | else: 23 | tmp = obj.__dict__ 24 | for p in black: 25 | try: 26 | tmp.pop(p) 27 | except: 28 | pass 29 | ret.append(tmp) 30 | return ret 31 | 32 | def check_order_by(obj, order_by=''): 33 | order_by = order_by.split() 34 | if len(order_by) != 2: ###看order by 传了几位 35 | raise Exception("order by 参数不正确") 36 | 37 | field, order = order_by 38 | order_list = ["asc", "desc"] 39 | 40 | if order.lower() not in ("asc", "desc"): 41 | raise Exception("排序参数不正确,值可以为:{}".format(order_list)) 42 | 43 | if not hasattr(obj, field.lower()): 44 | raise Exception("排序字段不在该表中") 45 | 46 | def check_limit(limit): 47 | if not str(limit).isdigit(): 48 | return Exception("limit值必须为数字") 49 | 50 | def check_output_field(obj, output=[]): 51 | if not isinstance(output, list): 52 | raise Exception("output必须为列表") 53 | 54 | for field in output: 55 | if not hasattr(obj, field): 56 | raise Exception("{}这个输出字段不存在".format(field)) 57 | 58 | def check_update_params(obj, data, where): 59 | if not data: 60 | raise Exception("没有需要的") 61 | 62 | for field in data.keys(): 63 | if not hasattr(obj, field): 64 | raise Exception("需要更新的{}这个字段不存在".format(field)) 65 | 66 | if not where: 67 | raise Exception("需要提供where条件") 68 | 69 | if where.get('id', None) is None: 70 | if where.get("uuid", None) is None: 71 | raise Exception("需要提供update条件") 72 | 73 | try: 74 | id = int(where['id']) 75 | if id <= 0: 76 | raise Exception("条件id的值不能为负数") 77 | except ValueError: 78 | raise Exception("条件id的值必须为int") 79 | 80 | def check_value_exists(obj, name, value): 81 | from app.models import db 82 | where = {name:value} 83 | ret = db.session.query(obj).filter_by(**where).first() 84 | if not ret: 85 | raise Exception("{}不存在".format(value)) 86 | 87 | -------------------------------------------------------------------------------- /web/app/templates/resource/server_vmlist.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 | {% include "public/cmdb_left.html" %} 3 |
      4 | 添加虚拟机 5 | 添加宿主机 6 |
      {{ num }} 台虚拟机 7 | 8 |
      9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | {% for server in servers %} 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | {% endfor %} 59 | 60 | 61 |
      #ST号操作系统系统版本主机名内网IPMAC地址IP信息CPU硬盘内存服务器状态备注业务线产品线故障处理人开发接口人运维接口人上次检测时间
      {{ loop.index }} {{ server.st }} {{ server.os_type }} {{ server.os_version }} {{ server.hostname }} {{ server.inner_ip }} {{ server.mac_address }} {{ server.ipinfo }} {{ server.server_cpu }} {{ server.server_disk }} {{ server.server_mem }} {{ server.status }} {{ server.remark }} {{ product[server.service_id] }} {{ product[server.server_purpose] }} {{ server.trouble_resolve }} {{ server.dev_interface }} {{ server.op_interface }} {{ server.check_update_time }}
      62 |
      63 |
      64 | {% include "public/footer.html" %} 65 | -------------------------------------------------------------------------------- /web/app/templates.bak/resource/server_vmlist.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 | {% include "public/cmdb_left.html" %} 3 |
      4 | 添加虚拟机 5 | 添加宿主机 6 |
      {{ num }} 台虚拟机 7 | 8 |
      9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | {% for server in servers %} 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | {% endfor %} 59 | 60 | 61 |
      #ST号操作系统系统版本主机名内网IPMAC地址IP信息CPU硬盘内存服务器状态备注业务线产品线故障处理人开发接口人运维接口人上次检测时间
      {{ loop.index }} {{ server.st }} {{ server.os_type }} {{ server.os_version }} {{ server.hostname }} {{ server.inner_ip }} {{ server.mac_address }} {{ server.ipinfo }} {{ server.server_cpu }} {{ server.server_disk }} {{ server.server_mem }} {{ server.status }} {{ server.remark }} {{ product[server.service_id] }} {{ product[server.server_purpose] }} {{ server.trouble_resolve }} {{ server.dev_interface }} {{ server.op_interface }} {{ server.check_update_time }}
      62 |
      63 |
      64 | {% include "public/footer.html" %} 65 | -------------------------------------------------------------------------------- /web/app/static/js/html5shiv.3.7.2.min.js: -------------------------------------------------------------------------------- 1 | /** 2 | * @preserve HTML5 Shiv 3.7.2 | @afarkas @jdalton @jon_neal @rem | MIT/GPL2 Licensed 3 | */ 4 | !function(a,b){function c(a,b){var c=a.createElement("p"),d=a.getElementsByTagName("head")[0]||a.documentElement;return c.innerHTML="x",d.insertBefore(c.lastChild,d.firstChild)}function d(){var a=t.elements;return"string"==typeof a?a.split(" "):a}function e(a,b){var c=t.elements;"string"!=typeof c&&(c=c.join(" ")),"string"!=typeof a&&(a=a.join(" ")),t.elements=c+" "+a,j(b)}function f(a){var b=s[a[q]];return b||(b={},r++,a[q]=r,s[r]=b),b}function g(a,c,d){if(c||(c=b),l)return c.createElement(a);d||(d=f(c));var e;return e=d.cache[a]?d.cache[a].cloneNode():p.test(a)?(d.cache[a]=d.createElem(a)).cloneNode():d.createElem(a),!e.canHaveChildren||o.test(a)||e.tagUrn?e:d.frag.appendChild(e)}function h(a,c){if(a||(a=b),l)return a.createDocumentFragment();c=c||f(a);for(var e=c.frag.cloneNode(),g=0,h=d(),i=h.length;i>g;g++)e.createElement(h[g]);return e}function i(a,b){b.cache||(b.cache={},b.createElem=a.createElement,b.createFrag=a.createDocumentFragment,b.frag=b.createFrag()),a.createElement=function(c){return t.shivMethods?g(c,a,b):b.createElem(c)},a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+d().join().replace(/[\w\-:]+/g,function(a){return b.createElem(a),b.frag.createElement(a),'c("'+a+'")'})+");return n}")(t,b.frag)}function j(a){a||(a=b);var d=f(a);return!t.shivCSS||k||d.hasCSS||(d.hasCSS=!!c(a,"article,aside,dialog,figcaption,figure,footer,header,hgroup,main,nav,section{display:block}mark{background:#FF0;color:#000}template{display:none}")),l||i(a,d),a}var k,l,m="3.7.2",n=a.html5||{},o=/^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i,p=/^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i,q="_html5shiv",r=0,s={};!function(){try{var a=b.createElement("a");a.innerHTML="",k="hidden"in a,l=1==a.childNodes.length||function(){b.createElement("a");var a=b.createDocumentFragment();return"undefined"==typeof a.cloneNode||"undefined"==typeof a.createDocumentFragment||"undefined"==typeof a.createElement}()}catch(c){k=!0,l=!0}}();var t={elements:n.elements||"abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output picture progress section summary template time video",version:m,shivCSS:n.shivCSS!==!1,supportsUnknownElements:l,shivMethods:n.shivMethods!==!1,type:"default",shivDocument:j,createElement:g,createDocumentFragment:h,addElements:e};a.html5=t,j(b)}(this,document); -------------------------------------------------------------------------------- /web/app/templates/resource/server_add_cabinet.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | {% block body %} 5 |
      6 |
      7 |
      8 | 9 |
      10 |
      11 | 12 |
      13 | 19 |
      20 |
      21 |
      22 | 23 |
      24 | 25 |
      26 | 27 |
      28 |
      29 | 30 |
      31 | 37 |
      38 | 39 |
      40 |
      41 |
      42 | 43 |
      44 |
      45 |
      46 |
      47 | {% endblock %} 48 | {% block js %} 49 | 50 | 72 | {% endblock %} -------------------------------------------------------------------------------- /web/app/templates.bak/resource/server_add_cabinet.html: -------------------------------------------------------------------------------- 1 | {% extends "public/layout.html" %} 2 | {% block sidebar %} 3 | {% endblock %} 4 | {% block body %} 5 |
      6 |
      7 |
      8 | 9 |
      10 |
      11 | 12 |
      13 | 19 |
      20 |
      21 |
      22 | 23 |
      24 | 25 |
      26 | 27 |
      28 |
      29 | 30 |
      31 | 37 |
      38 | 39 |
      40 |
      41 |
      42 | 43 |
      44 |
      45 |
      46 |
      47 | {% endblock %} 48 | {% block js %} 49 | 50 | 72 | {% endblock %} -------------------------------------------------------------------------------- /web/app/templates.bak/resource/server_list_hardware.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 | {% include "public/cmdb_left.html" %} 3 | 6 |
      7 |
      8 | {% include "public/server_list_type.html" %} 9 |
      10 |
      {{ num }} 台物理机 11 |
      12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | {% for server in servers %} 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | {% endfor %} 63 | 64 | 65 |
      #主机名内网IPST号制造商服务器型号UPS电源操作系统系统版本CPU型号硬盘信息内存信息RAID卡类型RAID卡型号远程管理卡类型远程管理卡IP业务线产品线是否为虚拟机电源功率
      {{ loop.index }} {{ server.hostname }} {{ server.inner_ip }} {{ server.st }} {{ server.manufacturers }} {{ server.server_type }} {% if server.ups %} 有 {% else %} 无 {% endif %} {{ server.os_type }} {{ server.os_version }} {{ server.server_cpu }} {{ server.server_disk }} {{ server.server_mem }} {{ server.raid }} {{ server.raid_card_type }} {{ server.remote_card }} {{ server.remote_cardip }} {{ server.server_id }} {{ server.server_purpose }} {{ server.vm_status }} {{ server.power }}
      66 |
      67 |
      68 | {% include "public/footer.html" %} 69 | 75 | -------------------------------------------------------------------------------- /web/app/templates/resource/server_list_hardware.html: -------------------------------------------------------------------------------- 1 | {% include "public/header.html" %} 2 | {% include "public/cmdb_left.html" %} 3 | 6 |
      7 |
      8 | {% include "public/server_list_type.html" %} 9 |
      10 |
      {{ num }} 台物理机 11 |
      12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | {% for server in servers %} 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | {% endfor %} 63 | 64 | 65 |
      #主机名内网IPST号制造商服务器型号UPS电源操作系统系统版本CPU型号硬盘信息内存信息RAID卡类型RAID卡型号远程管理卡类型远程管理卡IP业务线产品线是否为虚拟机电源功率
      {{ loop.index }} {{ server.hostname }} {{ server.inner_ip }} {{ server.st }} {{ server.manufacturers }} {{ server.server_type }} {% if server.ups %} 有 {% else %} 无 {% endif %} {{ server.os_type }} {{ server.os_version }} {{ server.server_cpu }} {{ server.server_disk }} {{ server.server_mem }} {{ server.raid }} {{ server.raid_card_type }} {{ server.remote_card }} {{ server.remote_cardip }} {{ server.server_id }} {{ server.server_purpose }} {{ server.vm_status }} {{ server.power }}
      66 |
      67 |
      68 | {% include "public/footer.html" %} 69 | 75 | -------------------------------------------------------------------------------- /web/app/static/css/multi-select.css: -------------------------------------------------------------------------------- 1 | .ms-container{ 2 | background: transparent url('/static/images//switch.png') no-repeat 50% 50%; 3 | width: 370px; 4 | } 5 | 6 | .ms-container:after{ 7 | content: "."; 8 | display: block; 9 | height: 0; 10 | line-height: 0; 11 | font-size: 0; 12 | clear: both; 13 | min-height: 0; 14 | visibility: hidden; 15 | } 16 | 17 | .ms-container .ms-selectable, .ms-container .ms-selection{ 18 | background: #fff; 19 | color: #555555; 20 | float: left; 21 | width: 45%; 22 | } 23 | .ms-container .ms-selection{ 24 | float: right; 25 | } 26 | 27 | .ms-container .ms-list{ 28 | -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); 29 | -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); 30 | box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); 31 | -webkit-transition: border linear 0.2s, box-shadow linear 0.2s; 32 | -moz-transition: border linear 0.2s, box-shadow linear 0.2s; 33 | -ms-transition: border linear 0.2s, box-shadow linear 0.2s; 34 | -o-transition: border linear 0.2s, box-shadow linear 0.2s; 35 | transition: border linear 0.2s, box-shadow linear 0.2s; 36 | border: 1px solid #ccc; 37 | -webkit-border-radius: 3px; 38 | -moz-border-radius: 3px; 39 | border-radius: 3px; 40 | position: relative; 41 | height: 200px; 42 | padding: 0; 43 | overflow-y: auto; 44 | } 45 | 46 | .ms-container .ms-list.ms-focus{ 47 | border-color: rgba(82, 168, 236, 0.8); 48 | -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); 49 | -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); 50 | box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); 51 | outline: 0; 52 | outline: thin dotted \9; 53 | } 54 | 55 | .ms-container ul{ 56 | margin: 0; 57 | list-style-type: none; 58 | padding: 0; 59 | } 60 | 61 | .ms-container .ms-optgroup-container{ 62 | width: 100%; 63 | } 64 | 65 | .ms-container .ms-optgroup-label{ 66 | margin: 0; 67 | padding: 5px 0px 0px 5px; 68 | cursor: pointer; 69 | color: #999; 70 | } 71 | 72 | .ms-container .ms-selectable li.ms-elem-selectable, 73 | .ms-container .ms-selection li.ms-elem-selection{ 74 | border-bottom: 1px #eee solid; 75 | padding: 2px 10px; 76 | color: #555; 77 | font-size: 14px; 78 | } 79 | 80 | .ms-container .ms-selectable li.ms-hover, 81 | .ms-container .ms-selection li.ms-hover{ 82 | cursor: pointer; 83 | color: #fff; 84 | text-decoration: none; 85 | background-color: #08c; 86 | } 87 | 88 | .ms-container .ms-selectable li.disabled, 89 | .ms-container .ms-selection li.disabled{ 90 | background-color: #eee; 91 | color: #aaa; 92 | cursor: text; 93 | } -------------------------------------------------------------------------------- /web/app/static/plugin/multi-select/css/multi-select.css: -------------------------------------------------------------------------------- 1 | .ms-container{ 2 | background: transparent url('../img/switch.png') no-repeat 50% 50%; 3 | width: 370px; 4 | } 5 | 6 | .ms-container:after{ 7 | content: "."; 8 | display: block; 9 | height: 0; 10 | line-height: 0; 11 | font-size: 0; 12 | clear: both; 13 | min-height: 0; 14 | visibility: hidden; 15 | } 16 | 17 | .ms-container .ms-selectable, .ms-container .ms-selection{ 18 | background: #fff; 19 | color: #555555; 20 | float: left; 21 | width: 45%; 22 | } 23 | .ms-container .ms-selection{ 24 | float: right; 25 | } 26 | 27 | .ms-container .ms-list{ 28 | -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); 29 | -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); 30 | box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); 31 | -webkit-transition: border linear 0.2s, box-shadow linear 0.2s; 32 | -moz-transition: border linear 0.2s, box-shadow linear 0.2s; 33 | -ms-transition: border linear 0.2s, box-shadow linear 0.2s; 34 | -o-transition: border linear 0.2s, box-shadow linear 0.2s; 35 | transition: border linear 0.2s, box-shadow linear 0.2s; 36 | border: 1px solid #ccc; 37 | -webkit-border-radius: 3px; 38 | -moz-border-radius: 3px; 39 | border-radius: 3px; 40 | position: relative; 41 | height: 200px; 42 | padding: 0; 43 | overflow-y: auto; 44 | } 45 | 46 | .ms-container .ms-list.ms-focus{ 47 | border-color: rgba(82, 168, 236, 0.8); 48 | -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); 49 | -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); 50 | box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); 51 | outline: 0; 52 | outline: thin dotted \9; 53 | } 54 | 55 | .ms-container ul{ 56 | margin: 0; 57 | list-style-type: none; 58 | padding: 0; 59 | } 60 | 61 | .ms-container .ms-optgroup-container{ 62 | width: 100%; 63 | } 64 | 65 | .ms-container .ms-optgroup-label{ 66 | margin: 0; 67 | padding: 5px 0px 0px 5px; 68 | cursor: pointer; 69 | color: #999; 70 | } 71 | 72 | .ms-container .ms-selectable li.ms-elem-selectable, 73 | .ms-container .ms-selection li.ms-elem-selection{ 74 | border-bottom: 1px #eee solid; 75 | padding: 2px 10px; 76 | color: #555; 77 | font-size: 14px; 78 | } 79 | 80 | .ms-container .ms-selectable li.ms-hover, 81 | .ms-container .ms-selection li.ms-hover{ 82 | cursor: pointer; 83 | color: #fff; 84 | text-decoration: none; 85 | background-color: #08c; 86 | } 87 | 88 | .ms-container .ms-selectable li.disabled, 89 | .ms-container .ms-selection li.disabled{ 90 | background-color: #eee; 91 | color: #aaa; 92 | cursor: text; 93 | } --------------------------------------------------------------------------------