Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error validating test apps: 'version' #295

Open
Res260 opened this issue Sep 25, 2024 · 3 comments · Fixed by #317 · May be fixed by Res260/contentctl#3 or #327
Open

Error validating test apps: 'version' #295

Res260 opened this issue Sep 25, 2024 · 3 comments · Fixed by #317 · May be fixed by Res260/contentctl#3 or #327

Comments

@Res260
Copy link
Contributor

Res260 commented Sep 25, 2024

I'm trying to get contentctl to download apps from splunkbase, but there is no documentation as to how to do that, so I have to keep guessing, but I'm running out of ideas.

Here is my command: contentctl test --verbose mode:all

Here is my contentctl.yml:

splunk_api_username: [email protected]
splunk_api_password: hihi
version: 20240925.16.111
path: .
app:
  uid: 42123
  title: 'MyAPP'
  appid: myapp
  version: 20240925.16.111
  description: "MyAPP"
  prefix: MA
  label: 'MyAPP'
  author_name: "MyAPP"
  author_email: [email protected]
  author_company: "MyAPP"
verbose: false
enrichments: false
build_app: true
build_api: false
build_ssa: false
build_path: dist
mode: {}
post_test_behavior: pause_on_failure
enable_integration_testing: false
apps:
- uid: 263
  title: Enterprise Security
  appid: Splunk_Enterprise_Security
  version: 7.3.2
  description: Splunk Enterprise Security
- uid: 1621
  title: Splunk Common Information Model (CIM)
  appid: Splunk_SA_CIM
  version: 5.2.0
  description: Splunk Common Information Model
  hardcoded_path: https://attack-range-appbinaries.s3.us-west-2.amazonaws.com/Latest/splunk-common-information-model-cim_520.tgz
- uid: 5579
  title: Splunk Add-on for CrowdStrike FDR
  appid: Splunk_TA_CrowdStrike_FDR
  version: 1.5.0
  description: description of app
  hardcoded_path: https://attack-range-appbinaries.s3.us-west-2.amazonaws.com/Latest/splunk-add-on-for-crowdstrike-fdr_150.tgz
container_settings:
  leave_running: true
  num_containers: 1
  full_image_path: registry.hub.docker.com/splunk/splunk:latest

I get this error:

Error validating 'contentctl.yml':
Error validating test apps: 'version'

It doesn't matter if I remove the version key from the contentctl.yml file, the error is the same.

Is this a bug or I'm doing something wrong?

@Res260
Copy link
Contributor Author

Res260 commented Sep 25, 2024

It is worth noting that if I remove splunk_api_username and splunk_api_password keys, I get this error instead:

Error validating 'contentctl.yml':
Error validating test apps: Unknown path for app 'Enterprise Security'

@Res260
Copy link
Contributor Author

Res260 commented Oct 24, 2024

I found the bug and it's fixed in #317

@pyth0n1c
Copy link
Contributor

pyth0n1c commented Nov 4, 2024

Sorry for the delay in getting to this, as we have been helping out with some internal Splunk releases.

Thank you @Res260 , you have been hard at work with some AWESOME fixes and improvements. I admit that downloading apps from Splunkbase is a feature that used to work, but we have not used (or tested it) in quite some time. Thanks for exposing all these issue. I am going to merge all the following fixes/PRs down to a single new branch for evaluation.

Related Bugs:
#295
#319
#321

Related PRs:
#317
#320

I have opened the following PR which will be used to merge + test these changes together:
#322

I will leave these issues open until all of these are reviewed + merged and a new contentctl release it made!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment