Uploaded image for project: 'Beaker'
  1. Beaker
  2. BKR-1699

Beaker task can't find Hosts - Gitlab Pipeline in Docker

    XMLWordPrintable

    Details

    • Type: Task
    • Status: Closed
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
    • Environment:

      Gitlab runner running in docker that runs on a Ubuntu 20

    • Template:
    • QA Risk Assessment:
      Needs Assessment

      Description

      When executing a Gitlab pipeline with Baseline Module applied to all puppet managed nodes, I get the following error:

      $ bundle exec rake beaker:ubuntu-1404-docker
      Libhoney::Client: no writekey configured, disabling sending events
      TEST_TIERS env variable not defined. Defaulting to run all tests.
      /usr/local/rvm/rubies/ruby-2.5.3/bin/ruby -I/builds/puppet/base/vendor/ruby/2.5.0/gems/rspec-core-3.10.1/lib:/builds/puppet/base/vendor/ruby/2.5.0/gems/rspec-support-3.10.2/lib /builds/puppet/base/vendor/ruby/2.5.0/gems/rspec-core-3.10.1/exe/rspec spec/acceptance
      /builds/puppet/base/vendor/ruby/2.5.0/gems/beaker-rspec-6.2.4/lib/beaker-rspec/helpers/serverspec.rb:43: warning: already initialized constant Module::VALID_OPTIONS_KEYS
      /builds/puppet/base/vendor/ruby/2.5.0/gems/specinfra-2.82.2/lib/specinfra/configuration.rb:4: warning: previous definition of VALID_OPTIONS_KEYS was here
      Beaker::Hypervisor, found some docker boxes to create
      Provisioning docker
      provisioning example-node.example
      Using docker server at Warning: Skipping ip method to ssh to host as its value is not set. Refer to https://github.com/puppetlabs/beaker/tree/master/docs/how_to/ssh_connection_preference.md to remove this warning
        Warning: Try 1 -- Host example-node.example unreachable: SocketError - getaddrinfo: Name or service not known
        Warning: Trying again in 3 seconds
      

      The command is:

      bundle exec rake beaker:ubuntu-1404-docker
      

      Hosts are stored as `.yml` files under `spec/acceptance/nodesets` and here is a `.yml` file as an example:

       

      HOSTS:
        example-node.example:
          platform: ubuntu-14.04-amd64
          image: ubuntu:14.04
          hypervisor: docker
          ssh_preference:
          - :ip
          - :hostname
          - :vmhostname
          docker_preserve_image: false
          docker_cmd: '["/sbin/init"]'
          docker_image_commands:
            - 'rm /usr/sbin/policy-rc.d && rm /sbin/initctl && dpkg-divert --rename --remove /sbin/initctl'
            - 'apt-get install -y net-tools wget curl locales apt-transport-https software-properties-common iptables'
            - 'locale-gen en_US.UTF-8'
      CONFIG:
        type: aio
        puppet_collection: puppet6
        puppet_agent_version: 6.17.0
      

       

      What am I missing?

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            lpossamai Lucas Possamai
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Zendesk Support