Feature #1946
let file() obtain file contents from fileserver and/or module space
| Status: | Accepted | Start: | 02/08/2009 | |
|---|---|---|---|---|
| Priority: | Normal | Due date: | ||
| Assigned to: | - | % Done: | 0% |
|
| Category: | fileserving | |||
| Target version: | Statler | |||
| Affected version: | 0.24.5 | Branch: | ||
| Keywords: | performance scaling | |||
| Votes: | 3 |
Description
file() as it is requires an absolute pathname.
It would be nice if relative pathnames would be resolved relative to the root of the fileserver ‘files’ hierarchy, unless they start out with a module name, in which case the module space should be searched.
For instance
file(“etc/motd”) ==> puppet:///files/etc/motd files(“motd/etc/motd”) ==> …/modules/motd/files/etc/motd
Related issues
| duplicated by Puppet - Bug #2771: file function should use puppet://url/module/ nomenclatur... | Duplicate | 11/02/2009 |
History
Updated by martin krafft over 1 year ago
The last line should have been file(), not files():
file(“motd/etc/motd”) > …/modules/motd/files/etc/motd
Updated by James Turnbull over 1 year ago
- Status changed from Unreviewed to Needs design decision
- Assigned to set to Luke Kanies
Updated by Luke Kanies over 1 year ago
- Category set to fileserving
- Status changed from Needs design decision to Accepted
There certainly needs to be some way to load module files this way, but there’s no canonical ‘files’ section in the fileserver.
As a general rule, though, I agree – accepting a URI would make sense, and then we can pass it through the normal file routing process. I’d only accept this as a URI, though.
Updated by Luke Kanies 9 months ago
- Assigned to deleted (
Luke Kanies) - Target version set to 2.6.0
Updated by James Turnbull 6 months ago
- Target version changed from 2.6.0 to Statler
Updated by Michael DeHaan 6 months ago
- Keywords set to performance scaling
Talking with eric0 online, the reason he wants “url” is not just for path convience as this subject suggests, but to use other transports.
For instance https:// provides better load balanancing and speed options.
(Other folks may want to choose to use NFS. (Or even smbfs). Naturally those could be mounted, though we should keep Windows fileshare notation in mind.)
I realize security is somewhat different here, but may not matter deeply in all environments and may only be bypassed for large files.