Skip to content

Commit

Permalink
Drop unused json, fog-json and fog-xml dependencies & add nokogiri
Browse files Browse the repository at this point in the history
This gem doesn't use JSON at all and uses nokogiri directly instead of
fog-xml. This removes the dependencies and instead adds nokogiri
directly.

fog-xml has nokogiri 1.5.11 as the lower bound. This is updated to 1.11
because that version introduced native gems for 2.7. It's also already 3
years old so it should be usable for everyone. There were plenty of CVEs
in older versions.
  • Loading branch information
ekohl committed Dec 22, 2024
1 parent ffae6a5 commit 33e4b3c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
5 changes: 2 additions & 3 deletions fog-libvirt.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,8 @@ Gem::Specification.new do |s|
s.required_ruby_version = '>= 2.7'

s.add_dependency("fog-core", ">= 1.27.4")
s.add_dependency("fog-json")
s.add_dependency("fog-xml", "~> 0.1.1")
s.add_dependency("json")
# 1.11 introduced support for Ruby 2.7 as precompiled gem
s.add_dependency("nokogiri", "~> 1.11")
s.add_dependency('ruby-libvirt','>= 0.7.0')

s.add_development_dependency("minitest", "~> 5.0")
Expand Down
2 changes: 0 additions & 2 deletions lib/fog/libvirt.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
require 'fog/core'
require 'fog/xml'
require 'fog/json'
require 'libvirt'

require File.expand_path('../libvirt/version', __FILE__)
Expand Down

0 comments on commit 33e4b3c

Please sign in to comment.