Git Product home page Git Product logo

Comments (6)

bgandon avatar bgandon commented on August 10, 2024 1

Actually a new ShelloutTypes library has been introduced in the 3421.x line, and the 'contain' matchers have to be replaced by their counterpart in the new library. This solves the 'ShelloutTypes' issue nicely.

There also are a couple of other patches for minor issues you might have encountered and already fixed.

Finally, the new tests that lock down lists of packages per IaaS need to be adapted to CloudStack.

I didn't implement the latter, but I have a working stemcell with those adjustments.

Cheers

from bosh-linux-stemcell-builder.

f-guichard avatar f-guichard commented on August 10, 2024

Probably not so much, but i encounter this error actually :

ubuntu@90510bbef7dd:/opt/bosh$ CANDIDATE_BUILD_NUMBER=0000.dev1 bundle exec rake stemcell:build_with_local_os_image[aws,xen,ubuntu,trusty,/tmp/bosh-ubuntu-trusty.tgz] --libdir bosh-stemcell/lib/
cd /opt/bosh/bosh-stemcell; OS_IMAGE=/tmp/bosh-ubuntu-trusty.tgz bundle exec rspec -fd spec/os_image/ubuntu_trusty_spec.rb
/opt/bosh/bosh-stemcell/spec/support/spec_assets.rb:11:in `block in <top (required)>': uninitialized constant ShelloutTypes (NameError)
Did you mean?  Shellwords
        from /home/ubuntu/.gem/ruby/2.3.1/gems/rspec-core-3.4.4/lib/rspec/core.rb:97:in `configure'
        from /opt/bosh/bosh-stemcell/spec/support/spec_assets.rb:9:in `<top (required)>'
        from /opt/bosh/bosh-stemcell/spec/spec_helper.rb:5:in `require'
        from /opt/bosh/bosh-stemcell/spec/spec_helper.rb:5:in `block in <top (required)>'

[...]

Here what i start to do, just trying to build a simple aws stemcell in 3421.x, to validate stemcell builder docker box is working good :

git clone https://github.com/orange-cloudfoundry/bosh-linux-stemcell-builder.git
cd bosh-linux-stemcell-builder/
git checkout 3421.x
cd ci/docker
./run os-image-stemcell-builder
insidedocker$ : wget "http://bosh-os-images.s3.amazonaws.com/bosh-ubuntu-trusty-os-image.tgz?versionId=8zApY4ctWhWag.8ewavNINnJli5NmLeH" -o /tmp/bosh-ubuntu-trusty.tgz
insidedocker$CANDIDATE_BUILD_NUMBER=0000.dev1 bundle exec rake stemcell:build_with_local_os_image[aws,xen,ubuntu,trusty,/tmp/bosh-ubuntu-trusty.tgz]

Probably Ruby specific stuffs ?

from bosh-linux-stemcell-builder.

dpb587-pivotal avatar dpb587-pivotal commented on August 10, 2024

Make sure you've run bundle install --localinside the container before trying to rake (link).

from bosh-linux-stemcell-builder.

f-guichard avatar f-guichard commented on August 10, 2024

Hello Danny.

Thanks for you reply.

I did the same thing with bundle install --local, still get the same issue :

insidedocker$ bundle exec rake stemcell:build_with_local_os_image[aws,xen,ubuntu,trusty,/tmp/bosh-ubuntu-trusty.tgz]
cd /opt/bosh/bosh-stemcell; OS_IMAGE=/tmp/bosh-ubuntu-trusty.tgz bundle exec rspec -fd spec/os_image/ubuntu_trusty_spec.rb
/opt/bosh/bosh-stemcell/spec/support/spec_assets.rb:11:in `block in <top (required)>': uninitialized constant ShelloutTypes (NameError)
Did you mean?  Shellwords
        from /home/ubuntu/.gem/ruby/2.3.1/gems/rspec-core-3.4.4/lib/rspec/core.rb:97:in `configure'
        from /opt/bosh/bosh-stemcell/spec/support/spec_assets.rb:9:in `<top (required)>'
        from /opt/bosh/bosh-stemcell/spec/spec_helper.rb:5:in `require'
        from /opt/bosh/bosh-stemcell/spec/spec_helper.rb:5:in `block in <top (required)>'
        from /opt/bosh/bosh-stemcell/spec/spec_helper.rb:5:in `each'
        from /opt/bosh/bosh-stemcell/spec/spec_helper.rb:5:in `<top (required)>'
        from /opt/bosh/bosh-stemcell/spec/os_image/ubuntu_trusty_spec.rb:2:in `require'
        from /opt/bosh/bosh-stemcell/spec/os_image/ubuntu_trusty_spec.rb:2:in `<top (required)>'
        from /home/ubuntu/.gem/ruby/2.3.1/gems/rspec-core-3.4.4/lib/rspec/core/configuration.rb:1361:in `load'
        from /home/ubuntu/.gem/ruby/2.3.1/gems/rspec-core-3.4.4/lib/rspec/core/configuration.rb:1361:in `block in load_spec_files'
        from /home/ubuntu/.gem/ruby/2.3.1/gems/rspec-core-3.4.4/lib/rspec/core/configuration.rb:1359:in `each'
        from /home/ubuntu/.gem/ruby/2.3.1/gems/rspec-core-3.4.4/lib/rspec/core/configuration.rb:1359:in `load_spec_files'
        from /home/ubuntu/.gem/ruby/2.3.1/gems/rspec-core-3.4.4/lib/rspec/core/runner.rb:106:in `setup'
        from /home/ubuntu/.gem/ruby/2.3.1/gems/rspec-core-3.4.4/lib/rspec/core/runner.rb:92:in `run'
        from /home/ubuntu/.gem/ruby/2.3.1/gems/rspec-core-3.4.4/lib/rspec/core/runner.rb:78:in `run'
        from /home/ubuntu/.gem/ruby/2.3.1/gems/rspec-core-3.4.4/lib/rspec/core/runner.rb:45:in `invoke'
        from /home/ubuntu/.gem/ruby/2.3.1/gems/rspec-core-3.4.4/exe/rspec:4:in `<top (required)>'
        from /home/ubuntu/.gem/ruby/2.3.1/bin/rspec:22:in `load'
        from /home/ubuntu/.gem/ruby/2.3.1/bin/rspec:22:in `<main>'

I'm first gonna destroy this container and restart from scratch. Then i should go deeper into ruby stuffs i guess, if things still go wrong.

If you have any kind of thoughts, feel free to let me know, i would really appreciate :)

from bosh-linux-stemcell-builder.

f-guichard avatar f-guichard commented on August 10, 2024

Finally, i used this workaround :

insidecontainer$ cat spec_assets.rb
require 'shellout_types/file'
require 'shellout_types/package'
require 'shellout_types/user'
require 'shellout_types/command'
require 'shellout_types/service'
require 'shellout_types/group'
require 'shellout_types/chroot'

module ShelloutTypes
  module Assertions
[...]
RSpec.configure do |config|
  config.include(Bosh::Stemcell::SpecAssets)
  config.extend(ShelloutTypes::Assertions)
  config.include(ShelloutTypes::Assertions)
end

Doesn't seem a nice way to move on anyway :-o, will need a proper fix.

from bosh-linux-stemcell-builder.

mfine30 avatar mfine30 commented on August 10, 2024

Seems like everything has been resolved in this thread. If that's not the case and you want to consider the discussion, feel free to re-open.

from bosh-linux-stemcell-builder.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.