Skip to content

Commit

Permalink
logstash-output-opensearch/2.0.3 package update (#33203)
Browse files Browse the repository at this point in the history
<p align="center">
<img
src="https://raw.githubusercontent.com/wolfi-dev/.github/b535a42419ce0edb3c144c0edcff55a62b8ec1f8/profile/wolfi-logo-light-mode.svg"
/>
</p>

---------

Signed-off-by: wolfi-bot <[email protected]>
Signed-off-by: Jason Hall <[email protected]>
Co-authored-by: wolfi-bot <[email protected]>
Co-authored-by: Jason Hall <[email protected]>
  • Loading branch information
3 people authored Dec 12, 2024
1 parent 26c763f commit 1bae9da
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 3 deletions.
19 changes: 16 additions & 3 deletions logstash-output-opensearch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,13 @@
#
package:
name: logstash-output-opensearch
version: 2.0.2
epoch: 1
version: 2.0.3
epoch: 0
description: Logstash - transport and process your logs, events, or other data
copyright:
- license: Apache-2.0
resources:
memory: 12Gi

environment:
contents:
Expand All @@ -26,6 +28,9 @@ environment:
- openjdk-17-default-jvm
environment:
JAVA_HOME: /usr/lib/jvm/default-jvm
JRUBY_OPTS: "-J-Xmx8g"
JAVA_OPTS: "-Xmx10g"
LS_JAVA_OPTS: "-Xmx10g"

vars:
gem: logstash-output-opensearch
Expand All @@ -36,7 +41,10 @@ pipeline:
with:
repository: https://github.com/opensearch-project/logstash-output-opensearch
tag: ${{package.version}}
expected-commit: 844fb28d9e148e4042563d277b8e4c8a63392f81
expected-commit: 087d252a6d4a4f329fb45863bdc3e850dbd90739
- uses: patch
with:
patches: Fix-build-remove-signing_key-from-gemspec.patch
- uses: ruby/build
with:
gem: ${{vars.gem}}
Expand All @@ -54,6 +62,11 @@ test:
packages:
- logstash
- openjdk-17-default-jvm
environment:
JAVA_HOME: /usr/lib/jvm/default-jvm
JRUBY_OPTS: "-J-Xmx8g"
JAVA_OPTS: "-Xmx10g"
LS_JAVA_OPTS: "-Xmx10g"
pipeline:
- runs: |
logstash-plugin install $(find / -type f -name "${{package.name}}-*.gem")
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
From 1fb62fa9602377cbc69fd35d91233577c4cf075a Mon Sep 17 00:00:00 2001
From: debasishbsws <[email protected]>
Date: Tue, 26 Nov 2024 11:48:36 +0000
Subject: [PATCH] Fix(build): remove signing_key from gemspec

Our ruby/build pipeline delete all the lines contains 'signing_key' by default since it leads to build failures as the key is not available in the build environment and is not needed. ref: https://github.com/chainguard-dev/melange/blob/main/pkg/build/pipelines/ruby/build.yaml#L42

But for version 2.0.3 and later it resutls in syntax error, unexpected end as it removes the condition line but not the full condition.

Signed-off-by: debasishbsws <[email protected]>
---
logstash-output-opensearch.gemspec | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/logstash-output-opensearch.gemspec b/logstash-output-opensearch.gemspec
index cd04d97..1b0af3d 100644
--- a/logstash-output-opensearch.gemspec
+++ b/logstash-output-opensearch.gemspec
@@ -29,10 +29,7 @@ Gem::Specification.new do |s|
# Tests
s.test_files = s.files.grep(%r{^(test|spec|features)/})

- if $PROGRAM_NAME.end_with?("gem") && ARGV == ["build", __FILE__] && File.exist?(signing_key_path)
- s.signing_key = signing_key_path
- s.cert_chain = ['certs/opensearch-rubygems.pem']
- end
+ s.cert_chain = ['certs/opensearch-rubygems.pem']

# Special flag to let us know this is actually a logstash plugin
s.metadata = {
--
2.47.1

0 comments on commit 1bae9da

Please sign in to comment.