puppet-openstack-unit-*-centos-8 is failing because of wonrg path where bunde is installed

Bug #1866176 reported by Takashi Kajinami on 2020-03-05
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
puppet-openstack-integration
Undecided
Takashi Kajinami

Bug Description

Currently unit tests on centos 8 is failing with the following error

~~~
2020-03-05 02:17:11.332396 | TASK [install ruby bundler and run it]
2020-03-05 02:17:14.232903 | centos-8 | HEAD https://api.rubygems.org/api/v1/dependencies
2020-03-05 02:17:14.233014 | centos-8 | 200 OK
2020-03-05 02:17:14.233038 | centos-8 | GET https://api.rubygems.org/api/v1/dependencies?gems=bundler
2020-03-05 02:17:14.233064 | centos-8 | 200 OK
2020-03-05 02:17:14.233083 | centos-8 | Getting SRV record failed: DNS result has no information for _rubygems._tcp.api.rubygems.org
2020-03-05 02:17:14.233101 | centos-8 | GET https://api.rubygems.org/quick/Marshal.4.8/bundler-2.1.4.gemspec.rz
2020-03-05 02:17:14.233119 | centos-8 | 200 OK
2020-03-05 02:17:14.233137 | centos-8 | Downloading gem bundler-2.1.4.gem
2020-03-05 02:17:14.233158 | centos-8 | GET https://api.rubygems.org/gems/bundler-2.1.4.gem
2020-03-05 02:17:14.233180 | centos-8 | 200 OK
2020-03-05 02:17:14.233198 | centos-8 | /home/zuul/.gem/ruby/gems/bundler-2.1.4/CHANGELOG.md
2020-03-05 02:17:14.233215 | centos-8 | /home/zuul/.gem/ruby/gems/bundler-2.1.4/LICENSE.md
...
2020-03-05 02:17:14.416084 | centos-8 | /home/zuul/.gem/ruby/gems/bundler-2.1.4/man/index.txt
2020-03-05 02:17:14.416101 | centos-8 | /home/zuul/bin/bundle
2020-03-05 02:17:14.416118 | centos-8 | /home/zuul/bin/bundler
2020-03-05 02:17:14.416135 | centos-8 | Successfully installed bundler-2.1.4
2020-03-05 02:17:14.416153 | centos-8 | 1 gem installed
2020-03-05 02:17:14.418277 | centos-8 | /bin/sh: line 21: /home/zuul/workspace/.bundled_gems/bin/bundle: No such file or directory
2020-03-05 02:17:14.418660 | centos-8 | /bin/sh: line 22: /home/zuul/workspace/.bundled_gems/bin/bundle: No such file or directory
~~~

It seems that bundle is installed in wrong directory, /home/zuul/.gem, instead of the specified directory, /home/zuul/workspace/.bundled_gems .

Fix proposed to branch: master
Review: https://review.opendev.org/711477

Changed in puppet-openstack-integration:
assignee: nobody → Takashi Kajinami (kajinamit)
status: New → In Progress
Takashi Kajinami (kajinamit) wrote :

Seems that currently --user-install is enabled by default[1], and we need to disable it to make "gem install" use GEM_HOME.

[1] https://github.com/rubygems/rubygems/pull/2847

Reviewed: https://review.opendev.org/711477
Committed: https://git.openstack.org/cgit/openstack/puppet-openstack-integration/commit/?id=3b266e9a36343b5e26866beeb1a129ab6421ac1a
Submitter: Zuul
Branch: master

commit 3b266e9a36343b5e26866beeb1a129ab6421ac1a
Author: Takashi Kajinami <email address hidden>
Date: Fri Mar 6 00:18:42 2020 +0900

    Set --no-user-install in gem install

    Since --user-install was enabled by default in gem[1], we need to set
    --no-user-install to make "gem install" refer GEM_HOME.

    Closes-Bug: #1866176
    [1] https://github.com/rubygems/rubygems/pull/2847

    Change-Id: Id640ec2cb1012e99826cb990fb4995945183521d

Changed in puppet-openstack-integration:
status: In Progress → Fix Released

