forked from QualiSystems/cloudshell-orch-sandbox
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into refactor_saveNrestore
- Loading branch information
Showing
6 changed files
with
244 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
[run] | ||
omit = | ||
*__init__* | ||
*/profiler/* | ||
*/tests/* | ||
*/remap_child_resources_constants.py | ||
|
||
[report] | ||
omit = | ||
*__init__* | ||
*/profiler/* | ||
*/tests/* | ||
*/remap_child_resources_constants.py |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# This file demonstrates implementation of get_version for Ericsson's IPOS/SEOS devices. | ||
|
||
from cloudshell.helpers.scripts import cloudshell_scripts_helpers as helpers | ||
from cloudshell.api.cloudshell_api import * | ||
import re | ||
|
||
|
||
def main(): | ||
api_session = helpers.get_api_session() | ||
resource_details = helpers.get_resource_context_details() | ||
reservation_id = helpers.get_reservation_context_details().id | ||
# Run custom command on the device requesting the version | ||
command_inputs = [InputNameValue('custom_command', str('show version'))] | ||
cmd_out = api_session.ExecuteCommand(reservation_id, resource_details.name, 'Resource', 'run_custom_command', | ||
commandInputs=command_inputs).Output | ||
# Clean unwanted text, leaving only the version itself | ||
match = re.search('(Ericsson IPOS Version|SmartEdge OS Version).+',cmd_out) | ||
version=match.group(0) | ||
version = version.replace('Ericsson IPOS Version ','') | ||
version = version.replace('SmartEdge OS Version ','') | ||
print str(version) | ||
|
||
|
||
main() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
<ResourceManagementExportImport xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.qualisystems.com/ResourceManagement/ExportImportConfigurationSchema.xsd"> | ||
<Tags> | ||
<Tag Name="Editable After Run (System Administrators)" /> | ||
<Tag Name="Editable After Run (Everyone)" /> | ||
<Tag Name="Configuration" /> | ||
<Tag Name="Setting" /> | ||
<Tag Name="Displayed In Diagram" /> | ||
<Tag Name="Link Configurations" /> | ||
<Tag Name="Variable Capability" /> | ||
<Tag Name="Constant Capability" /> | ||
<Tag Name="Topology Category" /> | ||
<Tag Name="Displayed In Route Creation" /> | ||
<Tag Name="Available For Abstract Resources" /> | ||
<Tag Name="Displayed In Search Filters" /> | ||
<Tag Name="Execution Server Selector" /> | ||
<Tag Name="Monitor Modifications" /> | ||
<Tag Name="Admin Only" /> | ||
<Tag Name="Displayed In Insight" /> | ||
</Tags> | ||
<Attributes> | ||
<AttributeInfo Name="GitLab URL" Type="String" DefaultValue="" IsReadOnly="false" IsCommand="false"> | ||
<Tags> | ||
<TagName Name="Configuration" /> | ||
</Tags> | ||
</AttributeInfo> | ||
<AttributeInfo Name="GitLab Token" Type="String" DefaultValue="" IsReadOnly="false" IsCommand="false"> | ||
<Tags> | ||
<TagName Name="Configuration" /> | ||
</Tags> | ||
</AttributeInfo> | ||
<AttributeInfo Name="GitLab Project Name" Type="String" DefaultValue="" IsReadOnly="false" IsCommand="false"> | ||
<Tags> | ||
<TagName Name="Configuration" /> | ||
</Tags> | ||
</AttributeInfo> | ||
</Attributes> | ||
<Modules> | ||
</Modules> | ||
<ResourceFamilies> | ||
<ResourceFamily Name="Repository" IsMappableContainer="false" IsMappable="false" IsConnectable="false" IsLicenseCheckRequired="false" IsAllConnectedContainer="false" IsLockedByDefault="false" AcceptsMultipleConnections="false" Description="" SupportsMulticastMapping="false" SupportsLoopbackMapping="false" IsPowerSwitch="false" IsConsoleServer="false" ResourceType="Resource" IsAdminOnly="true" Searchable="true"> | ||
<AttachedAttributes /> | ||
<AttributeValues /> | ||
<Models> | ||
<ResourceModel Name="GitLab" Description="" SupportsConcurrentCommands="false"> | ||
<AttachedAttributes> | ||
<AttachedAttribute Name="GitLab URL" IsOverridable="true" IsLocal="true"> | ||
<AllowedValues /> | ||
</AttachedAttribute> | ||
<AttachedAttribute Name="GitLab Token" IsOverridable="true" IsLocal="true"> | ||
<AllowedValues /> | ||
</AttachedAttribute> | ||
<AttachedAttribute Name="GitLab Project Name" IsOverridable="true" IsLocal="true"> | ||
<AllowedValues /> | ||
</AttachedAttribute> | ||
</AttachedAttributes> | ||
<AttributeValues> | ||
<AttributeValue Name="GitLab URL" Value="" /> | ||
<AttributeValue Name="GitLab Token" Value="" /> | ||
<AttributeValue Name="GitLab Project Name" Value="" /> | ||
</AttributeValues> | ||
<ParentModels /> | ||
<Drivers /> | ||
</ResourceModel> | ||
</Models> | ||
</ResourceFamily> | ||
</ResourceFamilies> | ||
<DriverDescriptors> | ||
</DriverDescriptors> | ||
</ResourceManagementExportImport> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,105 @@ | ||
|
||
<ResourceManagementExportImport xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.qualisystems.com/ResourceManagement/ExportImportConfigurationSchema.xsd"> | ||
<Tags> | ||
<Tag Name="Editable After Run (System Administrators)" /> | ||
<Tag Name="Editable After Run (Everyone)" /> | ||
<Tag Name="Configuration" /> | ||
<Tag Name="Setting" /> | ||
<Tag Name="Displayed In Diagram" /> | ||
<Tag Name="Link Configurations" /> | ||
<Tag Name="Variable Capability" /> | ||
<Tag Name="Constant Capability" /> | ||
<Tag Name="Topology Category" /> | ||
<Tag Name="Displayed In Route Creation" /> | ||
<Tag Name="Available For Abstract Resources" /> | ||
<Tag Name="Displayed In Search Filters" /> | ||
<Tag Name="Execution Server Selector" /> | ||
<Tag Name="Monitor Modifications" /> | ||
<Tag Name="Admin Only" /> | ||
<Tag Name="Displayed In Insight" /> | ||
</Tags> | ||
<Attributes> | ||
<AttributeInfo Name="Storage Port" Type="Numeric" DefaultValue="0" IsReadOnly="false" IsCommand="false"> | ||
<Tags> | ||
<TagName Name="Configuration" /> | ||
<TagName Name="Setting" /> | ||
</Tags> | ||
</AttributeInfo> | ||
<AttributeInfo Name="Storage Network configs Path" Type="String" DefaultValue="" IsReadOnly="false" IsCommand="false"> | ||
<Tags> | ||
<TagName Name="Configuration" /> | ||
<TagName Name="Setting" /> | ||
</Tags> | ||
</AttributeInfo> | ||
<AttributeInfo Name="Storage username" Type="String" DefaultValue="" IsReadOnly="false" IsCommand="false"> | ||
<Tags> | ||
<TagName Name="Configuration" /> | ||
</Tags> | ||
</AttributeInfo> | ||
<AttributeInfo Name="Storage password" Type="String" DefaultValue="" IsReadOnly="false" IsCommand="false"> | ||
<Tags> | ||
<TagName Name="Configuration" /> | ||
</Tags> | ||
</AttributeInfo> | ||
<AttributeInfo Name="Orch Config file path" Type="String" DefaultValue="" IsReadOnly="false" IsCommand="false"> | ||
<Tags> | ||
<TagName Name="Configuration" /> | ||
</Tags> | ||
</AttributeInfo> | ||
<AttributeInfo Name="Orch Disable Load Config" Type="Boolean" DefaultValue="False" IsReadOnly="false" IsCommand="false"> | ||
<Tags> | ||
<TagName Name="Configuration" /> | ||
</Tags> | ||
</AttributeInfo> | ||
</Attributes> | ||
<Modules> | ||
</Modules> | ||
<ResourceFamilies> | ||
<ResourceFamily Name="Storage server" IsMappableContainer="false" IsMappable="false" IsConnectable="false" IsLicenseCheckRequired="false" IsAllConnectedContainer="false" IsLockedByDefault="false" AcceptsMultipleConnections="false" Description="" SupportsMulticastMapping="false" SupportsLoopbackMapping="false" IsPowerSwitch="false" IsConsoleServer="false" ResourceType="Resource" IsAdminOnly="true" Searchable="true"> | ||
<AttachedAttributes /> | ||
<AttributeValues /> | ||
<Models> | ||
<ResourceModel Name="Generic FTP server" Description="" SupportsConcurrentCommands="false"> | ||
<AttachedAttributes> | ||
<AttachedAttribute Name="Storage Port" IsOverridable="true" IsLocal="true"> | ||
<AllowedValues /> | ||
</AttachedAttribute> | ||
<AttachedAttribute Name="Storage Network configs Path" IsOverridable="true" IsLocal="true"> | ||
<AllowedValues /> | ||
</AttachedAttribute> | ||
<AttachedAttribute Name="Storage username" IsOverridable="true" IsLocal="true"> | ||
<AllowedValues /> | ||
</AttachedAttribute> | ||
<AttachedAttribute Name="Storage password" IsOverridable="true" IsLocal="true"> | ||
<AllowedValues /> | ||
</AttachedAttribute> | ||
</AttachedAttributes> | ||
<AttributeValues> | ||
<AttributeValue Name="Storage Network configs Path" Value="" /> | ||
<AttributeValue Name="Storage username" Value="" /> | ||
<AttributeValue Name="Storage password" Value="" /> | ||
<AttributeValue Name="Storage Port" Value="21" /> | ||
</AttributeValues> | ||
<ParentModels /> | ||
<Drivers /> | ||
</ResourceModel> | ||
</Models> | ||
</ResourceFamily> | ||
<ResourceFamily Name="Pool" IsMappableContainer="false" IsMappable="false" IsConnectable="false" IsLicenseCheckRequired="false" IsAllConnectedContainer="false" IsLockedByDefault="true" AcceptsMultipleConnections="false" Description="" SupportsMulticastMapping="false" SupportsLoopbackMapping="false" IsPowerSwitch="false" IsConsoleServer="false" ResourceType="Resource" IsAdminOnly="true" Searchable="true"> | ||
<AttachedAttributes /> | ||
<AttributeValues /> | ||
<Models> | ||
<ResourceModel Name="Config Set Pool" Description="" SupportsConcurrentCommands="false"> | ||
<ParentModels /> | ||
<Drivers /> | ||
<AttachedAttributes /> | ||
<AttributeValues /> | ||
<ParentModels /> | ||
<Drivers /> | ||
</ResourceModel> | ||
</Models> | ||
</ResourceFamily> | ||
</ResourceFamilies> | ||
<DriverDescriptors> | ||
</DriverDescriptors> | ||
</ResourceManagementExportImport> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters