summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Smith <tsmith@chef.io>2021-08-16 10:54:42 -0700
committerGitHub <noreply@github.com>2021-08-16 10:54:42 -0700
commitc6d922e0e1b234edcc6b46cc8c8264dc986c5625 (patch)
tree46fdf907909bd36a232f2512de4df73287522d91
parent8f4fcb9188da05973f8f2530243e43d42cf33246 (diff)
parentace24911cb907717750b03aedc607b0f2efcad0e (diff)
downloadchef-c6d922e0e1b234edcc6b46cc8c8264dc986c5625.tar.gz
Merge pull request #11917 from chef/bundler_deprecated_warning
Replace deprecated --without flag with bundle config
-rw-r--r--.expeditor/scripts/bk_win_prep.ps13
-rw-r--r--.expeditor/verify.pipeline.yml66
-rw-r--r--.github/workflows/kitchen.yml4
-rw-r--r--omnibus/Gemfile2
-rw-r--r--omnibus/README.md13
5 files changed, 58 insertions, 30 deletions
diff --git a/.expeditor/scripts/bk_win_prep.ps1 b/.expeditor/scripts/bk_win_prep.ps1
index 37796da468..69f35a1ff2 100644
--- a/.expeditor/scripts/bk_win_prep.ps1
+++ b/.expeditor/scripts/bk_win_prep.ps1
@@ -11,5 +11,6 @@ bundle --version
if (-not $?) { throw "Can't run Bundler. Is it installed?" }
echo "--- bundle install"
-bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+bundle config set --local without omnibus_package
+bundle install --jobs=3 --retry=3 --path=vendor/bundle
if (-not $?) { throw "Unable to install gem dependencies" } \ No newline at end of file
diff --git a/.expeditor/verify.pipeline.yml b/.expeditor/verify.pipeline.yml
index b1ec9b73f2..9e3f0669ab 100644
--- a/.expeditor/verify.pipeline.yml
+++ b/.expeditor/verify.pipeline.yml
@@ -19,7 +19,8 @@ steps:
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- cd chef-utils
- - bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec
expeditor:
executor:
@@ -30,7 +31,8 @@ steps:
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- cd chef-config
- - bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec
expeditor:
executor:
@@ -44,7 +46,8 @@ steps:
- label: "Integration Ubuntu 18.04 :ruby: 3.0"
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- - cd /workdir; bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - cd /workdir; bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:integration
expeditor:
executor:
@@ -57,7 +60,8 @@ steps:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- apt-get update -y
- apt-get install -y cron locales # needed for functional tests to pass
- - cd /workdir; bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - cd /workdir; bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:functional
expeditor:
executor:
@@ -68,7 +72,8 @@ steps:
- label: "Unit Ubuntu 18.04 :ruby: 3.0"
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- - bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:unit
- bundle exec rake component_specs
expeditor:
@@ -79,7 +84,8 @@ steps:
- label: "Integration Ubuntu 20.04 :ruby: 3.0"
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- - cd /workdir; bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - cd /workdir; bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:integration
expeditor:
executor:
@@ -92,7 +98,8 @@ steps:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- apt-get update -y
- apt-get install -y cron locales # needed for functional tests to pass
- - cd /workdir; bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - cd /workdir; bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:functional
expeditor:
executor:
@@ -103,7 +110,8 @@ steps:
- label: "Unit Ubuntu 20.04 :ruby: 3.0"
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- - bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:unit
- bundle exec rake component_specs
expeditor:
@@ -114,7 +122,8 @@ steps:
- label: "Integration CentOS 7 :ruby: 3.0"
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- - cd /workdir; bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - cd /workdir; bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:integration
expeditor:
executor:
@@ -126,7 +135,8 @@ steps:
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- yum install -y crontabs e2fsprogs
- - cd /workdir; bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - cd /workdir; bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:functional
expeditor:
executor:
@@ -137,7 +147,8 @@ steps:
- label: "Unit CentOS 7 :ruby: 3.0"
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- - bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:unit
- bundle exec rake component_specs
expeditor:
@@ -149,7 +160,8 @@ steps:
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- zypper install -y cron insserv-compat
- - cd /workdir; bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - cd /workdir; bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:integration
expeditor:
executor:
@@ -161,7 +173,8 @@ steps:
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- zypper install -y cronie insserv-compat
- - cd /workdir; bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - cd /workdir; bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:functional
expeditor:
executor:
@@ -173,7 +186,8 @@ steps:
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- zypper install -y cron insserv-compat
- - bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:unit
- bundle exec rake component_specs
expeditor:
@@ -184,7 +198,8 @@ steps:
- label: "Integration Fedora :ruby: 3.0"
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- - cd /workdir; bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - cd /workdir; bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:integration
expeditor:
executor:
@@ -196,7 +211,8 @@ steps:
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- dnf install -y crontabs e2fsprogs
- - cd /workdir; bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - cd /workdir; bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:functional
expeditor:
executor:
@@ -210,7 +226,8 @@ steps:
- label: "Unit Fedora :ruby: 3.0"
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- - bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec rake spec:unit
- bundle exec rake component_specs
expeditor:
@@ -261,7 +278,8 @@ steps:
- label: "chef-zero gem :ruby: 3.0"
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- - bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec tasks/bin/run_external_test chef/chef-zero master rake pedant
expeditor:
executor:
@@ -274,7 +292,8 @@ steps:
- label: "cheffish gem :ruby: 3.0"
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- - bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec tasks/bin/run_external_test chef/cheffish master rake spec
expeditor:
executor:
@@ -284,7 +303,8 @@ steps:
- label: "chefspec gem :ruby: 3.0"
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- - bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec tasks/bin/run_external_test chefspec/chefspec master rake
expeditor:
executor:
@@ -294,7 +314,8 @@ steps:
- label: "knife-windows gem :ruby: 3.0"
commands:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- - bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec tasks/bin/run_external_test chef/knife-windows master rake spec
expeditor:
executor:
@@ -306,7 +327,8 @@ steps:
- /workdir/.expeditor/scripts/bk_container_prep.sh
- apt-get update -y
- apt-get install -y graphviz
- - bundle install --jobs=3 --retry=3 --path=vendor/bundle --without omnibus_package
+ - bundle config set --local without omnibus_package
+ - bundle install --jobs=3 --retry=3 --path=vendor/bundle
- bundle exec tasks/bin/run_external_test berkshelf/berkshelf master rake
expeditor:
executor:
diff --git a/.github/workflows/kitchen.yml b/.github/workflows/kitchen.yml
index afce7211b3..5fa865bb34 100644
--- a/.github/workflows/kitchen.yml
+++ b/.github/workflows/kitchen.yml
@@ -40,7 +40,7 @@ jobs:
run: |
cd kitchen-tests
$env:PATH = "C:\opscode\chef\bin;C:\opscode\chef\embedded\bin;" + $env:PATH
- bundle config set without 'omnibus_package'
+ bundle config set --local without 'omnibus_package'
bundle install --jobs=3 --retry=3 --path=vendor/bundle
gem install berkshelf --no-doc
# berks emits a ruby warning when it loads net/http due to a previously
@@ -82,7 +82,7 @@ jobs:
id: run
run: |
cd kitchen-tests
- sudo /opt/chef/embedded/bin/bundle config set without 'omnibus_package'
+ sudo /opt/chef/embedded/bin/bundle config set --local without 'omnibus_package'
sudo /opt/chef/embedded/bin/bundle install --jobs=3 --retry=3 --path=vendor/bundle
sudo /opt/chef/embedded/bin/gem install berkshelf --no-doc
sudo /opt/chef/embedded/bin/berks vendor cookbooks
diff --git a/omnibus/Gemfile b/omnibus/Gemfile
index 052ac6bfd9..14d2f3e698 100644
--- a/omnibus/Gemfile
+++ b/omnibus/Gemfile
@@ -9,7 +9,7 @@ gem "pedump"
# This development group is installed by default when you run `bundle install`,
# but if you are using Omnibus in a CI-based infrastructure, you do not need
# the Test Kitchen-based build lab. You can skip these unnecessary dependencies
-# by running `bundle install --without development` to speed up build times.
+# by running `bundle config set --local without development && bundle install` to speed up build times.
group :development do
# Use Berkshelf for resolving cookbook dependencies
gem "berkshelf", ">= 7.0"
diff --git a/omnibus/README.md b/omnibus/README.md
index a10190c136..2055f6c0fd 100644
--- a/omnibus/README.md
+++ b/omnibus/README.md
@@ -10,7 +10,8 @@ This project creates full-stack platform-specific packages for the following pro
You must have a sane Ruby environment with Bundler installed. Ensure all the required gems are installed:
```shell
-bundle install --without development
+bundle config set --local without development
+bundle install
```
## Usage
@@ -80,7 +81,8 @@ Then login to the instance and build the project as described in the Usage secti
```shell
$ bundle exec kitchen login <PROJECT>-ubuntu-1204
[vagrant@ubuntu...] $ cd chef/omnibus
-[vagrant@ubuntu...] $ bundle install --without development # Don't install dev tools!
+[vagrant@ubuntu...] $ bundle config set --local without development # Don't install dev tools!
+[vagrant@ubuntu...] $ bundle install
[vagrant@ubuntu...] $ ...
[vagrant@ubuntu...] $ bundle exec omnibus build <PROJECT> -l internal
```
@@ -89,7 +91,8 @@ $ bundle exec kitchen login <PROJECT>-ubuntu-1204
$ kitchen login chef-ubuntu-1604
[vagrant@ubuntu...] $ source load-omnibus-toolchain.sh
[vagrant@ubuntu...] $ cd chef/omnibus
-[vagrant@ubuntu...] $ bundle install --without development # Don't install dev tools!
+[vagrant@ubuntu...] $ bundle config set --local without development # Don't install dev tools!
+[vagrant@ubuntu...] $ bundle install
[vagrant@ubuntu...] $ ...
[vagrant@ubuntu...] $ bundle exec omnibus build chef -l internal
```
@@ -106,7 +109,9 @@ C:\>C:\vagrant\load-omnibus-toolchain.ps1
C:\>cd C:\vagrant\chef\omnibus
-C:\vagrant\chef\omnibus>bundle install --without development
+C:\vagrant\chef\omnibus>bundle config set --local without development
+
+C:\vagrant\chef\omnibus>bundle install
C:\vagrant\chef\omnibus>bundle exec omnibus build chef -l internal
```