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

Cherry-pick #20357 to 7.x: Add template for ssl config reference settings #20678

Merged
merged 1 commit into from
Aug 24, 2020

Conversation

andrewkroh
Copy link
Member

@andrewkroh andrewkroh commented Aug 18, 2020

Cherry-pick of PR #20357 to 7.x branch. Original message:

What does this PR do?

Use a shared template for the ssl options in reference configs.

I provided an indent function in case this config template needed to be reused
at various indentation levels, but it turns out that all of the uses so far required
an indentation of 2 (so I could have just indented ssl.reference.yml.tmpl manually).

Why is it important?

The reduces duplication of the SSL settings in config templates and ensures that the
reference configs are consistent across outputs and monitoring.

Checklist

  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have made corresponding change to the default configuration files
  • I have added tests that prove my fix is effective or that my feature works
  • I have added an entry in CHANGELOG.next.asciidoc or CHANGELOG-developer.next.asciidoc.

Author's Checklist

  • Please review the ssl.reference.yml.tmpl to ensure that it is complete and grammatically correct. It was copied directly from the elasticsearch output reference config.

Related issues

@andrewkroh andrewkroh requested review from a team as code owners August 18, 2020 21:48
@botelastic botelastic bot added the needs_team Indicates that the issue/PR needs a Team:* label label Aug 18, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/siem (Team:SIEM)

@elasticmachine
Copy link
Collaborator

Pinging @elastic/integrations (Team:Integrations)

@botelastic botelastic bot removed the needs_team Indicates that the issue/PR needs a Team:* label label Aug 18, 2020
@elasticmachine
Copy link
Collaborator

elasticmachine commented Aug 18, 2020

💔 Tests Failed

Pipeline View Test View Changes Artifacts preview

Expand to view the summary

