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

[CI] Add skeleton for integrations on Windows #1713

Closed

Conversation

v1v
Copy link
Member

@v1v v1v commented Sep 13, 2021

What does this PR do?

Refactor pipeline to support windows integrations. It requires to implement isIntegrationForWindows

Checklist

  • I have reviewed tips for building integrations and this pull request is aligned with them.
  • I have verified that all data streams collect metrics or logs.
  • I have added an entry to my package's changelog.yml file.
  • If I'm introducing a new feature, I have modified the Kibana version constraint in my package's manifest.yml file to point to the latest Elastic stack release (e.g. ^7.13.0).

Author's Checklist

  • [ ]

How to test this PR locally

Related issues

Screenshots

@elasticmachine
Copy link

elasticmachine commented Sep 13, 2021

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview preview

Expand to view the summary

Build stats

  • Start Time: 2022-05-18T13:28:14.000+0000

  • Duration: 96 min 38 sec

Test stats 🧪

Test Results
Failed 0
Passed 4967
Skipped 7
Total 4974

🤖 GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

@v1v
Copy link
Member Author

v1v commented Sep 23, 2021

@marc-gr , windows-2019-docker-immutable CI workers are now in place, and docker is available on windows (see here )

@marc-gr marc-gr force-pushed the feature/refactor-to-support-windows-integrations branch from b636a52 to 62b5b5a Compare October 6, 2021 11:17
@marc-gr marc-gr force-pushed the feature/refactor-to-support-windows-integrations branch from 62b5b5a to 30610b4 Compare October 6, 2021 11:20
v1v added 2 commits October 6, 2021 12:29
…thub.com:v1v/integrations into feature/refactor-to-support-windows-integrations

* 'feature/refactor-to-support-windows-integrations' of github.com:v1v/integrations: (200 commits)
  [CI] Draft for windows system tests
  [journald] Create custom journald input package (elastic#1739)
  [Microsoft_DHCP] New package replacing old RSA2ELK DHCP package (elastic#1793)
  Fix contains check for forwarded tag (elastic#1861)
  [google_workspace] Fix contains check for forwarded tag (elastic#1819)
  Fix contains check for forwarded tag (elastic#1805)
  Fix contains check for forwarded tag (elastic#1815)
  Fix contains check for forwarded tag (elastic#1816)
  Fix contains check for forwarded tag (elastic#1817)
  Fix contains check for forwarded tag (elastic#1818)
  Fix contains check for forwarded tag (elastic#1820)
  Fix contains check for forwarded tag (elastic#1821)
  Fix contains check for forwarded tag (elastic#1822)
  Fix contains check for forwarded tag (elastic#1823)
  Fix contains check for forwarded tag (elastic#1824)
  Fix contains check for forwarded tag (elastic#1825)
  Fix contains check for forwarded tag (elastic#1826)
  Fix contains check for forwarded tag (elastic#1827)
  Fix contains check for forwarded tag (elastic#1828)
  Fix contains check for forwarded tag (elastic#1829)
  ...
.ci/Jenkinsfile Outdated

def runWindowsSystemTests(name) {
return {
def linuxIp = grabWorkerIP()
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Look for the ip in the current linux worker.

.ci/Jenkinsfile Outdated
Comment on lines 154 to 155
// TODO: run the stack that's needed

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

prepare the context in the linux worker (services and so on)

.ci/Jenkinsfile Outdated
Comment on lines 157 to 159
def envContext = []
envContext.add("KIBANA_URL=https://${linuxIp}:5601")
envContext.add("ELASTICSEARCH_URL=https://${linuxIp}:9200")
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Setup the environment variables fro the services that run in the linux worker then the windows worker will consume them

.ci/Jenkinsfile Outdated
Comment on lines 163 to 167
// TOOD use the batch syntax in the pipelien and in the script
sh(label: "Test integration: ${name}", script: '''
eval "$(../../build/elastic-package stack shellinit)"
../../build/elastic-package test -v --report-format xUnit --report-output file --test-coverage
''')
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is needed to be changed to be Windows based

envContext.add("ELASTICSEARCH_URL=https://${linuxIp}:9200")

withNode(labels: 'windows-2019 && docker && immutable', sleepMin: 10, sleepMax: 100) {
withEnv(envContext) {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Load the above defined environment variables that contain the IP of the linux worker

@elasticmachine
Copy link

elasticmachine commented May 10, 2022

🌐 Coverage report

Name Metrics % (covered/total) Diff
Packages 100.0% (243/243) 💚
Files 96.42% (404/419) 👍
Classes 96.42% (404/419) 👍
Methods 88.342% (4198/4752) 👍
Lines 89.035% (73421/82463) 👍
Conditionals 100.0% (0/0) 💚

@botelastic
Copy link

botelastic bot commented Sep 19, 2022

Hi! We just realized that we haven't looked into this PR in a while. We're sorry! We're labeling this issue as Stale to make it hit our filters and make sure we get back to it as soon as possible. In the meantime, it'd be extremely helpful if you could take a look at it as well and confirm its relevance. A simple comment with a nice emoji will be enough :+1. Thank you for your contribution!

@botelastic botelastic bot added the Stalled label Sep 19, 2022
@v1v
Copy link
Member Author

v1v commented Sep 20, 2022

I'll close this PR, you can freely reopen it if this integration is something needed in the future

@v1v v1v closed this Sep 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants