systemd-journal 1.4.1 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.github/workflows/ruby.yml +20 -0
- data/.gitignore +2 -0
- data/README.md +26 -19
- data/Rakefile +8 -1
- data/ext/shim/extconf.rb +10 -0
- data/ext/shim/shim.c +25 -0
- data/ext/shim/shim.h +6 -0
- data/lib/systemd/journal/native.rb +0 -9
- data/lib/systemd/journal/version.rb +1 -1
- data/lib/systemd/journal/writable.rb +1 -1
- data/lib/systemd/journal.rb +2 -1
- data/spec/systemd/journal_spec.rb +12 -2
- data/systemd-journal.gemspec +9 -14
- metadata +45 -53
- checksums.yaml.gz.sig +0 -0
- data/Dockerfile.bionic +0 -19
- data/Dockerfile.centos +0 -11
- data/Dockerfile.xenial +0 -19
- data/certs/john@throttle.io.pem +0 -21
- data.tar.gz.sig +0 -0
- metadata.gz.sig +0 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: e5c615cee8de41012105d99aec5b93f8c88f322b67bbf4d97bcb4afbd74cec35
|
4
|
+
data.tar.gz: 84447c503addd9fc6c3c6564472e7eb1558f6e6a184a98214c604feb2649ecea
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dd1375594a013f9d237c0a62f5c4aed77f80b54637e1275cf32565905fde72187eb08feefc4d93129a3a942949de93d2f037b0af2893e95f52c006d682e32b39
|
7
|
+
data.tar.gz: 9debfc4954cc65ddf9fda2d448c30b67c0995cf2ad554dcfb00b067103218a5898d8d9f619e6b04236d184742397d64b5365efbbd90cb0be6f26a25cbeb8887b
|
@@ -0,0 +1,20 @@
|
|
1
|
+
name: RSpec Matrix
|
2
|
+
on: [push]
|
3
|
+
jobs:
|
4
|
+
test:
|
5
|
+
strategy:
|
6
|
+
fail-fast: false
|
7
|
+
matrix:
|
8
|
+
os: [ubuntu]
|
9
|
+
ruby: [3.0, 3.1, 3.2, 3.3]
|
10
|
+
runs-on: ${{ matrix.os }}-latest
|
11
|
+
steps:
|
12
|
+
- uses: actions/checkout@v2
|
13
|
+
- uses: ruby/setup-ruby@v1
|
14
|
+
with:
|
15
|
+
ruby-version: ${{ matrix.ruby }}
|
16
|
+
- run: sudo apt-get install libjemalloc2 --yes
|
17
|
+
- run: bundle install
|
18
|
+
- run: bundle exec rake compile
|
19
|
+
- run: bundle exec rake spec
|
20
|
+
- run: LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libjemalloc.so.2 bundle exec rake spec
|
data/.gitignore
CHANGED
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
# Systemd::Journal [![Gem Version](https://badge.fury.io/rb/systemd-journal.png)](http://badge.fury.io/rb/systemd-journal)
|
1
|
+
# Systemd::Journal [![Gem Version](https://badge.fury.io/rb/systemd-journal.png)](http://badge.fury.io/rb/systemd-journal) [![Code Climate](https://codeclimate.com/github/ledbettj/systemd-journal.png)](https://codeclimate.com/github/ledbettj/systemd-journal)
|
2
2
|
|
3
3
|
Ruby bindings for reading from the systemd journal.
|
4
4
|
|
@@ -10,7 +10,7 @@ Ruby bindings for reading from the systemd journal.
|
|
10
10
|
Add this line to your application's Gemfile:
|
11
11
|
|
12
12
|
```ruby
|
13
|
-
gem 'systemd-journal', '~>
|
13
|
+
gem 'systemd-journal', '~> 2.0'
|
14
14
|
```
|
15
15
|
|
16
16
|
And then execute:
|
@@ -19,20 +19,6 @@ And then execute:
|
|
19
19
|
bundle install
|
20
20
|
```
|
21
21
|
|
22
|
-
If you have trust issues, fear not:
|
23
|
-
|
24
|
-
```sh
|
25
|
-
wget https://raw.githubusercontent.com/ledbettj/systemd-journal/master/certs/john@throttle.io.pem
|
26
|
-
gem cert --add john@throttle.io.pem
|
27
|
-
```
|
28
|
-
|
29
|
-
You can then verify the signature at install time with either `gem` or `bundler`:
|
30
|
-
|
31
|
-
```sh
|
32
|
-
gem install systemd-journal -P HighSecurity
|
33
|
-
bundle install --trust-policy HighSecurity
|
34
|
-
```
|
35
|
-
|
36
22
|
## Dependencies
|
37
23
|
|
38
24
|
Obviously you will need to have
|
@@ -151,15 +137,36 @@ The solution is to always call one of `move`, `move_next`, `move_previous` and
|
|
151
137
|
friends before reading after issuing one of the above calls. For most functions,
|
152
138
|
call `move_next`. For `seek(:tail)`, call `move_previous`.
|
153
139
|
|
140
|
+
### I get a segfault pointing at Native.sd_journal_get_fd
|
141
|
+
|
142
|
+
This is caused by a bug in libsystemd v245 (and maybe earlier) which cannot be
|
143
|
+
solved in this gem, sadly. It's fixed upstream in [this commit](https://github.com/systemd/systemd/commit/2b6df46d21abe8a8b7481e420588a9a129699cf9), which you can ask your distribution to backport if
|
144
|
+
necessary until v246 is released.
|
145
|
+
|
146
|
+
In ArchLinux, this patch is applied in systemd-libs 245.6-2.
|
147
|
+
|
148
|
+
### I don't get any output when reading from/into a container!
|
149
|
+
|
150
|
+
The most likely cause of this is a version mismatch between `libsystemd` on the
|
151
|
+
host and in the container, where the older version does not support features used
|
152
|
+
by the newer version. If you run `journalctl` you might see:
|
153
|
+
|
154
|
+
> Journal file ... uses an unsupported feature, ignoring file.
|
155
|
+
|
156
|
+
Sadly, this error case is not exposed via the `libsystemd` API so this gem does
|
157
|
+
not know when this happens. There are two potential workarounds:
|
158
|
+
|
159
|
+
* Ensure that the version of `libsystemd` are compatible across host/container
|
160
|
+
* Disable the features that are not supported by the older version to cause the
|
161
|
+
newer version to emit compatible journal files.
|
162
|
+
|
163
|
+
|
154
164
|
## Issues?
|
155
165
|
|
156
166
|
This gem has been tested primarily on MRI and Arch Linux running systemd version
|
157
167
|
208 and up. Please let me know if you have issues with other versions or
|
158
168
|
distributions.
|
159
169
|
|
160
|
-
The gem will run under JRuby, although some features which rely on native file
|
161
|
-
descriptor support will not work.
|
162
|
-
|
163
170
|
If you run into problems or have questions, please open an
|
164
171
|
[Issue](https://github.com/ledbettj/systemd-journal/issues) or Pull Request.
|
165
172
|
|
data/Rakefile
CHANGED
@@ -1,9 +1,10 @@
|
|
1
1
|
require 'bundler/gem_tasks'
|
2
2
|
require 'yard'
|
3
3
|
require 'rspec/core/rake_task'
|
4
|
+
require "rake/extensiontask"
|
4
5
|
|
5
6
|
unless ENV['RUBOCOP'] == 'false'
|
6
|
-
require 'rubocop/rake_task'
|
7
|
+
require 'rubocop/rake_task'
|
7
8
|
|
8
9
|
RuboCop::RakeTask.new(:rubocop) do |task|
|
9
10
|
task.patterns = ['lib/**/*.rb', 'spec/**/*.rb']
|
@@ -25,4 +26,10 @@ RSpec::Core::RakeTask.new(:spec) do |t|
|
|
25
26
|
t.rspec_opts = %w(--color)
|
26
27
|
end
|
27
28
|
|
29
|
+
GEMSPEC = Gem::Specification.load("systemd-journal.gemspec")
|
30
|
+
|
31
|
+
Rake::ExtensionTask.new("shim", GEMSPEC) do |ext|
|
32
|
+
ext.lib_dir = "lib/systemd/journal/"
|
33
|
+
end
|
34
|
+
|
28
35
|
task default: :spec
|
data/ext/shim/extconf.rb
ADDED
@@ -0,0 +1,10 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "mkmf"
|
4
|
+
|
5
|
+
# Makes all symbols private by default to avoid unintended conflict
|
6
|
+
# with other gems. To explicitly export symbols you can use RUBY_FUNC_EXPORTED
|
7
|
+
# selectively, or entirely remove this flag.
|
8
|
+
append_cflags("-fvisibility=hidden")
|
9
|
+
|
10
|
+
create_makefile("systemd/journal/shim")
|
data/ext/shim/shim.c
ADDED
@@ -0,0 +1,25 @@
|
|
1
|
+
#include "shim.h"
|
2
|
+
|
3
|
+
VALUE rb_mShim;
|
4
|
+
|
5
|
+
VALUE shim_free(VALUE self, VALUE ptr);
|
6
|
+
|
7
|
+
RUBY_FUNC_EXPORTED void
|
8
|
+
Init_shim(void)
|
9
|
+
{
|
10
|
+
VALUE mSystemd = rb_define_module("Systemd");
|
11
|
+
VALUE cJournal = rb_define_class_under(mSystemd, "Journal", rb_cObject);
|
12
|
+
rb_mShim = rb_define_module_under(cJournal, "Shim");
|
13
|
+
|
14
|
+
rb_define_module_function(rb_mShim, "free", shim_free, 1);
|
15
|
+
}
|
16
|
+
|
17
|
+
VALUE shim_free(VALUE self, VALUE ptr) {
|
18
|
+
VALUE rb_addr = rb_funcall(ptr, rb_intern("address"), 0);
|
19
|
+
void* addr = (void*)NUM2ULL(rb_addr);
|
20
|
+
if (addr) {
|
21
|
+
free(addr);
|
22
|
+
}
|
23
|
+
|
24
|
+
return Qnil;
|
25
|
+
}
|
data/ext/shim/shim.h
ADDED
@@ -86,13 +86,4 @@ module Systemd
|
|
86
86
|
attach_function :sd_journal_get_usage, [:pointer, :pointer], :int
|
87
87
|
end
|
88
88
|
end
|
89
|
-
|
90
|
-
# @private
|
91
|
-
module LibC
|
92
|
-
require 'ffi'
|
93
|
-
extend FFI::Library
|
94
|
-
ffi_lib FFI::Library::LIBC
|
95
|
-
|
96
|
-
attach_function :free, [:pointer], :void
|
97
|
-
end
|
98
89
|
end
|
@@ -66,7 +66,7 @@ module Systemd
|
|
66
66
|
# severity of the event.
|
67
67
|
# @param [String] message the content of the message to write.
|
68
68
|
def print(level, message)
|
69
|
-
rc = Native.sd_journal_print(level, message)
|
69
|
+
rc = Native.sd_journal_print(level, message.to_s.gsub('%', '%%'))
|
70
70
|
raise JournalError, rc if rc < 0
|
71
71
|
end
|
72
72
|
|
data/lib/systemd/journal.rb
CHANGED
@@ -6,6 +6,7 @@ require 'systemd/journal/fields'
|
|
6
6
|
require 'systemd/journal/navigable'
|
7
7
|
require 'systemd/journal/filterable'
|
8
8
|
require 'systemd/journal/waitable'
|
9
|
+
require 'systemd/journal/shim'
|
9
10
|
require 'systemd/journal_error'
|
10
11
|
require 'systemd/journal_entry'
|
11
12
|
require 'systemd/id128'
|
@@ -322,7 +323,7 @@ module Systemd
|
|
322
323
|
# frees the char*, and returns the ruby string.
|
323
324
|
def self.read_and_free_outstr(ptr)
|
324
325
|
str = ptr.read_string
|
325
|
-
|
326
|
+
Shim.free(ptr)
|
326
327
|
str
|
327
328
|
end
|
328
329
|
end
|
@@ -13,7 +13,7 @@ RSpec.describe Systemd::Journal do
|
|
13
13
|
expect(Systemd::Journal::Native).to receive(:sd_journal_close)
|
14
14
|
.and_call_original
|
15
15
|
|
16
|
-
result =
|
16
|
+
result = Systemd::Journal.open { 1 }
|
17
17
|
expect(result).to eq 1
|
18
18
|
end
|
19
19
|
|
@@ -21,7 +21,7 @@ RSpec.describe Systemd::Journal do
|
|
21
21
|
expect(Systemd::Journal::Native).to_not receive(:sd_journal_close)
|
22
22
|
|
23
23
|
expect do
|
24
|
-
|
24
|
+
Systemd::Journal.open(file: 1, path: 2, files: 3) { 1 }
|
25
25
|
end.to raise_error(ArgumentError)
|
26
26
|
end
|
27
27
|
end
|
@@ -438,4 +438,14 @@ RSpec.describe Systemd::Journal do
|
|
438
438
|
Systemd::Journal.message(message: 'hello % world %')
|
439
439
|
end
|
440
440
|
end
|
441
|
+
|
442
|
+
describe 'print' do
|
443
|
+
it 'escapes percent signs' do
|
444
|
+
expect(Systemd::Journal::Native).to receive(:sd_journal_print)
|
445
|
+
.with(Systemd::Journal::LOG_DEBUG, 'hello %% world %%')
|
446
|
+
.and_return(0)
|
447
|
+
|
448
|
+
Systemd::Journal.print(Systemd::Journal::LOG_DEBUG, 'hello % world %')
|
449
|
+
end
|
450
|
+
end
|
441
451
|
end
|
data/systemd-journal.gemspec
CHANGED
@@ -8,31 +8,26 @@ Gem::Specification.new do |gem|
|
|
8
8
|
gem.version = Systemd::Journal::VERSION
|
9
9
|
gem.license = 'MIT'
|
10
10
|
gem.authors = ['John Ledbetter', 'Daniel Mack']
|
11
|
-
gem.email = ['john@
|
11
|
+
gem.email = ['john@weirdhorse.party']
|
12
12
|
gem.description = 'Provides the ability to navigate and read entries from the systemd journal in ruby, as well as write events to the journal.'
|
13
13
|
gem.summary = 'Ruby bindings to libsystemd-journal'
|
14
14
|
gem.homepage = 'https://github.com/ledbettj/systemd-journal'
|
15
15
|
|
16
|
-
gem.cert_chain = Dir['certs/*']
|
17
|
-
|
18
|
-
if $PROGRAM_NAME.end_with?('gem')
|
19
|
-
gem.signing_key = ENV['GEM_SIGNING_KEY']
|
20
|
-
raise ArgumentError, 'Please set GEM_SIGNING_KEY' if gem.signing_key.nil?
|
21
|
-
end
|
22
|
-
|
23
16
|
gem.files = `git ls-files`.split($/)
|
24
17
|
gem.executables = gem.files.grep(%r{^bin/}).map { |f| File.basename(f) }
|
25
18
|
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
26
19
|
gem.require_paths = ['lib']
|
20
|
+
gem.extensions = ["ext/shim/extconf.rb"]
|
27
21
|
|
28
|
-
gem.required_ruby_version = '>=
|
22
|
+
gem.required_ruby_version = '>= 3.0'
|
29
23
|
|
30
24
|
gem.add_runtime_dependency 'ffi', '~> 1.9'
|
31
25
|
|
32
|
-
gem.add_development_dependency '
|
33
|
-
gem.add_development_dependency '
|
34
|
-
gem.add_development_dependency '
|
35
|
-
gem.add_development_dependency '
|
26
|
+
gem.add_development_dependency 'pry', '~> 0.14'
|
27
|
+
gem.add_development_dependency 'rake', '~> 13.1'
|
28
|
+
gem.add_development_dependency 'rspec', '~> 3.13'
|
29
|
+
gem.add_development_dependency 'rubocop', '~> 1.61' unless ENV['RUBOCOP'] == 'false'
|
30
|
+
gem.add_development_dependency 'simplecov', '~> 0.22'
|
36
31
|
gem.add_development_dependency 'yard', '~> 0.9'
|
37
|
-
gem.add_development_dependency '
|
32
|
+
gem.add_development_dependency 'rake-compiler'
|
38
33
|
end
|
metadata
CHANGED
@@ -1,37 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: systemd-journal
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 2.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- John Ledbetter
|
8
8
|
- Daniel Mack
|
9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rJd5OTNoMztU3k+1zsv4KzAkvqcp1TpJfTF54GLq4QXcUYaepxCTW
|
28
|
-
PUBdWX8cgjZePmJ005KT3MPtA//o1nATLyYWc86Xk02FI9f7h4K6lSHMUr/L2fVL
|
29
|
-
9DahKJje3A0xvOupPKojNqHRB8NPwOV7lbD9Na8vqymCxqahh6VYGreAHAmoFJLw
|
30
|
-
Hw1jejkkg22p795C8ajT+BVGkALv64eUKBcg43XRiEdURHk6N0a9hPeV+F0pXJSi
|
31
|
-
qFmZlFSs2UEGpMrcVelMgdQ5dBFzZ/SIvfYO70bQhRRae39Z/QmV0jEgYx5f2Q1d
|
32
|
-
bc0+je0pm4TYY6oC
|
33
|
-
-----END CERTIFICATE-----
|
34
|
-
date: 2019-03-25 00:00:00.000000000 Z
|
11
|
+
cert_chain: []
|
12
|
+
date: 2024-09-11 00:00:00.000000000 Z
|
35
13
|
dependencies:
|
36
14
|
- !ruby/object:Gem::Dependency
|
37
15
|
name: ffi
|
@@ -48,61 +26,75 @@ dependencies:
|
|
48
26
|
- !ruby/object:Gem::Version
|
49
27
|
version: '1.9'
|
50
28
|
- !ruby/object:Gem::Dependency
|
51
|
-
name:
|
29
|
+
name: pry
|
52
30
|
requirement: !ruby/object:Gem::Requirement
|
53
31
|
requirements:
|
54
32
|
- - "~>"
|
55
33
|
- !ruby/object:Gem::Version
|
56
|
-
version: '
|
34
|
+
version: '0.14'
|
57
35
|
type: :development
|
58
36
|
prerelease: false
|
59
37
|
version_requirements: !ruby/object:Gem::Requirement
|
60
38
|
requirements:
|
61
39
|
- - "~>"
|
62
40
|
- !ruby/object:Gem::Version
|
63
|
-
version: '
|
41
|
+
version: '0.14'
|
64
42
|
- !ruby/object:Gem::Dependency
|
65
|
-
name:
|
43
|
+
name: rake
|
66
44
|
requirement: !ruby/object:Gem::Requirement
|
67
45
|
requirements:
|
68
46
|
- - "~>"
|
69
47
|
- !ruby/object:Gem::Version
|
70
|
-
version: '
|
48
|
+
version: '13.1'
|
71
49
|
type: :development
|
72
50
|
prerelease: false
|
73
51
|
version_requirements: !ruby/object:Gem::Requirement
|
74
52
|
requirements:
|
75
53
|
- - "~>"
|
76
54
|
- !ruby/object:Gem::Version
|
77
|
-
version: '
|
55
|
+
version: '13.1'
|
56
|
+
- !ruby/object:Gem::Dependency
|
57
|
+
name: rspec
|
58
|
+
requirement: !ruby/object:Gem::Requirement
|
59
|
+
requirements:
|
60
|
+
- - "~>"
|
61
|
+
- !ruby/object:Gem::Version
|
62
|
+
version: '3.13'
|
63
|
+
type: :development
|
64
|
+
prerelease: false
|
65
|
+
version_requirements: !ruby/object:Gem::Requirement
|
66
|
+
requirements:
|
67
|
+
- - "~>"
|
68
|
+
- !ruby/object:Gem::Version
|
69
|
+
version: '3.13'
|
78
70
|
- !ruby/object:Gem::Dependency
|
79
71
|
name: rubocop
|
80
72
|
requirement: !ruby/object:Gem::Requirement
|
81
73
|
requirements:
|
82
74
|
- - "~>"
|
83
75
|
- !ruby/object:Gem::Version
|
84
|
-
version: '
|
76
|
+
version: '1.61'
|
85
77
|
type: :development
|
86
78
|
prerelease: false
|
87
79
|
version_requirements: !ruby/object:Gem::Requirement
|
88
80
|
requirements:
|
89
81
|
- - "~>"
|
90
82
|
- !ruby/object:Gem::Version
|
91
|
-
version: '
|
83
|
+
version: '1.61'
|
92
84
|
- !ruby/object:Gem::Dependency
|
93
|
-
name:
|
85
|
+
name: simplecov
|
94
86
|
requirement: !ruby/object:Gem::Requirement
|
95
87
|
requirements:
|
96
88
|
- - "~>"
|
97
89
|
- !ruby/object:Gem::Version
|
98
|
-
version: '
|
90
|
+
version: '0.22'
|
99
91
|
type: :development
|
100
92
|
prerelease: false
|
101
93
|
version_requirements: !ruby/object:Gem::Requirement
|
102
94
|
requirements:
|
103
95
|
- - "~>"
|
104
96
|
- !ruby/object:Gem::Version
|
105
|
-
version: '
|
97
|
+
version: '0.22'
|
106
98
|
- !ruby/object:Gem::Dependency
|
107
99
|
name: yard
|
108
100
|
requirement: !ruby/object:Gem::Requirement
|
@@ -118,40 +110,41 @@ dependencies:
|
|
118
110
|
- !ruby/object:Gem::Version
|
119
111
|
version: '0.9'
|
120
112
|
- !ruby/object:Gem::Dependency
|
121
|
-
name:
|
113
|
+
name: rake-compiler
|
122
114
|
requirement: !ruby/object:Gem::Requirement
|
123
115
|
requirements:
|
124
|
-
- - "
|
116
|
+
- - ">="
|
125
117
|
- !ruby/object:Gem::Version
|
126
|
-
version: '0
|
118
|
+
version: '0'
|
127
119
|
type: :development
|
128
120
|
prerelease: false
|
129
121
|
version_requirements: !ruby/object:Gem::Requirement
|
130
122
|
requirements:
|
131
|
-
- - "
|
123
|
+
- - ">="
|
132
124
|
- !ruby/object:Gem::Version
|
133
|
-
version: '0
|
125
|
+
version: '0'
|
134
126
|
description: Provides the ability to navigate and read entries from the systemd journal
|
135
127
|
in ruby, as well as write events to the journal.
|
136
128
|
email:
|
137
|
-
- john@
|
129
|
+
- john@weirdhorse.party
|
138
130
|
executables: []
|
139
|
-
extensions:
|
131
|
+
extensions:
|
132
|
+
- ext/shim/extconf.rb
|
140
133
|
extra_rdoc_files: []
|
141
134
|
files:
|
135
|
+
- ".github/workflows/ruby.yml"
|
142
136
|
- ".gitignore"
|
143
137
|
- ".rubocop.yml"
|
144
138
|
- ".travis.yml"
|
145
|
-
- Dockerfile.bionic
|
146
|
-
- Dockerfile.centos
|
147
|
-
- Dockerfile.xenial
|
148
139
|
- Gemfile
|
149
140
|
- LICENSE.txt
|
150
141
|
- README.md
|
151
142
|
- Rakefile
|
152
|
-
- certs/john@throttle.io.pem
|
153
143
|
- examples/journal_directory.rb
|
154
144
|
- examples/ssh_watcher.rb
|
145
|
+
- ext/shim/extconf.rb
|
146
|
+
- ext/shim/shim.c
|
147
|
+
- ext/shim/shim.h
|
155
148
|
- lib/systemd-journal.rb
|
156
149
|
- lib/systemd.rb
|
157
150
|
- lib/systemd/ffi_size_t.rb
|
@@ -179,7 +172,7 @@ homepage: https://github.com/ledbettj/systemd-journal
|
|
179
172
|
licenses:
|
180
173
|
- MIT
|
181
174
|
metadata: {}
|
182
|
-
post_install_message:
|
175
|
+
post_install_message:
|
183
176
|
rdoc_options: []
|
184
177
|
require_paths:
|
185
178
|
- lib
|
@@ -187,16 +180,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
187
180
|
requirements:
|
188
181
|
- - ">="
|
189
182
|
- !ruby/object:Gem::Version
|
190
|
-
version:
|
183
|
+
version: '3.0'
|
191
184
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
192
185
|
requirements:
|
193
186
|
- - ">="
|
194
187
|
- !ruby/object:Gem::Version
|
195
188
|
version: '0'
|
196
189
|
requirements: []
|
197
|
-
|
198
|
-
|
199
|
-
signing_key:
|
190
|
+
rubygems_version: 3.5.18
|
191
|
+
signing_key:
|
200
192
|
specification_version: 4
|
201
193
|
summary: Ruby bindings to libsystemd-journal
|
202
194
|
test_files:
|
checksums.yaml.gz.sig
DELETED
Binary file
|
data/Dockerfile.bionic
DELETED
@@ -1,19 +0,0 @@
|
|
1
|
-
FROM ubuntu:18.04
|
2
|
-
|
3
|
-
RUN apt-get update -q && apt-get install -qy --no-install-recommends \
|
4
|
-
build-essential \
|
5
|
-
ruby \
|
6
|
-
ruby-bundler \
|
7
|
-
ruby-dev \
|
8
|
-
libsystemd0 \
|
9
|
-
git \
|
10
|
-
&& apt-get clean \
|
11
|
-
&& rm -rf /var/lib/apt/lists/* \
|
12
|
-
&& truncate -s 0 /var/log/*log
|
13
|
-
|
14
|
-
WORKDIR /usr/src
|
15
|
-
|
16
|
-
COPY . .
|
17
|
-
RUN bundle install
|
18
|
-
RUN cat /dev/urandom | tr -cd 'a-f0-9' | head -c 32 | awk '{ print $1 }' | tee /etc/machine-id
|
19
|
-
RUN bundle exec rake
|
data/Dockerfile.centos
DELETED
@@ -1,11 +0,0 @@
|
|
1
|
-
FROM centos:7
|
2
|
-
|
3
|
-
RUN yum install -y make gcc-c++ systemd ruby ruby-devel rubygem-bundler git
|
4
|
-
|
5
|
-
WORKDIR /usr/src
|
6
|
-
ENV RUBOCOP=false
|
7
|
-
|
8
|
-
COPY . .
|
9
|
-
RUN bundle install
|
10
|
-
RUN cat /dev/urandom | tr -cd 'a-f0-9' | head -c 32 | awk '{ print $1 }' | tee /etc/machine-id
|
11
|
-
RUN bundle exec rake
|
data/Dockerfile.xenial
DELETED
@@ -1,19 +0,0 @@
|
|
1
|
-
FROM ubuntu:16.04
|
2
|
-
|
3
|
-
RUN apt-get update -q && apt-get install -qy --no-install-recommends \
|
4
|
-
build-essential \
|
5
|
-
ruby \
|
6
|
-
ruby-bundler \
|
7
|
-
ruby-dev \
|
8
|
-
libsystemd0 \
|
9
|
-
git \
|
10
|
-
&& apt-get clean \
|
11
|
-
&& rm -rf /var/lib/apt/lists/* \
|
12
|
-
&& truncate -s 0 /var/log/*log
|
13
|
-
|
14
|
-
WORKDIR /usr/src
|
15
|
-
|
16
|
-
COPY . .
|
17
|
-
RUN bundle install
|
18
|
-
RUN cat /dev/urandom | tr -cd 'a-f0-9' | head -c 32 | awk '{ print $1 }' | tee /etc/machine-id
|
19
|
-
RUN bundle exec rake
|
data/certs/john@throttle.io.pem
DELETED
@@ -1,21 +0,0 @@
|
|
1
|
-
-----BEGIN CERTIFICATE-----
|
2
|
-
MIIDaDCCAlCgAwIBAgIBATANBgkqhkiG9w0BAQUFADA9MQ0wCwYDVQQDDARqb2hu
|
3
|
-
MRgwFgYKCZImiZPyLGQBGRYIdGhyb3R0bGUxEjAQBgoJkiaJk/IsZAEZFgJpbzAe
|
4
|
-
Fw0xOTAzMDUyMDM1MjZaFw0yMDAzMDQyMDM1MjZaMD0xDTALBgNVBAMMBGpvaG4x
|
5
|
-
GDAWBgoJkiaJk/IsZAEZFgh0aHJvdHRsZTESMBAGCgmSJomT8ixkARkWAmlvMIIB
|
6
|
-
IjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAtt7tfjZWDXScvPrmsfgFTAk4
|
7
|
-
q8hSkI5B4R+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