Reviewed: https://review.opendev.org/712016
Committed: https://git.openstack.org/cgit/openstack/puppet-openstack-integration/commit/?id=0be086fef570892654e288b086ab175df418fa72
Submitter: Zuul
Branch: master

commit 0be086fef570892654e288b086ab175df418fa72
Author: Takashi Kajinami <email address hidden>
Date: Tue Mar 10 14:16:02 2020 +0900

    Explicitly set --bindir when isntalling bundle

    ... so that we can make sure that bundle command is installed in
    GEM_HOME/bin directory.

    Change-Id: I1ea78bbd2b7fe22d510e10b0c96c0ed7bdc9f8a3
    Closes-Bug: #1866176

Fix proposed to branch: stable/train
Review: https://review.opendev.org/712199

Reviewed: https://review.opendev.org/712198
Committed: https://git.openstack.org/cgit/openstack/puppet-openstack-integration/commit/?id=f9050dc5433dc7497e7287b2b0490ba04234644b
Submitter: Zuul
Branch: stable/train

commit f9050dc5433dc7497e7287b2b0490ba04234644b
Author: Takashi Kajinami <email address hidden>
Date: Fri Mar 6 00:18:42 2020 +0900

    Set --no-user-install in gem install

    Since --user-install was enabled by default in gem[1], we need to set
    --no-user-install to make "gem install" refer GEM_HOME.

    Closes-Bug: #1866176
    [1] https://github.com/rubygems/rubygems/pull/2847

    Change-Id: Id640ec2cb1012e99826cb990fb4995945183521d
    (cherry picked from commit 3b266e9a36343b5e26866beeb1a129ab6421ac1a)

tags: added: in-stable-train

Reviewed: https://review.opendev.org/712199
Committed: https://git.openstack.org/cgit/openstack/puppet-openstack-integration/commit/?id=7d64abe4aaf7ba5c7ebaf33fa41808c9537028bd
Submitter: Zuul
Branch: stable/train

commit 7d64abe4aaf7ba5c7ebaf33fa41808c9537028bd
Author: Takashi Kajinami <email address hidden>
Date: Tue Mar 10 14:16:02 2020 +0900

    Explicitly set --bindir when isntalling bundle

    ... so that we can make sure that bundle command is installed in
    GEM_HOME/bin directory.

    Change-Id: I1ea78bbd2b7fe22d510e10b0c96c0ed7bdc9f8a3
    Closes-Bug: #1866176
    (cherry picked from commit 0be086fef570892654e288b086ab175df418fa72)

Fix proposed to branch: stable/rocky
Review: https://review.opendev.org/717999

Fix proposed to branch: stable/queens
Review: https://review.opendev.org/718004

Reviewed: https://review.opendev.org/718003
Committed: https://git.openstack.org/cgit/openstack/puppet-openstack-integration/commit/?id=8691833ac2a4daab90279edf0536f8f729ca5f35
Submitter: Zuul
Branch: stable/queens

commit 8691833ac2a4daab90279edf0536f8f729ca5f35
Author: Takashi Kajinami <email address hidden>
Date: Fri Mar 6 00:18:42 2020 +0900

    Set --no-user-install in gem install

    Since --user-install was enabled by default in gem[1], we need to set
    --no-user-install to make "gem install" refer GEM_HOME.

    Closes-Bug: #1866176
    [1] https://github.com/rubygems/rubygems/pull/2847

    Change-Id: Id640ec2cb1012e99826cb990fb4995945183521d
    (cherry picked from commit 3b266e9a36343b5e26866beeb1a129ab6421ac1a)

tags: added: in-stable-queens

Reviewed: https://review.opendev.org/718004
Committed: https://git.openstack.org/cgit/openstack/puppet-openstack-integration/commit/?id=2b74a8cb434d8202d06fb6570d359003799b4ab0
Submitter: Zuul
Branch: stable/queens

