Commit Graph
1125 Commits
Author SHA1 Message Date
eridai 7b70996073 Update implementation of restartSshService for some distros. Replace service reload to service condrestart for debian+ubuntu and restart for other distros. 2014-04-24 17:36:37 +08:00
Stephen A. Zarkos ca4ed38bb4 DistInfo(): remove leading/trailing whitespace 2014-04-23 21:28:59 -07:00
Stephen A. Zarkos b682b2a9c7 Abstract platform.dist() / linux_distribution()
- Abstract this function to allow us to safely call
platform.linux_distribution() on distributions that support it or
platform.dist() on older Python versions
- Allows for shorter/cleaner comparisons
2014-04-23 20:36:22 -07:00
Eric Gable 99e8fe6998 Add exception wrappers to volitile parsing in ExtensionsConfg
Remove old plugin directory after explicit 'uninstall' issued.
2014-04-22 16:14:05 -07:00
Eric Gable 3cea3a2f17 Add support for extension handler state 'uninstall'
Now make all files under extension handler zip to be executable by root
2014-04-16 17:57:19 -07:00
Eric Gable 76c81eac86 Narrow plugin list to prevent wrong <Plugin> xml tags from being used.
Store manifest in ExtensionsConfig.Plugins xml attribute 'manifestdata' for use in CheckHeartbeat
launchCommand now uses dirpath=os.path.dirname(mfile) and subprocess.Popen(dirpath+'/'+cmd+arg,shell=True,cwd=dirpath)

Added globals provisioned, provisionError to make agent status visible to ReportHandlerStatus()
Added Util.HttpPutBlockBlob() to PUT Handler StatusReports.
Added ExtensionsConfig.ReportHandlerStatus()
Added ExtensionsConfig.CheckHeartbeat()
Add call to Agent.Run for ReportHandlerStatus() and CheckHeartbeat()
2014-04-15 17:38:46 -07:00
Eric Gable 84f86bab3b Merge pull request #25 from szarkos/ReportRoleProperties
Call ReportRoleProperties() in Run()
2014-04-15 15:58:33 -07:00
Stephen Zarkos 7c58398e26 Call ReportRoleProperties() in Run()
Ensure we report SSH key fingerprint at agent runtime if
Provisioning.Enabled=n or if SSH keys are regenerated post-provisioning.
2014-04-15 15:01:15 -07:00
Stephen Zarkos d445beb321 Update changelog 2014-04-15 12:48:36 -07:00
Eric Gable cb2c85156c Fix bug determining correct budle uri.
Fix bug in command pid status
Wrap HandlerEnvironment.json contents with [ ].
prepend ./ to basename of command for execution.
2014-04-11 19:54:27 -07:00
eridai 1a91af3215 Merge branch '2.0' of https://github.com/WindowsAzure/WALinuxAgent into 2.0 2014-04-11 11:09:39 +08:00
Eric Gable aed40f0c05 Fix crash in ExtensionsConfig.launchCommand() when HandlerManifest.json contains {[...]}
Fix crash in ExtensionsConfig.launchCommand() when parsing an invalid handler command path.
2014-04-10 14:45:09 -07:00
Stephen A. Zarkos 1e84e6c03a Merge pull request #24 from ShanghaiTeam/2.0
Set SCSI timeout for resource and data disk
2014-04-07 15:55:17 -07:00
Stephen Zarkos 4d44aaa2a1 Update changelog and version information 2014-04-07 15:54:08 -07:00
Eric Gable 0520a708a9 Filter <Plugin> tags inside the <PluginSettings> from main loop in ExtensionsConfig.Parse()
Don't clobber dom when parsing manifest.
WALinuxAgent-2.0.4
2014-04-03 13:54:42 -07:00
Eric Gable 865b87d194 Merge upstream 2014-04-03 10:48:23 -07:00
Eric Gable 101e40d056 Fix message.encode syntax. 2014-04-03 10:40:32 -07:00
Stephen Zarkos 10d7deebda Update changelog and versioning for 2.0.4 2014-04-02 12:29:48 -07:00
Eric Gable f1fa8cfbb0 Bugfix for LogToFile, LogToCon, force encoding to ascii. 2014-04-01 21:38:46 -07:00
Eric Gable 472b2e2963 Chnages to ExtensionsConfig for public/protected config values 2014-03-31 14:41:04 -07:00
Eric Gable 72dd28d8aa Merge branch '2.0' of https://github.com/WindowsAzure/WALinuxAgent into 2.0 2014-03-26 11:53:55 -07:00
Eric Gable f18abd304b ExtensionsConfig add 'name' property to HandlerEnvironment.json 2014-03-26 11:52:49 -07:00
yuezh 3a40adaf4e Derive centosDistro from redhatDistro 2014-03-26 10:41:57 +08:00
yuezh 730d8000fd Fix static hostname on RHEL7 Beta 2014-03-26 10:41:43 +08:00
Stephen Zarkos fa6f7695a4 Update RPM spec to create /var/lib/waagent 2014-03-25 13:28:39 -07:00
eridai b934ca3d16 Set SCSI timeout for resource and data disk 2014-03-24 12:42:54 +08:00
Stephen Zarkos 100ccd3e82 Changelog and minor doc updates 2014-03-20 13:16:42 -07:00
Eric Gable 5bcb0205fe Call handler scripts directly
Changed:
ExtensionsConfig.launchCommand()
2014-03-18 17:29:31 -07:00
eridai 794a3c633b Move the Linux distro specific methods(initScsiDiskTimeout, setScsiDiskTimeout, setBlockDeviceTimeout) to AbsractDistro and override these methods for FreeBSD. 2014-03-18 17:10:48 +08:00
Eric Gable 42c46a5f5b Debugging ExtensionsConfig. 2014-03-17 16:23:36 -07:00
Eric Gable b5895d5a91 Move ExtensionsConfig.parse() to the health report loop in Agent.Run()
Support the full range of Handler commands.
2014-03-13 16:16:42 -07:00
Eric Gable da4e981544 Create the status and config dirs after manifest is read. 2014-03-06 12:38:18 -08:00
Eric Gable 3c4ae20224 Experimental json extension handler replaces xml extension in ExtensionsConfig.
GetMacAddress() - if ifname is empty keep trying.
FreeBSDDistro - Handle potential custom data by increasing length of dd from 1 (2048 byte) block to 33.
2014-03-05 17:51:03 -08:00
Eric Gable fd03cf54d3 Merge plugin branch 2014-02-19 15:19:30 -08:00
Eric Gable b7f8091b2a Fix bug in json logic 2014-02-19 14:44:21 -08:00
Eric Gable 05b043a2e2 Updates for json plugin handlers. 2014-02-19 14:04:01 -08:00
Stephen A. Zarkos 658088b0cc Fix python version requirements in README
We really need Python 5+ for this version.
2014-02-18 17:50:56 -08:00
Stephen Zarkos 1bd1855241 Minor README updates 2014-02-14 13:46:40 -08:00
Stephen Zarkos 593c485c5b Minor doc cleanup 2014-02-14 13:41:55 -08:00
Stephen Zarkos ff5d41f849 Updated version string and changelog 2014-02-14 13:28:33 -08:00
Eric Gable 8194f12549 Add updates for FreeBSDDistro
Add /usr/local/bin to path in bsd_init_file.
Use non-threaded method for activate resource disk to work around python thread bugs in FreeBSD10
Add call to dhclient if inet_addr is not set for hn0
Log to console even if verbose.
2014-02-12 12:09:06 -08:00
Eric Gable 407388fce7 Remove unneeded processing from HostingEnvironmentConfig.Process 2014-02-12 11:56:45 -08:00
Eric Gable 1ed7765319 Write out the base64 config data to zip_dir so the resource extension plugin can process it.
Changed:
ExtensionsConfig.Parse()
2014-02-10 15:15:44 -08:00
Eric Gable 6af746d99d Adding ResourceExtensions (Plugins).
Write configuration to file ExtensionsConfig.xml.
If <enabled> is true, attempt to download the plugin.
Get the manifest from 'location/failoverlocation' tag.
Download and extract the archive to LibDir/plugin_manifest_name/.
Read 'installCommand' from the PluginManifest.xml <Plugin> tag.
Create execuatable shell script containig 'installCommand'.
Spawn the script and report the PID to the Log.
TBD - disable plugin when <enabled> is false.

Added:
class ExtensionsConfig
Changed:
class HostingEnvironmentConfig
class GoalState
2014-02-05 15:57:28 -08:00
Eric Gable 55e62008a9 Add FedoraDistro 2014-01-24 16:00:56 -08:00
Stephen A. Zarkos c1122a31c1 WALinuxAgent-2.0.3 WALinuxAgent-2.0.3 2014-01-17 10:08:22 -08:00
Stephen Zarkos 8839d2cb91 Update RPM spec file 2014-01-16 16:22:53 -08:00
Stephen Zarkos 1805a0d715 Update Changelog 2014-01-16 16:21:38 -08:00
Eric Gable 0e8ecc4b54 Add exception awareness to GetFileContents, SetFileContents, AppendFileContents.
Return None and complain to log if exception occurs.
2014-01-16 15:52:08 -08:00
Eric Gable acd8db0198 Send host-name patch. Do not put send host-name "new-hostname" in dhclient.conf if the hostname value is <hostname> or gethostname(); .
Also remove unused method group setHostname() from all distro classes.
Remove duplicate call to EnvMonitor(object).MyDistro.publishHostname(self.HostName) which is now called from WaAgent.UpdateAndPublishHostName(self.HostName).

Removed:
redhatDistro.setHostname()
centosDistro.setHostname()
debianDistro.setHostname()

Changed:

AbstractDistro.publishHostname()
redhatDistro.publishHostname()
centosDistro.publishHostname()
debianDistro.publishHostname()
2014-01-13 14:13:37 -08:00