Merge lp:~harlowja/cloud-init/write-files-fetch-from-somewhere into lp:~cloud-init-dev/cloud-init/trunk
| Status: | Rejected |
|---|---|
| Rejected by: | Scott Moser on 2017-06-06 |
| Proposed branch: | lp:~harlowja/cloud-init/write-files-fetch-from-somewhere |
| Merge into: | lp:~cloud-init-dev/cloud-init/trunk |
| Diff against target: |
218 lines (+132/-9) 3 files modified
cloudinit/config/cc_write_files.py (+27/-3) cloudinit/url_helper.py (+20/-6) tests/unittests/test_handler/test_handler_write_files.py (+85/-0) |
| To merge this branch: | bzr merge lp:~harlowja/cloud-init/write-files-fetch-from-somewhere |
| Related bugs: |
| Reviewer | Review Type | Date Requested | Status |
|---|---|---|---|
| Server Team CI bot | continuous-integration | Needs Fixing on 2016-07-22 | |
| Scott Moser | 2015-03-31 | Needs Fixing on 2015-04-01 | |
|
Review via email:
|
|||
- 1091. By Joshua Harlow on 2015-03-31
-
Fix reading of files for py3.x
util.read_
file_or_ url needs to have a __str__ that
returns the right type for py3.x; so make sure that if
binary data is read that it is decoded. - 1092. By Joshua Harlow on 2015-03-31
-
Only do the decoding on py3.x
- 1093. By Joshua Harlow on 2015-03-31
-
Some contents/text tweaks and handler tests
| Joshua Harlow (harlowja) wrote : | # |
Thats fine with me; I was debating whether to try to interpret content or not and am fine either way; will adjust that soon.
- 1094. By Joshua Harlow on 2015-04-07
-
Avoid fetching automagically and add test for this
- 1095. By Joshua Harlow on 2015-04-07
-
Fixs log entry/output
FAILED: Continuous integration, rev:1095
No commit message was specified in the merge proposal. Click on the following link and set the commit message (if you want a jenkins rebuild you need to trigger it yourself):
https:/
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/
| Scott Moser (smoser) wrote : | # |
Hi,
Josh, Please re-submit this. I like the functionality. Please re-submit in git.
Thank you for taking the time to contribute to cloud-init. Cloud-init has moved its revision control system to git. As a result, we are marking all bzr merge proposals as 'rejected'. If you would like to re-submit this proposal for review, please do so by following the current HACKING documentation at http://
I'm going to mark this as 'merged', because I think it is actually
upstream at
https:/
Unmerged revisions
- 1095. By Joshua Harlow on 2015-04-07
-
Fixs log entry/output
- 1094. By Joshua Harlow on 2015-04-07
-
Avoid fetching automagically and add test for this
- 1093. By Joshua Harlow on 2015-03-31
-
Some contents/text tweaks and handler tests
- 1092. By Joshua Harlow on 2015-03-31
-
Only do the decoding on py3.x
- 1091. By Joshua Harlow on 2015-03-31
-
Fix reading of files for py3.x
util.read_
file_or_ url needs to have a __str__ that
returns the right type for py3.x; so make sure that if
binary data is read that it is decoded. - 1090. By Joshua Harlow on 2015-03-31
-
Fix extra space
- 1089. By Joshua Harlow on 2015-03-31
-
Allow write_files to fetch content
Instead of requring write_files to be always provided
all the data (which can be big/large blobs); allow it to
fetch that data from either a local file or a http/https
url instead (saving precious user-data space).


I think better to require user to be explicit that this is a remote file. '.
I don't like the interpretation of content. The problem being, if it seems quite likely that some config file that someone would want to 'write-files' of might start with 'http://
If they try to send such a content, then cloud-init would interpret that content and pull the url.
So, in short, I'd rather: www.yahoo. com of-cloud- init-for- copy /usr/bin/ true old-write_ files
write_files:
- path: /myfile-from-remote
content_url: http://
- path: /odd-use-
content_url: file://
- path: /myfile-
content: "Hi Mom"
Than: www.yahoo. com
write_files:
- path: /myfile-from-remote
content: http://
in the event of an entry having both 'content_url' and 'content', I guess I'd warn and use the 'content' field.
Agree/ disagree?