#ruby #windows #chef-infra
#ruby #Windows #шеф-повар-инфра
Вопрос:
Я пытаюсь создать клиент chef для Windows, используя предоставленные инструкции @ https://github.com/chef/chef/tree/master/omnibus#kitchen-based-build-environment .
Я думаю, что я правильно настроил шаги предварительной проверки в Windows и успешно запустил load-omnibus-toolchain.ps1 из omnibus-toolchain. После этого, если я запускаю «bundle exec omnibus build chef -l internal» из powershell, я получаю приведенную ниже ошибку. Любая помощь по этому вопросу будет оценена. Обратите внимание, что я пытаюсь выполнить сборку из последнего исходного кода 16.X.X.
C:/buildkite-agent is not a directory.
Bundler will use C:/Users/ADMINI~1/AppData/Local/Temp/2/bundler20201006-5812-gte5gk5812' as your home directory temporarily. [CLI] I | 2020-10-06T18:48:58 00:00 | Using config from 'omnibus.rb' [Project] I | 2020-10-06T18:48:58 00:00 | Loading project chef' from C:/chef-16.5.64/omnibus/config/projects/chef.rb'. [Software] I | 2020-10-06T18:49:02 00:00 | Loading software preparation' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/preparation.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:02 00:00 | Loading software chef' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/chef.rb' using overrides from chef. [Software: chef] W | 2020-10-06T18:49:02 00:00 | Version local_source for software chef was not parseable. Comparison methods such as #satisfies? will not be available for this version. [Software: chef] W | 2020-10-06T18:49:02 00:00 | Version local_source for software chef was not parseable. Comparison methods such as #satisfies? will not be available for this version. [Software] I | 2020-10-06T18:49:02 00:00 | Loading software ruby' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/ruby.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:02 00:00 | Loading software zlib' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/zlib.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:02 00:00 | Loading software openssl' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/openssl.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software cacerts' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/cacerts.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software libffi' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/libffi.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software libyaml' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/libyaml.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software config_guess' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/config_guess.rb' using overrides from chef. [Software: config_guess] W | 2020-10-06T18:49:03 00:00 | Version master for software config_guess was not parseable. Comparison methods such as #satisfies? will not be available for this version. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software ohai' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/ohai.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software libarchive' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/libarchive.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software libxml2' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/libxml2.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software liblzma' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/liblzma.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software bzip2' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/bzip2.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software nokogiri' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/nokogiri.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software libxslt' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/libxslt.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software gem-permissions' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/gem-permissions.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software shebang-cleanup' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/shebang-cleanup.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software version-manifest' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/version-manifest.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software openssl-customization' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/openssl-customization.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software ruby-windows-devkit' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/ruby-windows-devkit.rb' using overrides from chef. [Software: ruby-windows-devkit] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for ruby-windows-devkit [Software: ruby-windows-devkit] W | 2020-10-06T18:49:03 00:00 | DEPRECATED: project_file (DSL). This is a property of the NetFetcher and will not be publically exposed in the next major release. In general, you should not be using this method in your software definitions as it is an internal implementation detail of the NetFetcher. If you disagree with this statement, you should open an issue on the Omnibus repository on GitHub an explain your use case. For now, I will return the path to the downloaded file on disk, but please rethink the problem you are trying to solve :). [Software] I | 2020-10-06T18:49:03 00:00 | Loading software ruby-windows-devkit-bash' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/ruby-windows-devkit-bash.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software ruby-cleanup' from C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-software-0e0686b82299/config/software/ruby-cleanup.rb' using overrides from chef. [Software] I | 2020-10-06T18:49:03 00:00 | Loading software more-ruby-cleanup' from C:/chef-16.5.64/omnibus/config/software/more-ruby-cleanup.rb' using overrides from chef. Building chef 16.5.64 20201006184858... [Software: cacerts] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for cacerts [Software: openssl] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for openssl [Software: libffi] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for libffi [Software: zlib] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for zlib [Software: preparation] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for preparation [NullFetcher: preparation] I | 2020-10-06T18:49:03 00:00 | Fetching preparation' (nothing to fetch)
[Software: config_guess] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for config_guess
[Software: config_guess] W | 2020-10-06T18:49:03 00:00 | Version master for software config_guess was not parseable. Comparison methods such as #satisfies? will not be available for this version.
[Software: config_guess] W | 2020-10-06T18:49:03 00:00 | Version master for software config_guess was not parseable. Comparison methods such as #satisfies? will not be available for this version.
[GitFetcher] I | 2020-10-06T18:49:03 00:00 | git ls-remote "https://github.com/chef/config-mirror.git" "master*" [Software: libyaml] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for libyaml [Software: ruby] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for ruby [Software: ohai] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for ohai [Software: ohai] W | 2020-10-06T18:49:03 00:00 | Version v16.5.4 for software ohai was not parseable. Comparison methods such as #satisfies? will not be available for this version. [Software: ohai] W | 2020-10-06T18:49:03 00:00 | Version v16.5.4 for software ohai was not parseable. Comparison methods such as #satisfies? will not be available for this version. [GitFetcher] I | 2020-10-06T18:49:03 00:00 | git ls-remote "https://github.com/chef/ohai.git" "v16.5.4*"
[Software: liblzma] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for liblzma
[Software: libxml2] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for libxml2
[Software: bzip2] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for bzip2
[Software: libarchive] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for libarchive
[Software: libxslt] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for libxslt
[Software: chef] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for chef
[Software: chef] W | 2020-10-06T18:49:03 00:00 | Version local_source for software chef was not parseable. Comparison methods such as #satisfies? will not be available for this version.
[Software: chef] W | 2020-10-06T18:49:03 00:00 | Version local_source for software chef was not parseable. Comparison methods such as #satisfies? will not be available for this version.
[PathFetcher: chef] I | 2020-10-06T18:49:03 00:00 | Digesting C:/omnibus-ruby/src/chef/chef with sha256
[Software: nokogiri] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for nokogiri
[NullFetcher: nokogiri] I | 2020-10-06T18:49:03 00:00 | Fetching nokogiri' (nothing to fetch) [Software: gem-permissions] I | 2020-10-06T18:49:03 00:00 | Resolving manifest entry for gem-permissions [NullFetcher: gem-permissions] I | 2020-10-06T18:49:03 00:00 | Fetching gem-permissions' (nothing to fetch)
[Software: shebang-cleanup] I | 2020-10-06T18:49:04 00:00 | Resolving manifest entry for shebang-cleanup
[NullFetcher: shebang-cleanup] I | 2020-10-06T18:49:04 00:00 | Fetching shebang-cleanup' (nothing to fetch) [Software: version-manifest] I | 2020-10-06T18:49:04 00:00 | Resolving manifest entry for version-manifest [NullFetcher: version-manifest] I | 2020-10-06T18:49:04 00:00 | Fetching version-manifest' (nothing to fetch)
[Software: openssl-customization] I | 2020-10-06T18:49:04 00:00 | Resolving manifest entry for openssl-customization
[PathFetcher: openssl-customization] I | 2020-10-06T18:49:04 00:00 | Digesting C:/omnibus-ruby/src/openssl-customization with sha256
[PathFetcher: openssl-customization] I | 2020-10-06T18:49:04 00:00 | Digesting C:/chef-16.5.64/omnibus/files/openssl-customization with sha256
[Software: ruby-windows-devkit-bash] I | 2020-10-06T18:49:04 00:00 | Resolving manifest entry for ruby-windows-devkit-bash
[Software: ruby-cleanup] I | 2020-10-06T18:49:04 00:00 | Resolving manifest entry for ruby-cleanup
[NullFetcher: ruby-cleanup] I | 2020-10-06T18:49:04 00:00 | Fetching ruby-cleanup' (nothing to fetch) [Software: more-ruby-cleanup] I | 2020-10-06T18:49:04 00:00 | Resolving manifest entry for more-ruby-cleanup [PathFetcher: more-ruby-cleanup] I | 2020-10-06T18:49:04 00:00 | Digesting C:/omnibus-ruby/src/more-ruby-cleanup with sha256 [PathFetcher: more-ruby-cleanup] I | 2020-10-06T18:49:04 00:00 | Digesting C:/chef-16.5.64/omnibus/files/more-ruby-cleanup with sha256 I | 2020-10-06T18:49:04 00:00 | 84f04b02a7e2fc8eaa9d52deee5f6d57b06fe447 refs/heads/master I | 2020-10-06T18:49:04 00:00 | 5a37f3e4347b42023e15015b8f5e56c3905e20bf refs/tags/v16.5.4 I | 2020-10-06T18:49:04 00:00 | 0487d320efda47bce88b68c0916e2f4b275244ae refs/tags/v16.5.4^{} [GitFetcher: config_guess] I | 2020-10-06T18:49:04 00:00 | $ git -c core.autocrlf=false cat-file -t 84f04b02a7e2fc8eaa9d52deee5f6d57b06fe447 [GitFetcher: ohai] I | 2020-10-06T18:49:04 00:00 | $ git -c core.autocrlf=false cat-file -t 0487d320efda47bce88b68c0916e2f4b275244ae I | 2020-10-06T18:49:04 00:00 | commit I | 2020-10-06T18:49:04 00:00 | commit [PathFetcher: chef] I | 2020-10-06T18:49:24 00:00 | Digesting C:/chef-16.5.64/omnibus/files/../.. with sha256 [Licensing] I | 2020-10-06T18:49:48 00:00 | Project 'chef' is using 'Chef EULA' which is not one of the standard licenses identified in https://opensource.org/licenses/alphabetical. Consider using one of the standard licenses. [Software: config_guess] W | 2020-10-06T18:49:48 00:00 | Version master for software config_guess was not parseable. Comparison methods such as #satisfies? will not be available for this version. [Software: ohai] W | 2020-10-06T18:49:48 00:00 | Version v16.5.4 for software ohai was not parseable. Comparison methods such as #satisfies? will not be available for this version. [Software: chef] W | 2020-10-06T18:49:48 00:00 | Version local_source for software chef was not parseable. Comparison methods such as #satisfies? will not be available for this version. [Licensing] I | 2020-10-06T18:49:48 00:00 | Software 'config_guess' uses license 'GPL-3.0 (with exception)' which is not one of the standard licenses identified in https://opensource.org/licenses/alphabetical. Consider using one of the standard licenses. [Software: preparation] D | 2020-10-06T18:49:48 00:00 | Forcing build because git caching is off [Builder: preparation] I | 2020-10-06T18:49:48 00:00 | Starting build [Builder: preparation] I | 2020-10-06T18:49:48 00:00 | Cached builder checksum before build: 2791faa48a03f3fe6e6b7283fd538d6bcdc9ec7235211dc02d0d6a04af3870bd [Builder: preparation] I | 2020-10-06T18:49:48 00:00 | <Dynamic Ruby block>: 0.0001s [Builder: preparation] I | 2020-10-06T18:49:49 00:00 | touch C:/opscode/chef/embedded/lib/.gitkeep': 0.0021s
[Builder: preparation] I | 2020-10-06T18:49:49 00:00 | touch C:/opscode/chef/embedded/bin/.gitkeep': 0.0013s [Builder: preparation] I | 2020-10-06T18:49:49 00:00 | touch C:/opscode/chef/bin/.gitkeep': 0.0011s
[Builder: preparation] I | 2020-10-06T18:49:49 00:00 | Build preparation: 0.257s
[Builder: preparation] I | 2020-10-06T18:49:49 00:00 | Finished build
[Software: zlib] D | 2020-10-06T18:49:49 00:00 | Forcing build because git caching is off
[NetFetcher: zlib] I | 2020-10-06T18:49:49 00:00 | Cleaning project directory C:/omnibus-ruby/src/zlib' [NetFetcher: zlib] I | 2020-10-06T18:49:49 00:00 | Extracting C:omnibus-rubycachezlib-1.2.11.tar.gz' to C:omnibus-rubysrczlib' [NetFetcher: zlib] I | 2020-10-06T18:49:49 00:00 | $ tar zxf C:omnibus-rubycachezlib-1.2.11.tar.gz -CC:omnibus-rubysrczlib I | 2020-10-06T18:49:51 00:00 | tar (child): Cannot connect to C: resolve failed I | 2020-10-06T18:49:51 00:00 | I | 2020-10-06T18:49:51 00:00 | gzip: stdin: unexpected end of file I | 2020-10-06T18:49:51 00:00 | tar: Child returned status 128 I | 2020-10-06T18:49:51 00:00 | tar: Error is not recoverable: exiting now The following shell command exited with status 2: $ tar zxf C:omnibus-rubycachezlib-1.2.11.tar.gz -CC:omnibus-rubysrczlib Output: (nothing) Error: tar (child): Cannot connect to C: resolve failed gzip: stdin: unexpected end of file tar: Child returned status 128 tar: Error is not recoverable: exiting now C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/util.rb:139:in rescue in shellout!'
C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/util.rb:134:in shellout!' C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/fetchers/net_fetcher.rb:246:in extract'
C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/fetchers/net_fetcher.rb:187:in deploy' C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/fetchers/net_fetcher.rb:71:in clean'
C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/software.rb:1232:in execute_build' C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/software.rb:1123:in build_me'
C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/project.rb:1078:in block (2 levels) in build' C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/project.rb:1077:in each'
C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/project.rb:1077:in block in build' C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/licensing.rb:62:in block in create_incrementally'
C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/licensing.rb:57:in tap' C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/licensing.rb:57:in create_incrementally'
C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/project.rb:1076:in build' C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/cli.rb:89:in build'
C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor/command.rb:27:in run' C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor/invocation.rb:127:in invoke_command'
C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor.rb:392:in dispatch' C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/cli/base.rb:33:in dispatch'
C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor/base.rb:485:in start' C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/lib/omnibus/cli.rb:42:in execute!'
C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bundler/gems/omnibus-22ce15145e83/bin/omnibus:16:in <top (required)>' C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bin/omnibus:23:in load'
C:/opscode/omnibus-toolchain/embedded/lib/ruby/gems/2.6.0/bin/omnibus:23:in `'```
Ответ №1:
Существует проект CINC, который является дистрибутивом FOSS клиента Chef Infra ™, лицензированный под Apache-2.0. Так что, если вам просто нужно обойти модель лицензирования Chef, вы можете использовать двоичные файлы клиента Cinc.