Build stats

  • Build Cause: [Pull request #20678 updated]

  • Start Time: 2020-08-24T01:40:36.583+0000

  • Duration: 66 min 6 sec

Test stats 🧪

Test Results
Failed 12
Passed 17980
Skipped 1853
Total 19845

Test errors

Expand to view the tests failures

  • Name: Build and Test / Auditbeat oss Linux / test_dashboards – auditbeat.tests.system.test_base.Test

    • Age: 1
    • Duration: 0.373
    • Error Details: AssertionError: Expected exit code to be 0, but it was 1
  • Name: Build and Test / Filebeat oss / test_default_settings – filebeat.tests.system.test_autodiscover.TestAutodiscover

    • Age: 1
    • Duration: 90.003
    • Error Details: Failed: Timeout >90.0s
  • Name: Build and Test / Libbeat / Libbeat oss / test_dev_tool_export_dashboard_by_id – libbeat.tests.system.test_dashboard.Test

    • Age: 1
    • Duration: 0.23
    • Error Details: AssertionError: Expected exit code to be 0, but it was 1
  • Name: Build and Test / Libbeat / Libbeat oss / test_dev_tool_export_dashboard_by_id_from_space – libbeat.tests.system.test_dashboard.Test

    • Age: 1
    • Duration: 0.221
    • Error Details: AssertionError: Expected exit code to be 0, but it was 1
  • Name: Build and Test / Libbeat / Libbeat oss / test_dev_tool_export_dashboard_from_yml – libbeat.tests.system.test_dashboard.Test

    • Age: 1
    • Duration: 0.192
    • Error Details: AssertionError: Expected exit code to be 0, but it was 1
  • Name: Build and Test / Libbeat / Libbeat oss / test_export_dashboard_cmd_export_dashboard_by_id – libbeat.tests.system.test_dashboard.Test

    • Age: 1
    • Duration: 0.213
    • Error Details: AssertionError: Expected exit code to be 0, but it was 1
  • Name: Build and Test / Libbeat / Libbeat oss / test_export_dashboard_cmd_export_dashboard_by_id_and_decoding – libbeat.tests.system.test_dashboard.Test

    • Age: 1
    • Duration: 0.21
    • Error Details: AssertionError: Expected exit code to be 0, but it was 1
  • Name: Build and Test / Libbeat / Libbeat oss / test_export_dashboard_cmd_export_dashboard_from_yml – libbeat.tests.system.test_dashboard.Test

    • Age: 1
    • Duration: 0.15
    • Error Details: AssertionError: Expected exit code to be 0, but it was 1
  • Name: Build and Test / Libbeat / Libbeat oss / test_load_dashboard – libbeat.tests.system.test_dashboard.Test

    • Age: 1
    • Duration: 0.227
    • Error Details: AssertionError: Expected exit code to be 0, but it was 1
  • Name: Build and Test / Libbeat / Libbeat oss / test_load_dashboard_into_space – libbeat.tests.system.test_dashboard.Test

    • Age: 1
    • Duration: 0.696
    • Error Details: AssertionError: Expected exit code to be 0, but it was 1
  • Name: Build and Test / Libbeat / Libbeat oss / test_load_only_index_patterns – libbeat.tests.system.test_dashboard.Test

    • Age: 1
    • Duration: 0.217
    • Error Details: AssertionError: Expected exit code to be 0, but it was 1
  • Name: Build and Test / Libbeat / Libbeat oss / test_load_without_dashboard – libbeat.tests.system.test_dashboard.Test

    • Age: 1
    • Duration: 0.226
    • Error Details: AssertionError: Expected exit code to be 0, but it was 1

Steps errors

Expand to view the steps failures

  • Name: Mage build test

    • Description: mage build test

    • Duration: 29 min 42 sec

    • Start Time: 2020-08-24T02:03:33.769+0000

    • log

  • Name: Mage build test

    • Description: mage build test

    • Duration: 12 min 59 sec

    • Start Time: 2020-08-24T02:03:45.112+0000

    • log

  • Name: Mage build test

    • Description: mage build test

    • Duration: 33 min 21 sec

    • Start Time: 2020-08-24T02:03:52.442+0000

    • log

Log output

Expand to view the last 100 lines of log output

[2020-08-24T02:46:02.249Z] + tar --version
[2020-08-24T02:46:02.549Z] + tar -xpf source.tgz
[2020-08-24T02:46:12.888Z] + rm source.tgz
[2020-08-24T02:46:12.902Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats
[2020-08-24T02:46:12.926Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Lint
[2020-08-24T02:46:13.013Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Elastic-Agent-Mac-OS-X
[2020-08-24T02:46:13.099Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Elastic-Agent-x-pack
[2020-08-24T02:46:13.184Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Winlogbeat-oss
[2020-08-24T02:46:13.277Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Auditbeat-x-pack-Mac-OS-X
[2020-08-24T02:46:13.359Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Auditbeat-oss-Mac-OS-X
[2020-08-24T02:46:13.450Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Auditbeat-crosscompile
[2020-08-24T02:46:13.539Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/dockerlogbeat
[2020-08-24T02:46:13.634Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Journalbeat
[2020-08-24T02:46:13.720Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Generators-Metricbeat-Linux
[2020-08-24T02:46:13.806Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Functionbeat-x-pack
[2020-08-24T02:46:13.894Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Filebeat-x-pack-Mac-OS-X
[2020-08-24T02:46:13.985Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Filebeat-Mac-OS-X
[2020-08-24T02:46:14.065Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Packetbeat-Linux
[2020-08-24T02:46:14.149Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-x-pack-Mac-OS-X
[2020-08-24T02:46:14.232Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Functionbeat-Mac-OS-X-x-pack
[2020-08-24T02:46:14.313Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Elastic-Agent-x-pack-Windows
[2020-08-24T02:46:14.398Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Heartbeat-Mac-OS-X
[2020-08-24T02:46:14.478Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Packetbeat-Mac-OS-X
[2020-08-24T02:46:14.567Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-OSS-Unit-tests
[2020-08-24T02:46:14.659Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Generators-Beat-Mac-OS-X
[2020-08-24T02:46:14.740Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Auditbeat-oss-Windows
[2020-08-24T02:46:14.823Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Heartbeat-oss
[2020-08-24T02:46:14.908Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Auditbeat-x-pack-Windows
[2020-08-24T02:46:14.986Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Heartbeat-Windows
[2020-08-24T02:46:15.063Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Generators-Metricbeat-Mac-OS-X
[2020-08-24T02:46:15.144Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Winlogbeat-Windows-x-pack
[2020-08-24T02:46:15.227Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-crosscompile
[2020-08-24T02:46:15.308Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Auditbeat-x-pack
[2020-08-24T02:46:15.388Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Auditbeat-oss-Linux
[2020-08-24T02:46:15.469Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Filebeat-x-pack-Windows
[2020-08-24T02:46:15.552Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Libbeat-x-pack
[2020-08-24T02:46:15.635Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Filebeat-Windows
[2020-08-24T02:46:15.716Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Functionbeat-Windows
[2020-08-24T02:46:15.800Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Packetbeat-Windows
[2020-08-24T02:46:15.880Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Winlogbeat-Windows
[2020-08-24T02:46:15.961Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-x-pack-Windows
[2020-08-24T02:46:16.047Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-Windows
[2020-08-24T02:46:16.127Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Generators-Beat-Linux
[2020-08-24T02:46:16.216Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Filebeat-oss
[2020-08-24T02:46:16.301Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Filebeat-x-pack
[2020-08-24T02:46:16.384Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Libbeat-oss
[2020-08-24T02:46:16.465Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-OSS-Go-Integration-tests
[2020-08-24T02:46:16.549Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-OSS-Python-Integration-tests
[2020-08-24T02:46:16.639Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-Mac-OS-X
[2020-08-24T02:46:16.721Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-x-pack
[2020-08-24T02:46:17.125Z] + cat
[2020-08-24T02:46:17.125Z] + /usr/local/bin/runbld ./runbld-script --job-name elastic+beats+pull-request
[2020-08-24T02:46:17.125Z] Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF8
[2020-08-24T02:46:23.744Z] runbld>>> runbld started
[2020-08-24T02:46:23.744Z] runbld>>> 1.6.12/f45d832f2ba0aa2722ab4ec1fda8ad140f027f8b
[2020-08-24T02:46:24.693Z] runbld>>> The following profiles matched the job 'elastic+beats+pull-request' in order of occurrence in the config (last value wins).
[2020-08-24T02:46:24.693Z] runbld>>> Matches in the system config:
[2020-08-24T02:46:24.693Z] runbld>>> - Matched ^elastic\+beats
[2020-08-24T02:46:24.693Z] runbld>>> - Matched ^elastic\+beats\+pull-request
[2020-08-24T02:46:26.084Z] runbld>>> Debug logging enabled.
[2020-08-24T02:46:26.084Z] runbld>>> Storing result
[2020-08-24T02:46:26.084Z] runbld>>> Store result: created {:total 2, :successful 2, :failed 0} 1
[2020-08-24T02:46:26.084Z] runbld>>> BUILD: https://c150076387b5421f9154dfbf536e5c60.us-west1.gcp.cloud.es.io:9243/build-1597739501209/t/20200824024625-31F12A87
[2020-08-24T02:46:26.084Z] runbld>>> Adding system facts.
[2020-08-24T02:46:27.032Z] runbld>>> Adding vcs info for the latest commit:  b771830f2717cc4f92e6dc3c5131db9c495e9870
[2020-08-24T02:46:27.032Z] runbld>>> >>>>>>>>>>>> SCRIPT EXECUTION BEGIN >>>>>>>>>>>>
[2020-08-24T02:46:27.032Z] runbld>>> Adding /usr/lib/jvm/java-8-openjdk-amd64/bin to the path.
[2020-08-24T02:46:27.295Z] + echo 'Processing JUnit reports with runbld...'
[2020-08-24T02:46:27.295Z] Processing JUnit reports with runbld...
[2020-08-24T02:46:27.557Z] runbld>>> <<<<<<<<<<<< SCRIPT EXECUTION END <<<<<<<<<<<<
[2020-08-24T02:46:27.557Z] runbld>>> DURATION: 35ms
[2020-08-24T02:46:27.557Z] runbld>>> STDOUT: 40 bytes
[2020-08-24T02:46:27.557Z] runbld>>> STDERR: 49 bytes
[2020-08-24T02:46:27.557Z] runbld>>> WRAPPED PROCESS: SUCCESS (0)
[2020-08-24T02:46:27.557Z] runbld>>> Searching for build metadata in /var/lib/jenkins/workspace/Beats_beats_PR-20678
[2020-08-24T02:46:28.504Z] runbld>>> Storing build metadata: 
[2020-08-24T02:46:28.504Z] runbld>>> Adding test report.
[2020-08-24T02:46:28.504Z] runbld>>> Searching for junit test output files with the pattern: TEST-.*\.xml$ in: /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats
[2020-08-24T02:46:29.086Z] runbld>>> Found 137 test output files
[2020-08-24T02:46:31.013Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-x-pack/x-pack/metricbeat/build/TEST-go-integration-openmetrics.xml
[2020-08-24T02:46:31.013Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-x-pack/x-pack/metricbeat/build/TEST-go-integration-activemq.xml
[2020-08-24T02:46:31.013Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-x-pack/x-pack/metricbeat/build/TEST-go-integration-iis.xml
[2020-08-24T02:46:31.013Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-x-pack/x-pack/metricbeat/build/TEST-go-integration-istio.xml
[2020-08-24T02:46:31.013Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-x-pack/x-pack/metricbeat/build/TEST-go-integration-tomcat.xml
[2020-08-24T02:46:31.013Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-OSS-Go-Integration-tests/metricbeat/build/TEST-go-integration-graphite.xml
[2020-08-24T02:46:31.275Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-20678/src/github.com/elastic/beats/Metricbeat-OSS-Go-Integration-tests/metricbeat/build/TEST-go-integration-windows.xml
[2020-08-24T02:46:32.668Z] runbld>>> Test output logs contained: Errors: 0 Failures: 12 Tests: 19694 Skipped: 1575
[2020-08-24T02:46:32.668Z] runbld>>> Storing result
[2020-08-24T02:46:32.668Z] runbld>>> FAILURES: 12
[2020-08-24T02:46:35.220Z] runbld>>> Store result: updated {:total 2, :successful 2, :failed 0} 2
[2020-08-24T02:46:35.220Z] runbld>>> BUILD: https://c150076387b5421f9154dfbf536e5c60.us-west1.gcp.cloud.es.io:9243/build-1597739501209/t/20200824024625-31F12A87
[2020-08-24T02:46:35.220Z] runbld>>> Email notification disabled by environment variable.
[2020-08-24T02:46:35.220Z] runbld>>> Slack notification disabled by environment variable.
[2020-08-24T02:46:41.357Z] Running on Jenkins in /var/lib/jenkins/workspace/Beats_beats_PR-20678
[2020-08-24T02:46:41.626Z] [INFO] getVaultSecret: Getting secrets
[2020-08-24T02:46:41.682Z] Masking supported pattern matches of $VAULT_ADDR or $VAULT_ROLE_ID or $VAULT_SECRET_ID
[2020-08-24T02:46:42.485Z] + chmod 755 generate-build-data.sh
[2020-08-24T02:46:42.485Z] + ./generate-build-data.sh https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Beats/beats/PR-20678/ https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Beats/beats/PR-20678/runs/2 FAILURE 3965638
[2020-08-24T02:46:42.485Z] INFO: curl https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Beats/beats/PR-20678/runs/2/steps/?limit=10000 -o steps-info.json
[2020-08-24T02:46:44.968Z] INFO: curl https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Beats/beats/PR-20678/runs/2/tests/?status=FAILED -o tests-errors.json

@kaiyan-sheng
Copy link
Contributor

Could you run mage fmt update on x-pack/heartbeat here and then I don't need to cherry-pick #20681 😬 Thanks!!

* Add template for ssl config reference settings

Use a shared template for the ssl options in reference configs. The reduces
duplication of the SSL settings in config templates and ensures that the
reference configs are consistent across outputs and monitoring.

I provided an `indent` function in case this config template needed to be reused
at various indentation levels, but it turns out that all of the uses so far required
an indentation of 2 (so I could have just indented ssl.reference.yml.tmpl manually).

* Indent any non-whitespace containing lines

(cherry picked from commit 9e4d4f2)
@andrewkroh andrewkroh merged commit 96b5843 into elastic:7.x Aug 24, 2020
@zube zube bot removed the [zube]: Done label Nov 23, 2020
@andrewkroh andrewkroh deleted the backport_20357_7.x branch January 14, 2022 14:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport Team:Integrations Label for the Integrations team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants