sindri-dashboard 0.0.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- sindri_dashboard-0.0.2/LICENSE +202 -0
- sindri_dashboard-0.0.2/PKG-INFO +31 -0
- sindri_dashboard-0.0.2/pyproject.toml +52 -0
- sindri_dashboard-0.0.2/setup.cfg +4 -0
- sindri_dashboard-0.0.2/sindri_dashboard/__init__.py +16 -0
- sindri_dashboard-0.0.2/sindri_dashboard/content/__init__.py +9 -0
- sindri_dashboard-0.0.2/sindri_dashboard/content/sindri/__init__.py +8 -0
- sindri_dashboard-0.0.2/sindri_dashboard/content/sindri/api.py +224 -0
- sindri_dashboard-0.0.2/sindri_dashboard/content/sindri/panel.py +17 -0
- sindri_dashboard-0.0.2/sindri_dashboard/content/sindri/urls.py +27 -0
- sindri_dashboard-0.0.2/sindri_dashboard/content/sindri/views.py +56 -0
- sindri_dashboard-0.0.2/sindri_dashboard/enabled/_1660_project_provision_cloud_panel.py +96 -0
- sindri_dashboard-0.0.2/sindri_dashboard/enabled/__init__.py +14 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/angular-material.scss +18140 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/angular-notify.scss +83 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/hotgen-main.scss +5 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/hotgen.scss +182 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/img/icons/file-text-o.svg +3 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/img/icons/floppy-o.svg +3 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/img/icons/ic_close_24px.svg +1 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/img/icons/ic_help_outline_24px.svg +1 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/img/icons/spinner.svg +3 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/img/icons/trash.svg +3 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/img/icons/unknown-gray.svg +33 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/img/icons/unknown-green.svg +33 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/img/icons/unknown-red.svg +33 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/img/icons/unknown.svg +33 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/css/vis.scss +1248 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/agent.controller.js +49 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/agent.module.js +42 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/compile.directive.js +13 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/dependson.directive.js +55 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/draggable.directive.js +27 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/droppable.directive.js +57 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/globals.service.js +100 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/icons.controller.js +33 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/loading.controller.js +20 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/menu.controller.js +80 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/modal-draft.controller.js +64 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/modal-edge.controller.js +82 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/modal-node.controller.js +172 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/modal-template.controller.js +143 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/sindri-hcl.js +235 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/sindri-run.controller.js +167 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/states.service.js +153 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/template-generator.module.js +41 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/utils.module.js +230 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/components/vis-network.controller.js +215 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/libs/angular-material.js +36390 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/libs/angular-notify.js +184 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/libs/vis.js +41197 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__cinder__volume/os__cinder__volume.html +155 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__cinder__volume/os__cinder__volume.js +104 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__cinder__volume/os__cinder__volume.svg +3 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__floatingip/os__neutron__floatingip.html +89 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__floatingip/os__neutron__floatingip.js +173 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__floatingip/os__neutron__floatingip.svg +5 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__net/os__neutron__net.html +116 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__net/os__neutron__net.js +97 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__net/os__neutron__net.svg +3 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__port/os__neutron__port.html +192 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__port/os__neutron__port.js +253 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__port/os__neutron__port.svg +5 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__router/os__neutron__router.html +126 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__router/os__neutron__router.js +172 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__router/os__neutron__router.svg +5 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__securitygroup/os__neutron__securitygroup.html +94 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__securitygroup/os__neutron__securitygroup.js +79 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__securitygroup/os__neutron__securitygroup.svg +3 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__subnet/os__neutron__subnet.html +160 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__subnet/os__neutron__subnet.js +148 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__neutron__subnet/os__neutron__subnet.svg +6 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__nova__keypair/os__nova__keypair.html +60 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__nova__keypair/os__nova__keypair.js +80 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__nova__keypair/os__nova__keypair.svg +3 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__nova__server/os__nova__server.html +472 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__nova__server/os__nova__server.js +603 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/js/resources/os__nova__server/os__nova__server.svg +3 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/templates/depends_on.html +18 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/templates/modal_draft.html +28 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/templates/modal_edge.html +47 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/templates/modal_resource.html +29 -0
- sindri_dashboard-0.0.2/sindri_dashboard/static/dashboard/project/sindri_dashboard/template_generator/templates/modal_template.html +40 -0
- sindri_dashboard-0.0.2/sindri_dashboard/templates/project/sindri/index.html +166 -0
- sindri_dashboard-0.0.2/sindri_dashboard.egg-info/PKG-INFO +31 -0
- sindri_dashboard-0.0.2/sindri_dashboard.egg-info/SOURCES.txt +87 -0
- sindri_dashboard-0.0.2/sindri_dashboard.egg-info/dependency_links.txt +1 -0
- sindri_dashboard-0.0.2/sindri_dashboard.egg-info/requires.txt +7 -0
- sindri_dashboard-0.0.2/sindri_dashboard.egg-info/top_level.txt +1 -0
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
|
|
2
|
+
Apache License
|
|
3
|
+
Version 2.0, January 2004
|
|
4
|
+
http://www.apache.org/licenses/
|
|
5
|
+
|
|
6
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
7
|
+
|
|
8
|
+
1. Definitions.
|
|
9
|
+
|
|
10
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
11
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
12
|
+
|
|
13
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
14
|
+
the copyright owner that is granting the License.
|
|
15
|
+
|
|
16
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
17
|
+
other entities that control, are controlled by, or are under common
|
|
18
|
+
control with that entity. For the purposes of this definition,
|
|
19
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
20
|
+
direction or management of such entity, whether by contract or
|
|
21
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
22
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
23
|
+
|
|
24
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
25
|
+
exercising permissions granted by this License.
|
|
26
|
+
|
|
27
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
28
|
+
including but not limited to software source code, documentation
|
|
29
|
+
source, and configuration files.
|
|
30
|
+
|
|
31
|
+
"Object" form shall mean any form resulting from mechanical
|
|
32
|
+
transformation or translation of a Source form, including but
|
|
33
|
+
not limited to compiled object code, generated documentation,
|
|
34
|
+
and conversions to other media types.
|
|
35
|
+
|
|
36
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
37
|
+
Object form, made available under the License, as indicated by a
|
|
38
|
+
copyright notice that is included in or attached to the work
|
|
39
|
+
(an example is provided in the Appendix below).
|
|
40
|
+
|
|
41
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
42
|
+
form, that is based on (or derived from) the Work and for which the
|
|
43
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
44
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
45
|
+
of this License, Derivative Works shall not include works that remain
|
|
46
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
47
|
+
the Work and Derivative Works thereof.
|
|
48
|
+
|
|
49
|
+
"Contribution" shall mean any work of authorship, including
|
|
50
|
+
the original version of the Work and any modifications or additions
|
|
51
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
52
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
53
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
54
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
55
|
+
means any form of electronic, verbal, or written communication sent
|
|
56
|
+
to the Licensor or its representatives, including but not limited to
|
|
57
|
+
communication on electronic mailing lists, source code control systems,
|
|
58
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
59
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
60
|
+
excluding communication that is conspicuously marked or otherwise
|
|
61
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
62
|
+
|
|
63
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
64
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
65
|
+
subsequently incorporated within the Work.
|
|
66
|
+
|
|
67
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
68
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
69
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
70
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
71
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
72
|
+
Work and such Derivative Works in Source or Object form.
|
|
73
|
+
|
|
74
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
75
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
76
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
77
|
+
(except as stated in this section) patent license to make, have made,
|
|
78
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
79
|
+
where such license applies only to those patent claims licensable
|
|
80
|
+
by such Contributor that are necessarily infringed by their
|
|
81
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
82
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
83
|
+
institute patent litigation against any entity (including a
|
|
84
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
85
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
86
|
+
or contributory patent infringement, then any patent licenses
|
|
87
|
+
granted to You under this License for that Work shall terminate
|
|
88
|
+
as of the date such litigation is filed.
|
|
89
|
+
|
|
90
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
91
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
92
|
+
modifications, and in Source or Object form, provided that You
|
|
93
|
+
meet the following conditions:
|
|
94
|
+
|
|
95
|
+
(a) You must give any other recipients of the Work or
|
|
96
|
+
Derivative Works a copy of this License; and
|
|
97
|
+
|
|
98
|
+
(b) You must cause any modified files to carry prominent notices
|
|
99
|
+
stating that You changed the files; and
|
|
100
|
+
|
|
101
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
102
|
+
that You distribute, all copyright, patent, trademark, and
|
|
103
|
+
attribution notices from the Source form of the Work,
|
|
104
|
+
excluding those notices that do not pertain to any part of
|
|
105
|
+
the Derivative Works; and
|
|
106
|
+
|
|
107
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
108
|
+
distribution, then any Derivative Works that You distribute must
|
|
109
|
+
include a readable copy of the attribution notices contained
|
|
110
|
+
within such NOTICE file, excluding those notices that do not
|
|
111
|
+
pertain to any part of the Derivative Works, in at least one
|
|
112
|
+
of the following places: within a NOTICE text file distributed
|
|
113
|
+
as part of the Derivative Works; within the Source form or
|
|
114
|
+
documentation, if provided along with the Derivative Works; or,
|
|
115
|
+
within a display generated by the Derivative Works, if and
|
|
116
|
+
wherever such third-party notices normally appear. The contents
|
|
117
|
+
of the NOTICE file are for informational purposes only and
|
|
118
|
+
do not modify the License. You may add Your own attribution
|
|
119
|
+
notices within Derivative Works that You distribute, alongside
|
|
120
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
121
|
+
that such additional attribution notices cannot be construed
|
|
122
|
+
as modifying the License.
|
|
123
|
+
|
|
124
|
+
You may add Your own copyright statement to Your modifications and
|
|
125
|
+
may provide additional or different license terms and conditions
|
|
126
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
127
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
128
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
129
|
+
the conditions stated in this License.
|
|
130
|
+
|
|
131
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
132
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
133
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
134
|
+
this License, without any additional terms or conditions.
|
|
135
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
136
|
+
the terms of any separate license agreement you may have executed
|
|
137
|
+
with Licensor regarding such Contributions.
|
|
138
|
+
|
|
139
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
140
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
141
|
+
except as required for reasonable and customary use in describing the
|
|
142
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
143
|
+
|
|
144
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
145
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
146
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
147
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
148
|
+
implied, including, without limitation, any warranties or conditions
|
|
149
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
150
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
151
|
+
appropriateness of using or redistributing the Work and assume any
|
|
152
|
+
risks associated with Your exercise of permissions under this License.
|
|
153
|
+
|
|
154
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
155
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
156
|
+
unless required by applicable law (such as deliberate and grossly
|
|
157
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
158
|
+
liable to You for damages, including any direct, indirect, special,
|
|
159
|
+
incidental, or consequential damages of any character arising as a
|
|
160
|
+
result of this License or out of the use or inability to use the
|
|
161
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
162
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
163
|
+
other commercial damages or losses), even if such Contributor
|
|
164
|
+
has been advised of the possibility of such damages.
|
|
165
|
+
|
|
166
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
167
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
168
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
169
|
+
or other liability obligations and/or rights consistent with this
|
|
170
|
+
License. However, in accepting such obligations, You may act only
|
|
171
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
172
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
173
|
+
defend, and hold each Contributor harmless for any liability
|
|
174
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
175
|
+
of your accepting any such warranty or additional liability.
|
|
176
|
+
|
|
177
|
+
END OF TERMS AND CONDITIONS
|
|
178
|
+
|
|
179
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
180
|
+
|
|
181
|
+
To apply the Apache License to your work, attach the following
|
|
182
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
183
|
+
replaced with your own identifying information. (Don't include
|
|
184
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
185
|
+
comment syntax for the file format. We also recommend that a
|
|
186
|
+
file or class name and description of purpose be included on the
|
|
187
|
+
same "printed page" as the copyright notice for easier
|
|
188
|
+
identification within third-party archives.
|
|
189
|
+
|
|
190
|
+
Copyright [yyyy] [name of copyright owner]
|
|
191
|
+
|
|
192
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
193
|
+
you may not use this file except in compliance with the License.
|
|
194
|
+
You may obtain a copy of the License at
|
|
195
|
+
|
|
196
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
197
|
+
|
|
198
|
+
Unless required by applicable law or agreed to in writing, software
|
|
199
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
200
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
201
|
+
See the License for the specific language governing permissions and
|
|
202
|
+
limitations under the License.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: sindri-dashboard
|
|
3
|
+
Version: 0.0.2
|
|
4
|
+
Summary: Sindri Horizon dashboard: the Provision Cloud panel for OpenStack Horizon
|
|
5
|
+
Author-email: Tim Hosking <tim@mungerware.com>
|
|
6
|
+
License-Expression: Apache-2.0
|
|
7
|
+
Project-URL: Homepage, https://github.com/Munger/Sindri
|
|
8
|
+
Project-URL: Repository, https://github.com/Munger/Sindri
|
|
9
|
+
Project-URL: Issues, https://github.com/Munger/Sindri/issues
|
|
10
|
+
Keywords: openstack,horizon,sindri,terraform,opentofu
|
|
11
|
+
Classifier: Development Status :: 3 - Alpha
|
|
12
|
+
Classifier: Framework :: Django
|
|
13
|
+
Classifier: Intended Audience :: Developers
|
|
14
|
+
Classifier: Intended Audience :: System Administrators
|
|
15
|
+
Classifier: Operating System :: POSIX :: Linux
|
|
16
|
+
Classifier: Programming Language :: Python :: 3
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
21
|
+
Classifier: Topic :: Software Development :: Build Tools
|
|
22
|
+
Requires-Python: >=3.11
|
|
23
|
+
License-File: LICENSE
|
|
24
|
+
Requires-Dist: horizon
|
|
25
|
+
Requires-Dist: django
|
|
26
|
+
Requires-Dist: xstatic-angular-uuid
|
|
27
|
+
Requires-Dist: xstatic-angular-vis
|
|
28
|
+
Requires-Dist: xstatic-filesaver
|
|
29
|
+
Requires-Dist: xstatic-js-yaml
|
|
30
|
+
Requires-Dist: xstatic-json2yaml
|
|
31
|
+
Dynamic: license-file
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["setuptools>=77", "wheel"]
|
|
3
|
+
build-backend = "setuptools.build_meta"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "sindri-dashboard"
|
|
7
|
+
version = "0.0.2"
|
|
8
|
+
description = "Sindri Horizon dashboard: the Provision Cloud panel for OpenStack Horizon"
|
|
9
|
+
license = "Apache-2.0"
|
|
10
|
+
license-files = ["LICENSE"]
|
|
11
|
+
authors = [
|
|
12
|
+
{ name = "Tim Hosking", email = "tim@mungerware.com" },
|
|
13
|
+
]
|
|
14
|
+
keywords = ["openstack", "horizon", "sindri", "terraform", "opentofu"]
|
|
15
|
+
classifiers = [
|
|
16
|
+
"Development Status :: 3 - Alpha",
|
|
17
|
+
"Framework :: Django",
|
|
18
|
+
"Intended Audience :: Developers",
|
|
19
|
+
"Intended Audience :: System Administrators",
|
|
20
|
+
"Operating System :: POSIX :: Linux",
|
|
21
|
+
"Programming Language :: Python :: 3",
|
|
22
|
+
"Programming Language :: Python :: 3.11",
|
|
23
|
+
"Programming Language :: Python :: 3.12",
|
|
24
|
+
"Programming Language :: Python :: 3.13",
|
|
25
|
+
"Programming Language :: Python :: 3.14",
|
|
26
|
+
"Topic :: Software Development :: Build Tools",
|
|
27
|
+
]
|
|
28
|
+
requires-python = ">=3.11"
|
|
29
|
+
dependencies = [
|
|
30
|
+
"horizon",
|
|
31
|
+
"django",
|
|
32
|
+
"xstatic-angular-uuid",
|
|
33
|
+
"xstatic-angular-vis",
|
|
34
|
+
"xstatic-filesaver",
|
|
35
|
+
"xstatic-js-yaml",
|
|
36
|
+
"xstatic-json2yaml",
|
|
37
|
+
]
|
|
38
|
+
|
|
39
|
+
[project.urls]
|
|
40
|
+
Homepage = "https://github.com/Munger/Sindri"
|
|
41
|
+
Repository = "https://github.com/Munger/Sindri"
|
|
42
|
+
Issues = "https://github.com/Munger/Sindri/issues"
|
|
43
|
+
|
|
44
|
+
[tool.setuptools.packages.find]
|
|
45
|
+
where = ["."]
|
|
46
|
+
include = ["sindri_dashboard*"]
|
|
47
|
+
|
|
48
|
+
[tool.setuptools.package-data]
|
|
49
|
+
sindri_dashboard = [
|
|
50
|
+
"templates/**/*",
|
|
51
|
+
"static/**/*",
|
|
52
|
+
]
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
## @file __init__.py
|
|
2
|
+
##
|
|
3
|
+
## @brief Sindri Horizon dashboard plugin.
|
|
4
|
+
##
|
|
5
|
+
## Copyright (c) 2026 Tim Hosking
|
|
6
|
+
## @see https://github.com/munger
|
|
7
|
+
## @par Licence: Apache-2.0
|
|
8
|
+
|
|
9
|
+
"""Sindri Horizon dashboard plugin.
|
|
10
|
+
|
|
11
|
+
Registers the Sindri panel in Horizon (reusing the Template Generator canvas
|
|
12
|
+
pattern) and exposes the small JSON endpoints the canvas needs; the heavy
|
|
13
|
+
lifting stays in the runner service (`sindri` package).
|
|
14
|
+
"""
|
|
15
|
+
|
|
16
|
+
__version__ = "0.0.1"
|
|
@@ -0,0 +1,224 @@
|
|
|
1
|
+
## @file api.py
|
|
2
|
+
##
|
|
3
|
+
## @brief Client-side API helpers for the Sindri canvas.
|
|
4
|
+
##
|
|
5
|
+
## Copyright (c) 2026 Tim Hosking
|
|
6
|
+
## @see https://github.com/munger
|
|
7
|
+
## @par Licence: Apache-2.0
|
|
8
|
+
|
|
9
|
+
"""Client-side API helpers the Sindri canvas calls.
|
|
10
|
+
|
|
11
|
+
``get_resource_options`` reuses heat-dashboard's aggregator for the canvas's
|
|
12
|
+
dropdown data, exactly as heat-dashboard's own project panel calls it. The run
|
|
13
|
+
and status calls proxy straight to the runner service: the endpoint is resolved
|
|
14
|
+
from the caller's own service catalog (``openstack_dashboard.api.base.url_for``,
|
|
15
|
+
the same way heat-dashboard resolves the "orchestration" service), and the
|
|
16
|
+
user's token is forwarded so the runner can validate it and mint the per-run
|
|
17
|
+
credential on the user's behalf.
|
|
18
|
+
"""
|
|
19
|
+
|
|
20
|
+
from __future__ import annotations
|
|
21
|
+
|
|
22
|
+
import json
|
|
23
|
+
import re
|
|
24
|
+
|
|
25
|
+
# The operations the canvas can start, matching the runner's own whitelist.
|
|
26
|
+
_OPERATIONS = ("plan", "apply", "destroy")
|
|
27
|
+
|
|
28
|
+
# A workspace or run identifier becomes a path segment in the proxied request.
|
|
29
|
+
# Anything that could move the path is rejected rather than escaped, matching
|
|
30
|
+
# the runner's own validation of the same names.
|
|
31
|
+
_SAFE_SEGMENT = re.compile(r"^[A-Za-z0-9][A-Za-z0-9._-]*$")
|
|
32
|
+
|
|
33
|
+
# The runner starts the engine and returns immediately; the canvas polls the
|
|
34
|
+
# run. This bounds the proxied call, not the run itself.
|
|
35
|
+
_DEFAULT_TIMEOUT = 30
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
def _t(message):
|
|
39
|
+
try:
|
|
40
|
+
from django.utils.translation import gettext
|
|
41
|
+
except ImportError:
|
|
42
|
+
# Only reachable in environments without django (the offline test
|
|
43
|
+
# suite); the deployed dashboard always has it.
|
|
44
|
+
return message
|
|
45
|
+
return gettext(message)
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
def _identity_headers(request):
|
|
49
|
+
"""The user's token and project, which the runner authenticates with."""
|
|
50
|
+
return {
|
|
51
|
+
"X-Auth-Token": request.user.token.id,
|
|
52
|
+
"X-Project-Id": request.user.tenant_id or "",
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
def _runner_session():
|
|
57
|
+
import requests
|
|
58
|
+
from django.conf import settings
|
|
59
|
+
|
|
60
|
+
# TLS for the proxied request follows the dashboard's own settings, the
|
|
61
|
+
# same way heat-dashboard builds its client (heat.py does this via
|
|
62
|
+
# OPENSTACK_SSL_NO_VERIFY / OPENSTACK_SSL_CACERT).
|
|
63
|
+
verify = not getattr(settings, "OPENSTACK_SSL_NO_VERIFY", False)
|
|
64
|
+
cacert = getattr(settings, "OPENSTACK_SSL_CACERT", None)
|
|
65
|
+
if cacert:
|
|
66
|
+
verify = cacert
|
|
67
|
+
session = requests.Session()
|
|
68
|
+
session.verify = verify
|
|
69
|
+
return session
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
def _runner_timeout():
|
|
73
|
+
try:
|
|
74
|
+
from django.conf import settings
|
|
75
|
+
except ImportError:
|
|
76
|
+
# Only reachable in environments without django (the offline test
|
|
77
|
+
# suite); the deployed dashboard always has it.
|
|
78
|
+
return _DEFAULT_TIMEOUT
|
|
79
|
+
return getattr(settings, "SINDRI_RUNNER_HTTP_TIMEOUT", _DEFAULT_TIMEOUT)
|
|
80
|
+
|
|
81
|
+
|
|
82
|
+
def _runner_endpoint(request):
|
|
83
|
+
from openstack_dashboard.api import base
|
|
84
|
+
|
|
85
|
+
return base.url_for(request, "sindri")
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
def get_resource_options(request, aggregator=None):
|
|
89
|
+
if aggregator is None:
|
|
90
|
+
from heat_dashboard.content.template_generator.api import (
|
|
91
|
+
get_resource_options as _agg,
|
|
92
|
+
)
|
|
93
|
+
|
|
94
|
+
aggregator = _agg
|
|
95
|
+
return json.dumps(aggregator(request))
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
def proxy_run(request, workspace_id, op, endpoint=None, session=None):
|
|
99
|
+
"""POST a plan/apply/destroy run to the runner.
|
|
100
|
+
|
|
101
|
+
The raw request body is the workspace's configuration file, which the
|
|
102
|
+
runner persists before executing. Returns ``(status, body)``: 202 with the
|
|
103
|
+
run metadata when the run starts, the runner's own error status passed
|
|
104
|
+
through, or 502 when the runner cannot be reached.
|
|
105
|
+
"""
|
|
106
|
+
import requests
|
|
107
|
+
|
|
108
|
+
if op not in _OPERATIONS:
|
|
109
|
+
return 400, json.dumps({"error": _t("invalid operation")}).encode("utf-8")
|
|
110
|
+
if not _SAFE_SEGMENT.match(workspace_id or ""):
|
|
111
|
+
return 400, json.dumps({"error": _t("invalid workspace name")}).encode("utf-8")
|
|
112
|
+
if session is None:
|
|
113
|
+
session = _runner_session()
|
|
114
|
+
if endpoint is None:
|
|
115
|
+
endpoint = _runner_endpoint(request)
|
|
116
|
+
try:
|
|
117
|
+
response = session.post(
|
|
118
|
+
f"{endpoint}/v1/workspaces/{workspace_id}/{op}",
|
|
119
|
+
data=request.body,
|
|
120
|
+
headers=_identity_headers(request),
|
|
121
|
+
timeout=_runner_timeout(),
|
|
122
|
+
)
|
|
123
|
+
except requests.exceptions.RequestException as err:
|
|
124
|
+
return 502, json.dumps(
|
|
125
|
+
{"error": _t("runner unreachable: %(err)s") % {"err": err}}
|
|
126
|
+
).encode("utf-8")
|
|
127
|
+
return response.status_code, response.content
|
|
128
|
+
|
|
129
|
+
|
|
130
|
+
def proxy_workspace_create(request, endpoint=None, session=None):
|
|
131
|
+
"""POST /v1/workspaces; the runner names the workspace when it must.
|
|
132
|
+
|
|
133
|
+
Returns ``(status, body)``. The runner answers 201 the first time a name is
|
|
134
|
+
created and 409 for an existing one -- the canvas treats both as success so
|
|
135
|
+
a repeated save does not fail.
|
|
136
|
+
"""
|
|
137
|
+
import requests
|
|
138
|
+
|
|
139
|
+
if session is None:
|
|
140
|
+
session = _runner_session()
|
|
141
|
+
if endpoint is None:
|
|
142
|
+
endpoint = _runner_endpoint(request)
|
|
143
|
+
try:
|
|
144
|
+
response = session.post(
|
|
145
|
+
f"{endpoint}/v1/workspaces",
|
|
146
|
+
data=request.body or b"",
|
|
147
|
+
headers=_identity_headers(request),
|
|
148
|
+
timeout=_runner_timeout(),
|
|
149
|
+
)
|
|
150
|
+
except requests.exceptions.RequestException as err:
|
|
151
|
+
return 502, json.dumps(
|
|
152
|
+
{"error": _t("runner unreachable: %(err)s") % {"err": err}}
|
|
153
|
+
).encode("utf-8")
|
|
154
|
+
return response.status_code, response.content
|
|
155
|
+
|
|
156
|
+
|
|
157
|
+
def proxy_run_status(request, run_id, endpoint=None, session=None):
|
|
158
|
+
"""GET the current status and output of a run. Returns ``(status, body)``."""
|
|
159
|
+
import requests
|
|
160
|
+
|
|
161
|
+
if not _SAFE_SEGMENT.match(run_id or ""):
|
|
162
|
+
return 400, json.dumps({"error": _t("invalid run id")}).encode("utf-8")
|
|
163
|
+
if session is None:
|
|
164
|
+
session = _runner_session()
|
|
165
|
+
if endpoint is None:
|
|
166
|
+
endpoint = _runner_endpoint(request)
|
|
167
|
+
try:
|
|
168
|
+
response = session.get(
|
|
169
|
+
f"{endpoint}/v1/runs/{run_id}",
|
|
170
|
+
headers=_identity_headers(request),
|
|
171
|
+
timeout=_runner_timeout(),
|
|
172
|
+
)
|
|
173
|
+
except requests.exceptions.RequestException as err:
|
|
174
|
+
return 502, json.dumps(
|
|
175
|
+
{"error": _t("runner unreachable: %(err)s") % {"err": err}}
|
|
176
|
+
).encode("utf-8")
|
|
177
|
+
return response.status_code, response.content
|
|
178
|
+
|
|
179
|
+
|
|
180
|
+
def proxy_configuration(request, workspace_id, endpoint=None, session=None):
|
|
181
|
+
"""PUT the workspace's configuration at /v1/workspaces/{id}/configuration."""
|
|
182
|
+
import requests
|
|
183
|
+
|
|
184
|
+
if not _SAFE_SEGMENT.match(workspace_id or ""):
|
|
185
|
+
return 400, json.dumps({"error": _t("invalid workspace name")}).encode("utf-8")
|
|
186
|
+
if session is None:
|
|
187
|
+
session = _runner_session()
|
|
188
|
+
if endpoint is None:
|
|
189
|
+
endpoint = _runner_endpoint(request)
|
|
190
|
+
try:
|
|
191
|
+
response = session.put(
|
|
192
|
+
f"{endpoint}/v1/workspaces/{workspace_id}/configuration",
|
|
193
|
+
data=request.body or b"",
|
|
194
|
+
headers=_identity_headers(request),
|
|
195
|
+
timeout=_runner_timeout(),
|
|
196
|
+
)
|
|
197
|
+
except requests.exceptions.RequestException as err:
|
|
198
|
+
return 502, json.dumps(
|
|
199
|
+
{"error": _t("runner unreachable: %(err)s") % {"err": err}}
|
|
200
|
+
).encode("utf-8")
|
|
201
|
+
return response.status_code, response.content
|
|
202
|
+
|
|
203
|
+
|
|
204
|
+
def proxy_workspace_delete(request, workspace_id, endpoint=None, session=None):
|
|
205
|
+
"""DELETE a workspace directory, refusing while its runs are active."""
|
|
206
|
+
import requests
|
|
207
|
+
|
|
208
|
+
if not _SAFE_SEGMENT.match(workspace_id or ""):
|
|
209
|
+
return 400, json.dumps({"error": _t("invalid workspace name")}).encode("utf-8")
|
|
210
|
+
if session is None:
|
|
211
|
+
session = _runner_session()
|
|
212
|
+
if endpoint is None:
|
|
213
|
+
endpoint = _runner_endpoint(request)
|
|
214
|
+
try:
|
|
215
|
+
response = session.delete(
|
|
216
|
+
f"{endpoint}/v1/workspaces/{workspace_id}",
|
|
217
|
+
headers=_identity_headers(request),
|
|
218
|
+
timeout=_runner_timeout(),
|
|
219
|
+
)
|
|
220
|
+
except requests.exceptions.RequestException as err:
|
|
221
|
+
return 502, json.dumps(
|
|
222
|
+
{"error": _t("runner unreachable: %(err)s") % {"err": err}}
|
|
223
|
+
).encode("utf-8")
|
|
224
|
+
return response.status_code, response.content
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
## @file panel.py
|
|
2
|
+
##
|
|
3
|
+
## @brief Horizon panel definition for Sindri.
|
|
4
|
+
##
|
|
5
|
+
## Copyright (c) 2026 Tim Hosking
|
|
6
|
+
## @see https://github.com/munger
|
|
7
|
+
## @par Licence: Apache-2.0
|
|
8
|
+
|
|
9
|
+
from django.utils.translation import gettext_lazy as _
|
|
10
|
+
|
|
11
|
+
import horizon
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class Sindri(horizon.Panel):
|
|
15
|
+
name = _("Provision Cloud")
|
|
16
|
+
slug = 'sindri'
|
|
17
|
+
permissions = ('openstack.services.sindri',)
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
## @file urls.py
|
|
2
|
+
##
|
|
3
|
+
## @brief URL routes for the Sindri panel.
|
|
4
|
+
##
|
|
5
|
+
## Copyright (c) 2026 Tim Hosking
|
|
6
|
+
## @see https://github.com/munger
|
|
7
|
+
## @par Licence: Apache-2.0
|
|
8
|
+
|
|
9
|
+
from django.urls import re_path
|
|
10
|
+
|
|
11
|
+
from sindri_dashboard.content.sindri import views
|
|
12
|
+
|
|
13
|
+
urlpatterns = [
|
|
14
|
+
re_path(r'^$', views.IndexView.as_view(), name='index'),
|
|
15
|
+
re_path(r'^get_resource_options$',
|
|
16
|
+
views.OptionView.as_view(), name="apis"),
|
|
17
|
+
re_path(r'^workspaces$',
|
|
18
|
+
views.WorkspaceCreateView.as_view(), name='workspace-create'),
|
|
19
|
+
re_path(r'^workspaces/(?P<workspace_id>[^/]+)/configuration$',
|
|
20
|
+
views.ConfigurationView.as_view(), name='configuration'),
|
|
21
|
+
re_path(r'^workspaces/(?P<workspace_id>[^/]+)/delete$',
|
|
22
|
+
views.WorkspaceDeleteView.as_view(), name='workspace-delete'),
|
|
23
|
+
re_path(r'^workspaces/(?P<workspace_id>[^/]+)/(?P<op>plan|apply|destroy)$',
|
|
24
|
+
views.RunView.as_view(), name='run'),
|
|
25
|
+
re_path(r'^runs/(?P<run_id>[^/]+)$',
|
|
26
|
+
views.RunStatusView.as_view(), name='run-status'),
|
|
27
|
+
]
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
## @file views.py
|
|
2
|
+
##
|
|
3
|
+
## @brief Views for the Sindri panel.
|
|
4
|
+
##
|
|
5
|
+
## Copyright (c) 2026 Tim Hosking
|
|
6
|
+
## @see https://github.com/munger
|
|
7
|
+
## @par Licence: Apache-2.0
|
|
8
|
+
|
|
9
|
+
from django.http import HttpResponse
|
|
10
|
+
from django.utils.translation import gettext_lazy as _
|
|
11
|
+
from django.views import generic
|
|
12
|
+
|
|
13
|
+
from horizon.browsers.views import AngularIndexView
|
|
14
|
+
|
|
15
|
+
from sindri_dashboard.content.sindri import api
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
class IndexView(AngularIndexView):
|
|
19
|
+
template_name = 'project/sindri/index.html'
|
|
20
|
+
page_title = _("Provision Cloud")
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
class OptionView(generic.View):
|
|
24
|
+
def get(self, request):
|
|
25
|
+
return HttpResponse(api.get_resource_options(request),
|
|
26
|
+
content_type="application/json")
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
class RunView(generic.View):
|
|
30
|
+
def post(self, request, workspace_id, op):
|
|
31
|
+
status, body = api.proxy_run(request, workspace_id, op)
|
|
32
|
+
return HttpResponse(body, status=status, content_type="application/json")
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
class RunStatusView(generic.View):
|
|
36
|
+
def get(self, request, run_id):
|
|
37
|
+
status, body = api.proxy_run_status(request, run_id)
|
|
38
|
+
return HttpResponse(body, status=status, content_type="application/json")
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
class WorkspaceCreateView(generic.View):
|
|
42
|
+
def post(self, request):
|
|
43
|
+
status, body = api.proxy_workspace_create(request)
|
|
44
|
+
return HttpResponse(body, status=status, content_type="application/json")
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
class ConfigurationView(generic.View):
|
|
48
|
+
def put(self, request, workspace_id):
|
|
49
|
+
status, body = api.proxy_configuration(request, workspace_id)
|
|
50
|
+
return HttpResponse(body, status=status, content_type="application/json")
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
class WorkspaceDeleteView(generic.View):
|
|
54
|
+
def post(self, request, workspace_id):
|
|
55
|
+
status, body = api.proxy_workspace_delete(request, workspace_id)
|
|
56
|
+
return HttpResponse(body, status=status, content_type="application/json")
|