Compare commits

...
Sign in to create a new pull request.

6 commits

Author SHA1 Message Date
Pavel Valena
cb7af6ea0f Use VAGRANT_PREFERRED_PROVIDERS in binstub instead of VAGRANT_DEFAULT_PROVIDER.
To support docker provider(also enables preset in Vagrantfile).
2017-08-29 14:15:22 +02:00
Pavel Valena
46c07a4afb Fix typos in binstub. 2017-08-29 14:09:51 +02:00
Pavel Valena
2d1e433494 Update to Vagrant 1.9.8.
Remove Nokogiri dependency.
Use current vagrant-spec.
Use unrestricted version for rubygem(rspec) BuildRequire (RSpec 3 as of now).
Add rubygem(rspec-its) BuildRequire.
Backport use-system-certificates into standalone patch(from 630247626b).
2017-08-29 14:02:25 +02:00
Fedora Release Engineering
3b9501f343 - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild 2017-08-29 14:02:15 +02:00
Pavel Valena
1706912ab5 Sync with master. 2017-08-29 14:01:36 +02:00
Pavel Valena
700507091e Update to 1.9.7.
Removed nokogiri dependency.
Updated vagrant_spec.
2017-07-31 15:45:37 +02:00
8 changed files with 130 additions and 93 deletions

4
.gitignore vendored
View file

@ -9,3 +9,7 @@
/vagrant-1.8.6.tar.gz
/vagrant-1.8.7.tar.gz
/vagrant-1.9.1.tar.gz
/vagrant-1.9.7.tar.gz
/vagrant-spec-2f0fb10862b2d19861c584be9d728080ba1f5d33.tar.gz
/vagrant-1.9.8.tar.gz
/vagrant-spec-e623a5694912c539ac2657e38a372d5e8c93441d.tar.gz

20
binstub
View file

@ -1,11 +1,16 @@
#!/usr/bin/env bash
#
# This is a wrapper to properly execute Vagrant within the embedded
# Vagrant installation directory. This sets up proper environmental variables
# Vagrant installation directory. This sets up proper environment variables
# so that everything loads and compiles to proper directories.
# Load defaults, especially VAGRANT_PREFERRED_PROVIDERS
if [ -r /etc/default/vagrant ]; then
source /etc/default/vagrant
fi
# Export gem paths so that we use the isolated gems.
# TODO: Should be repalced from .spec file.
# TODO: Should be replaced from .spec file.
# ruby -e "print Gem.path.join(':')"
export GEM_PATH="/usr/share/gems:/usr/share/vagrant/gems"
@ -22,7 +27,7 @@ export GEM_HOME="$VAGRANT_HOME/gems"
# SSL certs
export SSL_CERT_FILE="${SSL_CERT_FILE:-/etc/pki/tls/cert.pem}"
# Export an enviromental variable to say we're in a Vagrant
# Export an enviroment variable to say we're in a Vagrant
# installer created environment.
export VAGRANT_INSTALLER_ENV=1
# This is currently used only in Vagrant::Plugin::Manager.system_plugins_file
@ -35,17 +40,18 @@ export VAGRANT_INSTALLER_VERSION="2"
# because uname dependencies can conflict on some platforms.
OS=$(uname -s 2>/dev/null)
# Export the OS as an environmental variable that Vagrant can access
# Export the OS as an environment variable that Vagrant can access
# so that it can behave better.
export VAGRANT_DETECTED_OS="${OS}"
# Export the VAGRANT_EXECUTABLE so that pre-rubygems can optimize a bit
export VAGRANT_EXECUTABLE="${VAGRANT_INSTALLER_EMBEDDED_DIR}/gems/bin/vagrant"
# libvirt provider as a default
if [ -z $VAGRANT_DEFAULT_PROVIDER ]; then
export VAGRANT_DEFAULT_PROVIDER=libvirt
# Set providers' preferred order(priority)
if [ -z $VAGRANT_PREFERRED_PROVIDERS ]; then
VAGRANT_PREFERRED_PROVIDERS=libvirt,docker
fi
export VAGRANT_PREFERRED_PROVIDERS
# Call the actual Vagrant bin with our arguments
exec ruby "${VAGRANT_EXECUTABLE}" "$@"

