Merge ~ajorgens/cloud-init:instance-identity into cloud-init:master
| Status: | Merged |
|---|---|
| Approved by: | Scott Moser on 2017-12-11 |
| Approved revision: | 0aa9fe8c552cc95335fc112ba2a9d2e52dea84ba |
| Merged at revision: | 703241a3c50f2cfec21e7c8e90616c3378ebbea2 |
| Proposed branch: | ~ajorgens/cloud-init:instance-identity |
| Merge into: | cloud-init:master |
| Diff against target: |
198 lines (+78/-22) 4 files modified
cloudinit/distros/__init__.py (+7/-8) cloudinit/ec2_utils.py (+30/-9) cloudinit/sources/DataSourceEc2.py (+25/-5) tests/unittests/test_datasource/test_aliyun.py (+16/-0) |
| Related bugs: |
| Reviewer | Review Type | Date Requested | Status |
|---|---|---|---|
| Chad Smith | Approve on 2017-12-11 | ||
| Scott Moser | 2017-08-25 | Approve on 2017-12-11 | |
| Server Team CI bot | continuous-integration | Approve on 2017-11-27 | |
|
Review via email:
|
|||
Commit Message
ec2: Use instance-identity doc for region and instance-id
The instance identity document is a better source for region information, partly because region isn't actually in meta-data at all, only availability-zone, which happens to be named similarly.
http://
| Scott Moser (smoser) wrote : | # |
I'm not opposed to this in principal, I just have a few concerns. We need to make sure we continue to work on "clones" of ec2 and do not significantly affect them negatively. Chad's recent work to use a newer version of the metadata service and also our identifying the platform (Platforms.AWS) might allow us to more aggressively take advantage of "Genuine AWS".
Someo comments in line.
At very least we need some information and more thought at this point.
PASSED: Continuous integration, rev:
https:/
Executed test runs:
SUCCESS: Checkout
SUCCESS: Unit & Style Tests
SUCCESS: Ubuntu LTS: Build
SUCCESS: Ubuntu LTS: Integration
SUCCESS: MAAS Compatability Testing
IN_PROGRESS: Declarative: Post Actions
Click here to trigger a rebuild:
https:/
| Andrew Jorgensen (ajorgens) wrote : | # |
I made a point of ensuring that the unit tests for Aliyun still worked. Lars had a PR for better mocking of meta-data service that might be helpful here.
If you have advice on which clones this needs to be tested against I'm happy to try.
| Scott Moser (smoser) wrote : | # |
Can you adjust this to search under ec2 only if on Platforms.aws ?
see comment.
- 0aa9fe8... by Andrew Jorgensen on 2017-11-27
| Andrew Jorgensen (ajorgens) wrote : | # |
Is this what you're looking for?
PASSED: Continuous integration, rev:0aa9fe8c552
https:/
Executed test runs:
SUCCESS: Checkout
SUCCESS: Unit & Style Tests
SUCCESS: Ubuntu LTS: Build
SUCCESS: Ubuntu LTS: Integration
SUCCESS: MAAS Compatability Testing
IN_PROGRESS: Declarative: Post Actions
Click here to trigger a rebuild:
https:/
| Scott Moser (smoser) wrote : | # |
I approve.
Ryan was just suggesting your use of the word 'current' be replaced with 'current as of 2017-12-11' or something.
i'm capable of doing that change.
| Chad Smith (chad.smith) wrote : | # |
+1 on this branch, tested on
As a follow-up. I'd like to see us persist this new dynamic/identity metadata route in the datasource's self.metadata dict because that is written to instance-data.json on which other consumers will eventually rely. The datasource should be persisting any metadata on which it relies to introspect the platform so that others could consume that same data.
| Chad Smith (chad.smith) wrote : | # |
sorry tested on non-ec2 openstack 'lookalike' platform as well as Ec2 proper instances. Looks good and good fallback configuration if instance-identity doesn't exist as expected.


FAILED: Continuous integration, rev:0af07e16ac1 be5a98f83176012 e5e1af3a6d9b2d /code.launchpad .net/~ajorgens/ cloud-init/ +git/cloud- init/+merge/ 329657/ +edit-commit- message
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:/ /jenkins. ubuntu. com/server/ job/cloud- init-ci/ 212/
Executed test runs:
SUCCESS: Checkout
SUCCESS: Unit & Style Tests
SUCCESS: Ubuntu LTS: Build
SUCCESS: Ubuntu LTS: Integration
SUCCESS: MAAS Compatability Testing
IN_PROGRESS: Declarative: Post Actions
Click here to trigger a rebuild: /jenkins. ubuntu. com/server/ job/cloud- init-ci/ 212/rebuild
https:/