Project

General

Profile

Actions

Bug #12600

open

Name clash with foreman_deployments in production env

Added by Ondřej Pražák about 9 years ago. Updated about 9 years ago.

Status:
Ready For Testing
Priority:
Normal
Category:
-
Target version:
-
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

When foreman_deployments plugin is added to a Foreman instance with foreman_docker in a production environment, the server fails to start. There seems to be a name clash between these two plugins and foreman_docker controllers tend to look for class definitions in foreman_deployments' files, which results in undefined constant. Renaming controllers in question seems to resolve the issue.


Files

name_clash.png View name_clash.png 219 KB Ondřej Pražák, 11/25/2015 03:36 AM
Actions #1

Updated by The Foreman Bot about 9 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman-docker/pull/128 added
Actions #2

Updated by Dominic Cleal about 9 years ago

I don't think this is a problem with the foreman_docker plugin, https://github.com/theforeman/foreman_deployments/blob/v0.0.1/lib/foreman_deployments/engine.rb#L7 looks incorrect to me. This will add every directory recursively to the autoload path, but it should only add the top level that's required.

This may cause app/lib/foreman_deployments/ to be added as a load path, but it should be only app/lib/. Rails might then expect "Registry" to be loaded rather than ForemanDeployments::Registry because it's relative to the wrong dir.

Actions

Also available in: Atom PDF