commit 2b74a8cb434d8202d06fb6570d359003799b4ab0
Author: Takashi Kajinami <email address hidden>
Date: Tue Mar 10 14:16:02 2020 +0900

    Explicitly set --bindir when isntalling bundle

    ... so that we can make sure that bundle command is installed in
    GEM_HOME/bin directory.

    Change-Id: I1ea78bbd2b7fe22d510e10b0c96c0ed7bdc9f8a3
    Closes-Bug: #1866176
    (cherry picked from commit 0be086fef570892654e288b086ab175df418fa72)

Reviewed: https://review.opendev.org/717985
Committed: https://git.openstack.org/cgit/openstack/puppet-openstack-integration/commit/?id=80e7d59d52c4020d77eeafcd370fc78c8ef7e618
Submitter: Zuul
Branch: stable/stein

commit 80e7d59d52c4020d77eeafcd370fc78c8ef7e618
Author: Takashi Kajinami <email address hidden>
Date: Fri Mar 6 00:18:42 2020 +0900

    Set --no-user-install in gem install

    Since --user-install was enabled by default in gem[1], we need to set
    --no-user-install to make "gem install" refer GEM_HOME.

    Closes-Bug: #1866176
    [1] https://github.com/rubygems/rubygems/pull/2847

    Change-Id: Id640ec2cb1012e99826cb990fb4995945183521d
    (cherry picked from commit 3b266e9a36343b5e26866beeb1a129ab6421ac1a)
    (cherry picked from commit f9050dc5433dc7497e7287b2b0490ba04234644b)

tags: added: in-stable-stein

Reviewed: https://review.opendev.org/718002
Committed: https://git.openstack.org/cgit/openstack/puppet-openstack-integration/commit/?id=7f59e9c845d6722b2e26ffa291f7fcd8be95d89b
Submitter: Zuul
Branch: stable/stein

commit 7f59e9c845d6722b2e26ffa291f7fcd8be95d89b
Author: Takashi Kajinami <email address hidden>
Date: Tue Mar 10 14:16:02 2020 +0900

    Explicitly set --bindir when isntalling bundle

    ... so that we can make sure that bundle command is installed in
    GEM_HOME/bin directory.

    Change-Id: I1ea78bbd2b7fe22d510e10b0c96c0ed7bdc9f8a3
    Closes-Bug: #1866176
    (cherry picked from commit 0be086fef570892654e288b086ab175df418fa72)
    (cherry picked from commit 7d64abe4aaf7ba5c7ebaf33fa41808c9537028bd)

tags: added: in-stable-rocky

Reviewed: https://review.opendev.org/717998
Committed: https://git.openstack.org/cgit/openstack/puppet-openstack-integration/commit/?id=3bb858507f4279a6bc771ccad4a4ed6efd30bf99
Submitter: Zuul
Branch: stable/rocky

commit 3bb858507f4279a6bc771ccad4a4ed6efd30bf99
Author: Takashi Kajinami <email address hidden>
Date: Fri Mar 6 00:18:42 2020 +0900

    Set --no-user-install in gem install

    Since --user-install was enabled by default in gem[1], we need to set
    --no-user-install to make "gem install" refer GEM_HOME.

    Closes-Bug: #1866176
    [1] https://github.com/rubygems/rubygems/pull/2847

    Change-Id: Id640ec2cb1012e99826cb990fb4995945183521d
    (cherry picked from commit 3b266e9a36343b5e26866beeb1a129ab6421ac1a)

Reviewed: https://review.opendev.org/717999
Committed: https://git.openstack.org/cgit/openstack/puppet-openstack-integration/commit/?id=e12561cadc1a7c8e8a1701d84b5580cc702694ef
Submitter: Zuul
Branch: stable/rocky

commit e12561cadc1a7c8e8a1701d84b5580cc702694ef
Author: Takashi Kajinami <email address hidden>
Date: Tue Mar 10 14:16:02 2020 +0900

    Explicitly set --bindir when isntalling bundle

    ... so that we can make sure that bundle command is installed in
    GEM_HOME/bin directory.

    Change-Id: I1ea78bbd2b7fe22d510e10b0c96c0ed7bdc9f8a3
    Closes-Bug: #1866176
    (cherry picked from commit 0be086fef570892654e288b086ab175df418fa72)

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers