Age | Commit message (Collapse) | Author |
|
Allow users to provide '## template: jinja' as the first line or their
#cloud-config or custom script user-data parts. When this header exists,
the cloud-config or script will be rendered as a jinja template.
All instance metadata keys and values present in
/run/cloud-init/instance-data.json will be available as jinja variables
for the template. This means any cloud-config module or script can
reference any standardized instance data in templates and scripts.
Additionally, any standardized instance-data.json keys scoped below a
'<v#>' key will be promoted as a top-level key for ease of reference in
templates. This means that '{{ local_hostname }}' is the same as using the
latest '{{ v#.local_hostname }}'.
Since instance-data is written to /run/cloud-init/instance-data.json, make
sure it is persisted across reboots when the cached datasource opject is
reloaded.
LP: #1791781
|
|
Currently the python logging module will default to a local time which may
contain an TZ offset in the values it produces, but the logged time format
does not contain the offset. Switching to UTC time for logging produces
consistent values in the cloud-init.log file and avoids issues when the
timezone is changed during boot.
LP: #1713158
|
|
This has been a recurring ask and we had initially just made the change to
the cloud-init 2.0 codebase. As the current thinking is we'll just
continue to enhance the current codebase, its desirable to relicense to
match what we'd intended as part of the 2.0 plan here.
- put a brief description of license in LICENSE file
- put full license versions in LICENSE-GPLv3 and LICENSE-Apache2.0
- simplify the per-file header to reference LICENSE
- tox: ignore H102 (Apache License Header check)
Add license header to files that ship.
Reformat headers, make sure everything has vi: at end of file.
Non-shipping files do not need the copyright header,
but at the moment tests/ have it.
|
|
to be behind trunk.
`tox -e py27` passes full test suite. Now to work on replacing mocker.
|
|
Exeptions were being swallowed completely and no way to even see them
other than log.
|
|
|
|
make pep8 now is silent on precise's pep8 ( 0.6.1-2ubuntu2).
|
|
iterable which performs the same, but can handle iterator
types beyond those three.
|
|
revno 584 broke logging. This fixes as it intended.
|
|
why we don't convert a string that is a filename to a string
buffer/io like object.
|
|
In 0.6.3, if one of the logging configs succeeded, then it was
just used. If it failed, it failed silently. This behavior was
expected, and desired.
As the code was here, we tried each log_cfg in the list anyway (possibly
using the last rather than the first) and writing a messgae including
'WARN' to stderr on failure of the log.
|
|
|
|
cloud init main entrypoint
2. Have the ability to reset the logging handlers
a. This seems needed when we initially have basic logging turned on, then later we come in and change the logging.
It seems required for some odd reason to go in and reset the handlers for the root/cloudinit loggers (needs some more investigation).
|
|
|
|
logger, show how many configs were tried if none succeeded, and for basic logging setup try to mirror more of what is in the default configuration file if all else fails
|
|
|
|
|
|
config) as well as file names (for those that have files).
|
|
importing, constant usage.
1. Move all datasources to a new sources directory
1. Rename some files to be more consistent with python file/module naming.
|