View file

@ -1,2 +1,2 @@
SHA512 (vagrant-1.9.1.tar.gz) = 07ea6e2d881806ce61395a30abdaa7b4f7c2c39bb909d6c6e0aa14101945a9a26078ed18ebb8e238d97f05ee060564fb290615ac4868b80ee29b64b88a666452
SHA512 (vagrant-spec-9bba7e1228379c0a249a06ce76ba8ea7d276afbe.tar.gz) = eda90b5e05c04c7c690bf4579931a0aa2a418ca6f3f1f9b0c18770e4d09fcea2f081f817604ed73c84cb33c437674e315b0ecbdfa7dc24ca94713bb179cb3544
SHA512 (vagrant-1.9.8.tar.gz) = d22cc0a6800aa5ef84085c750f5ec8729f7b3adefd9a5df1a1fcaf60d1219e781869ede4f57ce4fdeb269224603dfc3a8024545a0250ebd9e144745ce9aa670b
SHA512 (vagrant-spec-e623a5694912c539ac2657e38a372d5e8c93441d.tar.gz) = dd480f06b3be740f368354a3d15bf4bba2982d72c6368c10b72596e8263c2c2fb5179c07f8aea8d9e77e9e2b7792e6f8562a9abb3c2e8861969effb5825a908c

View file

@ -2,7 +2,7 @@ diff --git a/test/unit/plugins/provisioners/ansible/provisioner_test.rb b/test/u
index 31354a7..f2dfd0f 100644
--- a/test/unit/plugins/provisioners/ansible/provisioner_test.rb
+++ b/test/unit/plugins/provisioners/ansible/provisioner_test.rb
@@ -498,55 +498,6 @@ VF
@@ -497,55 +497,6 @@ VF
end
end
@ -31,13 +31,13 @@ index 31354a7..f2dfd0f 100644
-
- it "generates an inventory with winrm connection settings" do
-
- expect(Vagrant::Util::Subprocess).to receive(:execute).with { |*args|
- expect(Vagrant::Util::Subprocess).to receive(:execute).with(any_args) { |*args|
- expect(config.inventory_path).to be_nil
- expect(File.exists?(generated_inventory_file)).to be_true
- expect(File.exists?(generated_inventory_file)).to be(true)
- inventory_content = File.read(generated_inventory_file)
-
- expect(inventory_content).to include("machine1 ansible_connection=winrm ansible_ssh_host=127.0.0.1 ansible_ssh_port=55986 ansible_ssh_user='winner' ansible_ssh_pass='winword'\n")
- }
- }.and_return(default_execute_result)
- end
-
- describe "with force_remote_user option disabled" do
@ -46,12 +46,12 @@ index 31354a7..f2dfd0f 100644
- end
-
- it "doesn't set the ansible remote user in inventory and use '--user' argument with the vagrant ssh username" do
- expect(Vagrant::Util::Subprocess).to receive(:execute).with { |*args|
- expect(Vagrant::Util::Subprocess).to receive(:execute).with(any_args) { |*args|
- inventory_content = File.read(generated_inventory_file)
-
- expect(inventory_content).to include("machine1 ansible_connection=winrm ansible_ssh_host=127.0.0.1 ansible_ssh_port=55986 ansible_ssh_pass='winword'\n")
- expect(args).to include("--user=testuser")
- }
- }.and_return(default_execute_result)
- end
- end
- end

View file

@ -1,70 +0,0 @@
From 8d5d208fbc4a9b87c6f1f9991dbbf65d5cb5bfbb Mon Sep 17 00:00:00 2001
From: Tomas Hrcka <thrcka@redhat.com>
Date: Wed, 27 Jan 2016 10:20:34 +0100
Subject: [PATCH] fix dependencies
---
lib/vagrant/bundler.rb | 2 +-
lib/vagrant/util/downloader.rb | 5 +++--
vagrant.gemspec | 41 ++++++++++++++++++++---------------------
3 files changed, 24 insertions(+), 24 deletions(-)
diff --git a/lib/vagrant/util/downloader.rb b/lib/vagrant/util/downloader.rb
index 03e6238..9a02a85 100644
--- a/lib/vagrant/util/downloader.rb
+++ b/lib/vagrant/util/downloader.rb
@@ -297,8 +297,9 @@ module Vagrant
# If we're in Vagrant, then we use the packaged CA bundle
if Vagrant.in_installer?
subprocess_options[:env] ||= {}
- subprocess_options[:env]["CURL_CA_BUNDLE"] =
- File.expand_path("cacert.pem", ENV["VAGRANT_INSTALLER_EMBEDDED_DIR"])
+ #Use system certificates.
+ #subprocess_options[:env]["CURL_CA_BUNDLE"] =
+ # File.expand_path("cacert.pem", ENV["VAGRANT_INSTALLER_EMBEDDED_DIR"])
end
return [options, subprocess_options]
diff --git a/vagrant.gemspec b/vagrant.gemspec
index 078add3..d1dd7bd 100644
--- a/vagrant.gemspec
+++ b/vagrant.gemspec
@@ -22,23 +22,27 @@ Gem::Specification.new do |s|
s.add_dependency "listen", "~> 3.1.5"
s.add_dependency "hashicorp-checkpoint", "~> 0.1.1"
s.add_dependency "log4r", "~> 1.1.9", "< 1.1.11"
- s.add_dependency "net-ssh", "~> 3.0.1"
+ s.add_dependency "net-ssh", ">= 3.0"
s.add_dependency "net-sftp", "~> 2.1"
- s.add_dependency "net-scp", "~> 1.1.0"
- s.add_dependency "rb-kqueue", "~> 0.2.0"
+ s.add_dependency "net-scp", ">= 1.1.0"
+ # Remove BSD specific dependency.
+ # s.add_dependency "rb-kqueue", "~> 0.2.0"
s.add_dependency "rest-client", ">= 1.6.0", "< 3.0"
- s.add_dependency "wdm", "~> 0.1.0"
- s.add_dependency "winrm", "~> 1.6"
- s.add_dependency "winrm-fs", "~> 0.3.0"
+ # Remove Windows specific dependency.
+ # s.add_dependency "wdm", "~> 0.1.0"
+ # s.add_dependency "winrm", "~> 1.6"
+ # s.add_dependency "winrm-fs", "~> 0.3.0"
# We lock this down to avoid compilation issues.
- s.add_dependency "nokogiri", "= 1.6.7.1"
+ s.add_dependency "nokogiri"
# NOTE: The ruby_dep gem is an implicit dependency from the listen gem. Later versions
# of the ruby_dep gem impose an aggressive constraint on the required ruby version (>= 2.2.5).
# Explicit constraint is defined to provide required dependency to listen without imposing
# tighter restrictions on valid ruby versions
- s.add_dependency "ruby_dep", "<= 1.3.1"
+ #
+ # Do not impose any Ruby version restrictions on Fedora.
+ # s.add_dependency "ruby_dep", "<= 1.3.1"
# Constraint rake to properly handle deprecated method usage
# from within rspec
--
2.5.0

View file

