Bug 1002691 - Puppet handler depends on consumer config, which may not be available
Summary: Puppet handler depends on consumer config, which may not be available
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Pulp
Classification: Retired
Component: consumers
Version: Master
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: 2.3.0
Assignee: Jeff Ortel
QA Contact: Preethi Thomas
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-08-29 17:49 UTC by Michael Hrivnak
Modified: 2013-12-09 14:31 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-12-09 14:31:27 UTC
Embargoed:


Attachments (Terms of Use)

Description Michael Hrivnak 2013-08-29 17:49:45 UTC
The Puppet handler depends on being able to access the consumer config, which will not be available when used by katello-agent. We need some other way for it to know the hostname of the server. We should also reconsider whether pulp.agent.gofer.pulp.Conduit should offer a consumer config.

Comment 1 Jeff Ortel 2013-09-17 19:55:46 UTC
https://github.com/pulp/pulp_puppet/pull/73

Comment 2 Jeff Ortel 2013-09-18 23:58:42 UTC
build: 2.3.0-0.14.alpha

Comment 3 Preethi Thomas 2013-10-09 15:00:37 UTC
Jeff, Mike could you please give some steps to verify this bug

Comment 5 Preethi Thomas 2013-10-09 17:41:12 UTC
verified

[root@qe-blade-04 ~]# rpm -qa |grep katello-agent
katello-agent-1.4.4-3.el6sat.noarch
[root@qe-blade-04 ~]# rpm -qa |grep puppet
puppet-3.2.4-1.el6_4.noarch
[root@qe-blade-04 ~]# puppet module install puppetlabs-apache
Notice: Preparing to install into /etc/puppet/modules ...
Notice: Downloading from https://forge.puppetlabs.com ...
Notice: Installing -- do not interrupt ...
/etc/puppet/modules
└── puppetlabs-apache (v0.9.0)
[root@qe-blade-04 ~]# puppet module list
/etc/puppet/modules
├── puppetlabs-apache (v0.9.0)
├── puppetlabs-concat (v1.0.0)
└── puppetlabs-stdlib (v4.1.0)
/usr/share/puppet/modules (no modules installed)
[root@qe-blade-04 ~]#

Comment 6 Preethi Thomas 2013-10-09 18:15:07 UTC
In [6]: pic.POST('/v2/repositories/puppet-copy/distributors/', {'distributor_type_id':'puppet_install_distributor', 'distributor_id':'puppet_install_distributor', 'auto_publish': False, 'distributor_config': {'install_path':'/tmp/puppet'}}) 
Request Body
{
  "distributor_id": "puppet_install_distributor", 
  "distributor_type_id": "puppet_install_distributor", 
  "distributor_config": {
    "install_path": "/tmp/puppet"
  }, 
  "auto_publish": false
}
Response Body
{
  "repo_id": "puppet-copy", 
  "_ns": "repo_distributors", 
  "last_publish": null, 
  "auto_publish": false, 
  "scheduled_publishes": [], 
  "distributor_type_id": "puppet_install_distributor", 
  "scratchpad": null, 
  "_id": {
    "$oid": "52559c57f4fc721f20665c16"
  }, 
  "config": {
    "install_path": "/tmp/puppet"
  }, 
  "id": "puppet_install_distributor"
}
Out[6]: 
(201,
 {u'_id': {u'$oid': u'52559c57f4fc721f20665c16'},
  u'_ns': u'repo_distributors',
  u'auto_publish': False,
  u'config': {u'install_path': u'/tmp/puppet'},
  u'distributor_type_id': u'puppet_install_distributor',
  u'id': u'puppet_install_distributor',
  u'last_publish': None,
  u'repo_id': u'puppet-copy',
  u'scheduled_publishes': [],
  u'scratchpad': None})

