-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: update UCC UI to v1.24.0 (#709) * feat: introduce ucc-gen import-from-aob (#710) * feat: introduce ucc-gen import-from-aob This introduces a new command to import add-on built with AoB (Addon Builder) into the UCC-accepted structure. * test: fix pipeline failures * fix: use_single_instance=False by default (#711) Docs: https://dev.splunk.com/enterprise/reference/modinputs/modinputsintrospection/ * ci: update splunk/appinspect-cli-action to v1.7 (#712) * docs: update for import-from-aob command (#714)
- Loading branch information
Showing
20 changed files
with
559 additions
and
37 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
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
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
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
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
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
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
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,38 @@ | ||
# | ||
# Copyright 2021 Splunk Inc. | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
# | ||
import os | ||
import subprocess | ||
|
||
import logging | ||
import sys | ||
|
||
logger = logging.getLogger("ucc_gen") | ||
|
||
|
||
def import_from_aob(addon_name: str): | ||
addon_name_directory = os.path.join(os.getcwd(), addon_name) | ||
if not os.path.isdir(addon_name_directory): | ||
logger.error(f"No such directory {addon_name_directory}") | ||
sys.exit(1) | ||
import_from_aob_script_path = os.path.join( | ||
os.path.dirname(os.path.dirname(__file__)), | ||
"commands", | ||
"import_from_aob.sh", | ||
) | ||
imports_py_path = os.path.join( | ||
os.path.dirname(os.path.dirname(__file__)), "commands", "imports.py" | ||
) | ||
subprocess.call((import_from_aob_script_path, addon_name, imports_py_path)) |
Oops, something went wrong.