@ -0,0 +1,58 @@
From 7486aa2ce950f55a4be9049d514c412d7e45ddef Mon Sep 17 00:00:00 2001
From: Pavel Valena <pvalena@redhat.com>
Date: Thu, 20 Jul 2017 15:01:06 +0200
Subject: [PATCH] Fix dependencies for Vagrant 1.9.7.
---
vagrant.gemspec | 21 ++++++++++++---------
1 file changed, 12 insertions(+), 9 deletions(-)
diff --git a/vagrant.gemspec b/vagrant.gemspec
index c92ca17..aeee52f 100644
--- a/vagrant.gemspec
+++ b/vagrant.gemspec
@@ -12,7 +12,7 @@ Gem::Specification.new do |s|
s.summary = "Build and distribute virtualized development environments."
s.description = "Vagrant is a tool for building and distributing virtualized development environments."
- s.required_ruby_version = "~> 2.2", "< 2.4"
+ s.required_ruby_version = "~> 2.2"
s.required_rubygems_version = ">= 1.3.6"
s.rubyforge_project = "vagrant"
@@ -22,21 +22,24 @@ Gem::Specification.new do |s|
s.add_dependency "listen", "~> 3.1.5"
s.add_dependency "hashicorp-checkpoint", "~> 0.1.1"
s.add_dependency "log4r", "~> 1.1.9", "< 1.1.11"
- s.add_dependency "net-ssh", "~> 4.1.0"
+ s.add_dependency "net-ssh", ">= 4.1.0"
s.add_dependency "net-sftp", "~> 2.1"
- s.add_dependency "net-scp", "~> 1.2.0"
- s.add_dependency "rb-kqueue", "~> 0.2.0"
+ s.add_dependency "net-scp", ">= 1.2.0"
+ # Remove Windows specific dependency.
+ # s.add_dependency "rb-kqueue", "~> 0.2.0"
s.add_dependency "rest-client", ">= 1.6.0", "< 3.0"
- s.add_dependency "wdm", "~> 0.1.0"
- s.add_dependency "winrm", "~> 2.1"
- s.add_dependency "winrm-fs", "~> 1.0"
- s.add_dependency "winrm-elevated", "~> 1.1"
+ # s.add_dependency "wdm", "~> 0.1.0"
+ # s.add_dependency "winrm", "~> 2.1"
+ # s.add_dependency "winrm-fs", "~> 1.0"
+ # s.add_dependency "winrm-elevated", "~> 1.1"
# NOTE: The ruby_dep gem is an implicit dependency from the listen gem. Later versions
# of the ruby_dep gem impose an aggressive constraint on the required ruby version (>= 2.2.5).
# Explicit constraint is defined to provide required dependency to listen without imposing
# tighter restrictions on valid ruby versions
- s.add_dependency "ruby_dep", "<= 1.3.1"
+ #
+ # Do not impose any Ruby version restrictions on Fedora.
+ # s.add_dependency "ruby_dep", "<= 1.3.1"
# Constraint rake to properly handle deprecated method usage
# from within rspec
--
2.7.5

View file

@ -0,0 +1,27 @@
From 7486aa2ce950f55a4be9049d514c412d7e45ddef Mon Sep 17 00:00:00 2001
From: Pavel Valena <pvalena@redhat.com>
Date: Thu, 20 Jul 2017 15:01:06 +0200
Subject: [PATCH] Use system certificates
---
lib/vagrant/util/downloader.rb | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/lib/vagrant/util/downloader.rb b/lib/vagrant/util/downloader.rb
index 03e6238..9a02a85 100644
--- a/lib/vagrant/util/downloader.rb
+++ b/lib/vagrant/util/downloader.rb
@@ -297,8 +297,9 @@ module Vagrant
# If we're in Vagrant, then we use the packaged CA bundle
if Vagrant.in_installer?
subprocess_options[:env] ||= {}
- subprocess_options[:env]["CURL_CA_BUNDLE"] =
- File.expand_path("cacert.pem", ENV["VAGRANT_INSTALLER_EMBEDDED_DIR"])
+ #Use system certificates.
+ #subprocess_options[:env]["CURL_CA_BUNDLE"] =
+ # File.expand_path("cacert.pem", ENV["VAGRANT_INSTALLER_EMBEDDED_DIR"])
end
return [options, subprocess_options]
--
2.5.0

View file