In [7]: pic.POST('/v2/repositories/puppet-copy/actions/publish/', {'id':'puppet_install_distributor'})
Request Body
{
  "id": "puppet_install_distributor"
}
Response Body
{
  "task_group_id": null, 
  "call_request_id": "00105200-a85b-4628-8ee8-1f6ea33fc7ab", 
  "exception": null, 
  "_href": "/pulp/api/v2/tasks/00105200-a85b-4628-8ee8-1f6ea33fc7ab/", 
  "task_id": "00105200-a85b-4628-8ee8-1f6ea33fc7ab", 
  "call_request_tags": [
    "pulp:repository:puppet-copy", 
    "pulp:action:publish"
  ], 
  "reasons": [], 
  "start_time": null, 
  "traceback": null, 
  "schedule_id": null, 
  "finish_time": null, 
  "state": "waiting", 
  "result": null, 
  "dependency_failures": {}, 
  "call_request_group_id": null, 
  "progress": {}, 
  "principal_login": "admin", 
  "response": "accepted", 
  "tags": [
    "pulp:repository:puppet-copy", 
    "pulp:action:publish"
  ]
}
Out[7]: 
(202,
 {u'_href': u'/pulp/api/v2/tasks/00105200-a85b-4628-8ee8-1f6ea33fc7ab/',
  u'call_request_group_id': None,
  u'call_request_id': u'00105200-a85b-4628-8ee8-1f6ea33fc7ab',
  u'call_request_tags': [u'pulp:repository:puppet-copy',
                         u'pulp:action:publish'],
  u'dependency_failures': {},
  u'exception': None,
  u'finish_time': None,
  u'principal_login': u'admin',
  u'progress': {},
  u'reasons': [],
  u'response': u'accepted',
  u'result': None,
  u'schedule_id': None,
  u'start_time': None,
  u'state': u'waiting',
  u'tags': [u'pulp:repository:puppet-copy', u'pulp:action:publish'],
  u'task_group_id': None,
  u'task_id': u'00105200-a85b-4628-8ee8-1f6ea33fc7ab',
  u'traceback': None})

In [8]:  pic.GET('/v2/repositories/puppet-copy/history/publish/puppet_install_distributor/')
   ...: 
Response Body
[
  {
    "result": "success", 
    "exception": null, 
    "repo_id": "puppet-copy", 
    "started": "2013-10-09T14:11:48-04:00", 
    "_ns": "repo_publish_results", 
    "completed": "2013-10-09T14:11:48-04:00", 
    "traceback": null, 
    "distributor_type_id": "puppet_install_distributor", 
    "_id": {
      "$oid": "52559c64f4fc721f20665c20"
    }, 
    "summary": "success", 
    "error_message": null, 
    "distributor_id": "puppet_install_distributor", 
    "id": "52559c64f4fc721f20665c20", 
    "details": {
      "errors": [], 
      "success_unit_keys": [
        {
          "version": "4.1.0", 
          "name": "stdlib", 
          "author": "puppetlabs"
        }
      ]
    }
  }
]
Out[8]: 
(200,
 [{u'_id': {u'$oid': u'52559c64f4fc721f20665c20'},
   u'_ns': u'repo_publish_results',
   u'completed': u'2013-10-09T14:11:48-04:00',
   u'details': {u'errors': [],
                u'success_unit_keys': [{u'author': u'puppetlabs',
                                        u'name': u'stdlib',
                                        u'version': u'4.1.0'}]},
   u'distributor_id': u'puppet_install_distributor',
   u'distributor_type_id': u'puppet_install_distributor',
   u'error_message': None,
   u'exception': None,
   u'id': u'52559c64f4fc721f20665c20',
   u'repo_id': u'puppet-copy',
   u'result': u'success',
   u'started': u'2013-10-09T14:11:48-04:00',
   u'summary': u'success',
   u'traceback': None}])


[root@qe-blade-04 yum.repos.d]# puppet module list --modulepath /tmp/puppet
/tmp/puppet
└── puppetlabs-stdlib (v4.1.0)
[root@qe-blade-04 yum.repos.d]#

Comment 7 Preethi Thomas 2013-12-09 14:31:27 UTC
Pulp 2.3 released.


Note You need to log in before you can comment on or make changes to this bug.