-
Notifications
You must be signed in to change notification settings - Fork 8.6k
Setup E2E against Serverless ES, Kibana, Fleet server standalone and Elastic endpoint agent in VM #167720
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
Setup E2E against Serverless ES, Kibana, Fleet server standalone and Elastic endpoint agent in VM #167720
Changes from all commits
58871f7
fa16f43
cc22a07
62001bd
0eb2ccc
30be411
421188e
d6105f8
97f8211
c73a905
72439fb
b331b7f
dfbaf91
a7af0a8
0e5d548
902e647
5c1c5be
1e34539
9b906ee
59b921f
797b5e6
1a1167e
a21cb1a
d0dc156
d009b64
70af4d9
170fe9e
2dac722
955b554
9ad98d6
6073ba1
fbce75b
b215d57
6ad077d
954eecb
e21f80b
ba9099c
754c8dd
83a68c2
ad32340
8efc7c4
94b77e1
66aa351
e2c4e7d
dd06e98
1f1d5d4
1c22314
e90214b
9a62a62
7adac99
bea13b4
ec4aaa7
fa0292c
e24a8b3
be6b0e5
d471bee
fe33b5b
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -56,6 +56,8 @@ export interface DockerOptions extends EsClusterExecOptions, BaseOptions { | |
| } | ||
|
|
||
| export interface ServerlessOptions extends EsClusterExecOptions, BaseOptions { | ||
| /** Publish ES docker container on additional host IP */ | ||
| host?: string; | ||
| /** Clean (or delete) all data created by the ES cluster after it is stopped */ | ||
| clean?: boolean; | ||
| /** Path to the directory where the ES cluster will store data */ | ||
|
|
@@ -306,19 +308,21 @@ export function resolveDockerImage({ | |
| } | ||
|
|
||
| /** | ||
| * Determine the port to bind the Serverless index node or Docker node to | ||
| * Determine the port and optionally an additional host to bind the Serverless index node or Docker node to | ||
| */ | ||
| export function resolvePort(options: ServerlessOptions | DockerOptions) { | ||
| const port = options.port || DEFAULT_PORT; | ||
| const value = ['-p', `127.0.0.1:${port}:${port}`]; | ||
|
|
||
| if ((options as ServerlessOptions).host) { | ||
| value.push('-p', `${(options as ServerlessOptions).host}:${port}:${port}`); | ||
| } | ||
|
Comment on lines
+317
to
+319
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Just curious if this change needed for Cypress tests or as a general capability to improve developer UX?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this change is needed to improve dev UX, mostly in case we want to set elastic-agent on a dedicated VM outside of the Docker network
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @dmlemeshko updated description, please let me know if that works |
||
|
|
||
| if (options.port) { | ||
| return [ | ||
| '-p', | ||
| `127.0.0.1:${options.port}:${options.port}`, | ||
| '--env', | ||
| `http.port=${options.port}`, | ||
| ]; | ||
| value.push('--env', `http.port=${options.port}`); | ||
| } | ||
|
|
||
| return ['-p', `127.0.0.1:${DEFAULT_PORT}:${DEFAULT_PORT}`]; | ||
| return value; | ||
| } | ||
|
|
||
| /** | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -30,7 +30,7 @@ const loginWithoutAccess = (url: string) => { | |
| loadPage(url); | ||
| }; | ||
|
|
||
| describe('Artifacts pages', { tags: '@ess' }, () => { | ||
| describe('Artifacts pages', { tags: ['@ess', '@serverless', '@brokenInServerless'] }, () => { | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is the test really broken in Serverless or you wanna just skip it for now?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. to me, it seems both tags are doing the same, maybe we could simplify and just have one tag for both use cases? |
||
| before(() => { | ||
| login(); | ||
| loadEndpointDataForEventFiltersIfNeeded(); | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -18,7 +18,7 @@ import { cleanupRule, generateRandomStringName, loadRule } from '../../tasks/api | |
| import { RESPONSE_ACTION_TYPES } from '../../../../../common/api/detection_engine'; | ||
| import { login, ROLE } from '../../tasks/login'; | ||
|
|
||
| describe('Form', { tags: '@ess' }, () => { | ||
| describe('Form', { tags: ['@ess', '@serverless', '@brokenInServerless'] }, () => { | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is the test really broken in Serverless or you wanna just skip it for now? |
||
| describe('User with no access can not create an endpoint response action', () => { | ||
| before(() => { | ||
| login(ROLE.endpoint_response_actions_no_access); | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we add this to the cli
--helpto https://github.com/elastic/kibana/blob/main/packages/kbn-es/src/cli_commands/serverless.ts#L37?