summaryrefslogtreecommitdiff
path: root/bin/cloud-init
AgeCommit message (Collapse)Author
2013-07-30set reading /proc/uptime to false by default.Scott Moser
reading /proc/uptime is going to be slower, and no reason to do it on most things. Better to only do it when you suspect maybe a need for it.
2013-07-30add util.log_time helperScott Moser
The reason for this is that more and more things I was wanting to be able to see how long they took. This puts that time logic into a single place. It also supports (by default) reading from /proc/uptime as the timing mechanism. While that is almost certainly slower than time.time(), it does give millisecond granularity and is not affected by 'ntpdate' having run in between the two events.
2012-09-19if a logged message fails, fallback to logging to stdoutJoshua Harlow
This most commonly occurs if a user-data script does '/sbin/poweroff' where syslog was being used. Once poweroff is invoked, syslog gets killed and logging would start to show stack traces. This generally tries to continue working instead, but log to stderr.
2012-09-19First thing that we do after we can start importingJoshua Harlow
is to patch the functionality before it gets reimported.
2012-09-06Add capturing of basic signal handlers toJoshua Harlow
handle those signals more gracefully and with better messaging than what comes builtin.
2012-08-09Move the code that did the 'cloud-config' upstart event name emitting to Joshua Harlow
a config module and make it more generic in that it can take in a list of event names to emit as arguments. Add a yaml example to replace the functionality removed from the main binary.
2012-07-26emit the cloud-config event againScott Moser
The merge of 0.7.0 dropped the cloud-config initctl emission. I've added it back here, but done so in a way that doesn't force non-ubuntu (or non-upstart) distros to provide this config setting to disable it. LP: #1028674
2012-07-10Change the welcome message to be slightly differentJoshua Harlow
when running in local mode vs non-local mode, which is useful when tracking what is happening in the console and in the logs that are written out later.
2012-07-10re-setup logging to address cloud-config changes input via user-dataScott Moser
If the user has input logging information in user-data cloud-config we want to set up the logging to accept that after the data source has been read.
2012-07-10send welcome message after logging has been appliedScott Moser
in the 'cloud-init init' stages, we want the welcome message to get to the correct output as specified by the system's configuration. Ie, if the local /etc/cloud.config.d had 'output' or 'log_cfg' settings we want those to be able to affect the welcome message also. In normal operation, nothing else will go to stdout or stderr before this, and likely/hopefully nothing terribly important to the logs.
2012-07-09cloud-init: do not warn on failure to find local datasourceScott Moser
Instead of a warning, only debug this message. Warnings get to console and look scary to users.
2012-07-09Revert back to using cheetah + adjust resultant code + templatesJoshua Harlow
At this point there is a mixture of "double hash" cheetah comments and '#*' cheetah comments.
2012-07-021. Move the welcome message template string to a constant at the top of the ↵Joshua Harlow
module 2. Fix the usage of multi_log to log to only one of the places (for now) 3. Update comment about multi-log and why write_file isn't used in this case
2012-07-01Add a multi log function that can write to stderr, console and a log debug, ↵Joshua Harlow
useful in certain cases
2012-06-29If logging hasn't been enabled via '--debug' at least log the exceptions ↵Joshua Harlow
that occur to stderr.
2012-06-29Add a force option which will allow users to continue running when no ↵Joshua Harlow
datasource is found.
2012-06-29Fix the datasource not being fetched in single running mode.Joshua Harlow
2012-06-29Add a message about why the second consume_userdata occurs since its not ↵Joshua Harlow
very obvious.
2012-06-281. Update with smosers code review and comments (and put some of those ↵Joshua Harlow
comments into the files) 2. Rename consume() to consume_userdata() as it helps in figuring out what this does. 3. Fixup the tests due to #2
2012-06-27No longer need to do this special config appending, the config merger class ↵Joshua Harlow
handles this.
2012-06-221. Return which modules ran from the run module functionharlowja
2. Use that list in the main binary & adjust related comparisions
2012-06-21Ensure that nothing was ran by checking the total countharlowja
2012-06-211. Move all info() logging methods to debug() harlowja
2. Adjust comment on sources list from depends 3. For the /etc/timezone 'writing', add a header that says created by cloud-init
2012-06-201. Shorten the passed in name for frequency (and expand it later)Joshua Harlow
2. For single modules, if it doesn't run, print a warning and exit with a return code of 1
2012-06-20No need for this now that we have the imports done correctlyJoshua Harlow
2012-06-20Massive pylint + pep8 fixups!Joshua Harlow
2012-06-201. Use the name modules where transforms was usedJoshua Harlow
2. Reflect the move back to config 'modules' in the other cli options 3. Have the single mode not need to lookup the module but use the general import path
2012-06-20Remove the .py extension for this new main program binary.Joshua Harlow