@ -1,10 +1,10 @@
%global bashcompletion_dir %(pkg-config --variable=completionsdir bash-completion 2> /dev/null || :)
%global vagrant_spec_commit 9bba7e1228379c0a249a06ce76ba8ea7d276afbe
%global vagrant_spec_commit e623a5694912c539ac2657e38a372d5e8c93441d
Name: vagrant
Version: 1.9.1
Release: 2%{?dist}
Version: 1.9.8
Release: 1%{?dist}
Summary: Build and distribute virtualized development environments
Group: Development/Languages
License: MIT
@ -14,7 +14,7 @@ Source0: https://github.com/mitchellh/%{name}/archive/v%{version}/%{name}-%{vers
Source1: binstub
# The library has no official release yet. But since it is just test
# dependency, it should be fine to include the source right here.
# wget https://github.com/mitchellh/vagrant-spec/archive/9bba7e1228379c0a249a06ce76ba8ea7d276afbe/vagrant-spec-9bba7e1228379c0a249a06ce76ba8ea7d276afbe.tar.gz
# wget https://github.com/mitchellh/vagrant-spec/archive/2f0fb10862b2d19861c584be9d728080ba1f5d33/vagrant-spec-2f0fb10862b2d19861c584be9d728080ba1f5d33.tar.gz
Source2: https://github.com/mitchellh/%{name}-spec/archive/%{vagrant_spec_commit}/%{name}-spec-%{vagrant_spec_commit}.tar.gz
# Monkey-patching needed for Vagrant to work until the respective patches
# for RubyGems and Bundler are in place
@ -24,7 +24,7 @@ Source4: macros.vagrant
# fails on older Fedoras.
%{?load:%{SOURCE4}}
Patch0: vagrant-1.9.1-fix-dependencies.patch
Patch0: vagrant-1.9.8-fix-dependencies.patch
# Disable ansible winrm tests
Patch1: vagrant-1.8.1-disable-winrm-tests.patch
@ -33,6 +33,10 @@ Patch1: vagrant-1.8.1-disable-winrm-tests.patch
# https://github.com/mitchellh/vagrant/pull/8284
Patch2: vagrant-1.9.1-Fix-Ruby-2.4-compatibility.patch
# Extracted from vagrant-1.9.1-fix-dependencies.patch
# in commit 630247626bf1353c463184f1bca6c59a246d33e2
Patch3: vagrant-1.9.8-use-system-certificates.patch
Requires: ruby(release)
Requires: ruby(rubygems) >= 1.3.6
# Explicitly specify MRI, since Vagrant does not work with JRuby ATM.
@ -52,7 +56,6 @@ Requires: rubygem(log4r) >= 1.1.9
Requires: rubygem(log4r) < 1.1.11
Requires: rubygem(net-ssh) >= 3.0
Requires: rubygem(net-scp) >= 1.1.0
Requires: rubygem(nokogiri) >= 1.6
Requires: rubygem(net-sftp) >= 2.1
Requires: rubygem(net-sftp) < 3
Requires: rubygem(rest-client) < 3.0
@ -71,11 +74,11 @@ BuildRequires: rubygem(hashicorp-checkpoint)
BuildRequires: rubygem(log4r)
BuildRequires: rubygem(net-ssh)
BuildRequires: rubygem(net-scp)
BuildRequires: rubygem(nokogiri)
BuildRequires: rubygem(i18n)
BuildRequires: rubygem(json)
BuildRequires: rubygem(erubis)
BuildRequires: rubygem(rspec) < 3
BuildRequires: rubygem(rspec)
BuildRequires: rubygem(rspec-its)
BuildRequires: rubygem(net-sftp)
BuildRequires: rubygem(rest-client)
BuildRequires: rubygem(thor)
@ -113,6 +116,7 @@ Documentation for %{name}.
%patch0 -p1
%patch1 -p1
%patch2 -p1
%patch3 -p1
%build
gem build %{name}.gemspec
@ -308,6 +312,14 @@ end
%changelog
* Thu Aug 24 2017 Pavel Valena <pvalena@redhat.com> - 1.9.8-1
- Update to Vagrant 1.9.8.
- Remove Nokogiri dependency.
- Use VAGRANT_PREFERRED_PROVIDERS in binstub instead of VAGRANT_DEFAULT_PROVIDER.
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org>
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
* Tue Feb 28 2017 Vít Ondruch <vondruch@redhat.com> - 1.9.1-2
- Obsolete vagrant-atomic, since it is now merged in Vagrant.