Details
-
Bug
-
Status: Closed
-
Normal
-
Resolution: Fixed
-
None
-
None
-
-
Platform Core
-
Platform Core KANBAN
-
Manual Test
-
Bug Fix
-
-
No Action
-
we are adding unit tests
Description
As part of supporting module translations, we added a default mountpoint to Puppet for serving module translation files. However, this mountpoint will not be available on older versions of Puppetserver, so when an agent tries to query it, Puppetserver throws an error:
Error: /File[/Users/josh/.puppetlabs/opt/puppet/cache/locales]: Failed to generate additional resources using 'eval_generate': Error 500 on SERVER: Server Error: Not authorized to call search on /file_metadata/locales with {:rest=>"locales", :links=>"follow", :recurse=>true, :source_permissions=>"ignore", :ignore=>[".svn", "CVS", ".git", ".hg", "*.pot", "config.yaml"], :checksum_type=>"sha256"}
|
We need to handle this gracefully, since it is not really an error (it just means module translations won't be available agent-side). We cannot simply catch the exception, since at the downloader level the error has already been caught and logged as part of the HTTP handler. So ideally we should prevent the query from being made in the first place, dependent on the version of Puppetserver being queried.
The server version is currently not available beyond the HTTP layer. Two options to explore for making it available include:
1) adding something to Puppet's context object
2) creating a setting to skip downloading locale files
The context gives us a lifecycle for the data and tight control over it (no user can enable translation downloading by accident). However, a setting would give us the option to support people turning off translation downloads if they should prove problematic in certain use cases.
Attachments
Issue Links
- relates to
-
PUP-8100 Create mountpoint for locale files on master
-
- Closed
-