Skip to content

Commit

Permalink
Merge branch '8.16' into backport/8.16/pr-205619
Browse files Browse the repository at this point in the history
  • Loading branch information
elasticmachine authored Jan 7, 2025
2 parents 5780a33 + 1fd0eb1 commit c256264
Show file tree
Hide file tree
Showing 6 changed files with 53 additions and 8 deletions.
13 changes: 13 additions & 0 deletions .buildkite/pipeline-utils/buildkite/emitPipeline.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the "Elastic License
* 2.0", the "GNU Affero General Public License v3.0 only", and the "Server Side
* Public License v 1"; you may not use this file except in compliance with, at
* your election, the "Elastic License 2.0", the "GNU Affero General Public
* License v3.0 only", or the "Server Side Public License, v 1".
*/

export function emitPipeline(pipelineSteps: string[]) {
const pipelineStr = [...new Set(pipelineSteps)].join('\n');
console.log(pipelineStr);
}
1 change: 1 addition & 0 deletions .buildkite/pipeline-utils/buildkite/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@

export * from './client';
export * from './types';
export * from './emitPipeline';
4 changes: 4 additions & 0 deletions .buildkite/pipelines/on_merge_unsupported_ftrs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ steps:
machineType: n2-standard-4
preemptible: true
depends_on: build
env:
PING_SLACK_TEAM: "@obs-ux-infra_services-team"
timeout_in_minutes: 120
retry:
automatic:
Expand All @@ -54,6 +56,8 @@ steps:
machineType: n2-standard-4
preemptible: true
depends_on: build
env:
PING_SLACK_TEAM: "@obs-ux-infra_services-team"
timeout_in_minutes: 120
retry:
automatic:
Expand Down
8 changes: 8 additions & 0 deletions .buildkite/scripts/lifecycle/post_command.sh
Original file line number Diff line number Diff line change
Expand Up @@ -52,4 +52,12 @@ if [[ "$IS_TEST_EXECUTION_STEP" == "true" ]]; then
buildkite-agent artifact upload 'target/test_failures/**/*'
ts-node .buildkite/scripts/lifecycle/annotate_test_failures.ts
fi

fi

if [[ $BUILDKITE_COMMAND_EXIT_STATUS -ne 0 ]]; then
# If the slack team environment variable is set, ping the team in slack
if [ -n "${PING_SLACK_TEAM:-}" ]; then
buildkite-agent meta-data set 'slack:ping_team:body' "${PING_SLACK_TEAM}, can you please take a look at the test failures?"
fi
fi
24 changes: 18 additions & 6 deletions .buildkite/scripts/pipelines/pull_request/pipeline.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,22 @@
* License v3.0 only", or the "Server Side Public License, v 1".
*/

/* eslint "no-restricted-syntax": [
"error",
{
"selector": "CallExpression[callee.object.name='console'][callee.property.name!=/^(warn|error)$/]",
"message": "Debug logging to stdout in this file will attempt to upload the log message as yaml to buildkite, which might result in pipeline syntax error. Use emitPipeline() to upload steps, or log to stderr."
}
] */

import fs from 'fs';
import prConfigs from '../../../pull_requests.json';
import { areChangesSkippable, doAnyChangesMatch, getAgentImageConfig } from '#pipeline-utils';
import {
areChangesSkippable,
doAnyChangesMatch,
getAgentImageConfig,
emitPipeline,
} from '#pipeline-utils';

const prConfig = prConfigs.jobs.find((job) => job.pipelineSlug === 'kibana-pull-request');
const emptyStep = `steps: []`;
Expand All @@ -35,7 +48,7 @@ const getPipeline = (filename: string, removeSteps = true) => {
const skippable = await areChangesSkippable(SKIPPABLE_PR_MATCHERS, REQUIRED_PATHS);

if (skippable) {
console.log(emptyStep);
emitPipeline([emptyStep]);
return;
}

Expand All @@ -44,8 +57,8 @@ const getPipeline = (filename: string, removeSteps = true) => {
const onlyRunQuickChecks = await areChangesSkippable([/^renovate\.json$/], REQUIRED_PATHS);
if (onlyRunQuickChecks) {
pipeline.push(getPipeline('.buildkite/pipelines/pull_request/renovate.yml', false));

console.log([...new Set(pipeline)].join('\n'));
console.warn('Isolated changes to renovate.json. Skipping main PR pipeline.');
emitPipeline(pipeline);
return;
}

Expand Down Expand Up @@ -325,8 +338,7 @@ const getPipeline = (filename: string, removeSteps = true) => {

pipeline.push(getPipeline('.buildkite/pipelines/pull_request/post_build.yml'));

// remove duplicated steps
console.log([...new Set(pipeline)].join('\n'));
emitPipeline(pipeline);
} catch (ex) {
console.error('Error while generating the pipeline steps: ' + ex.message, ex);
process.exit(1);
Expand Down
11 changes: 9 additions & 2 deletions docs/user/dashboard/create-visualizations.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ Use one of the editors to create visualizations of your data. Each editor offers
| <<add-image,Image>>
| Personalize your dashboard with custom images


| <<dashboard-links,Links>>
| Add links to other dashboards or to external websites

Expand Down Expand Up @@ -278,7 +279,14 @@ For detailed information about writing on GitHub, click *Help* on the top-right
[[add-image]]
== Image panels

To personalize your dashboards, add your own logos and graphics with the *Image* panel. You can upload images from your computer, select previously uploaded images, or add images from an external link.
To personalize your dashboards, add your own logos and graphics with the *Image* panel.

[IMPORTANT]
====
Image uploads are limited to 10 MiB.
====

You can upload images from your computer, select previously uploaded images, or add images from an external link.

. From your dashboard, select *Add panel*.

Expand All @@ -292,7 +300,6 @@ image::images/dashboard_addImageEditor_8.7.0.png[Add image editor]
To manage your uploaded image files, go to the *Files* management page using the navigation menu or the
<<kibana-navigation-search,global search field>>.


[WARNING]
============================================================================
When you export a dashboard, the uploaded image files are not exported.
Expand Down

0 comments on commit c256264

Please sign in to comment.