Actions
Bug #11869
openWrong URLs generated for pxe templates on smart proxy
Status:
New
Priority:
Normal
Assignee:
-
Category:
Templates
Target version:
-
Description
Description of problem:
foreman-proxy generating wrong URLs using foreman_url() for pxe* templates.
They are pointing to Foreman, not smart proxy.
- Add smart proxy with enabled templates plugin;
- Create test provision template containing following lines:
foreman_url: <%= foreman_url %> foreman_url('provision'): <%= foreman_url('provision') %>
- Create test PXELinux template containing following lines:
foreman_url: <%= foreman_url %> foreman_url('provision'): <%= foreman_url('provision') %>
- Create test host, assign test templates and put it to build mode;
- Execute following commands:
# curl 'http://smartproxy:8000/unattended/provision?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611' | grep foreman_url # curl 'http://smartproxy:8000/unattended/PXELinux?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611' | grep foreman_url
Actual results:
# curl 'http://smartproxy:8000/unattended/provision?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611' | grep foreman_url foreman_url: http://smartproxy:8000/unattended/built?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611 foreman_url('provision'): http://smartproxy:8000/unattended/provision?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611 # curl 'http://smartproxy:8000/unattended/PXELinux?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611' | grep foreman_url foreman_url: http://foremanbox:80/unattended/built?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611 foreman_url('provision'): http://foremanbox:80/unattended/provision?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611
Expected results:
# curl 'http://smartproxy:8000/unattended/provision?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611' | grep foreman_url foreman_url: http://smartproxy:8000/unattended/built?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611 foreman_url('provision'): http://smartproxy:8000/unattended/provision?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611 # curl 'http://smartproxy:8000/unattended/PXELinux?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611' | grep foreman_url foreman_url: http://smartproxy:8000/unattended/built?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611 foreman_url('provision'): http://smartproxy:8000/unattended/provision?token=cd1cb7ba-d642-4cc0-a5dd-f30e15490611
Updated by Anonymous over 9 years ago
- Project changed from Smart Proxy to Foreman
- Category deleted (
Templates)
Actions