Merge branch 'stable-3.1'
* stable-3.1: InitSshd: Use correct flag to set empty passphrase for all key types Move EventEmitter on Gerrit to gr-gerrit file Change-Id: Id2be221e3b893168df67dfc76460058efe07b2e0
This commit is contained in:
@@ -124,7 +124,7 @@ public class InitSshd implements InitStep {
|
|||||||
"-q" /* quiet */,
|
"-q" /* quiet */,
|
||||||
"-t",
|
"-t",
|
||||||
"ed25519",
|
"ed25519",
|
||||||
"-P",
|
"-N",
|
||||||
emptyPassphraseArg,
|
emptyPassphraseArg,
|
||||||
"-C",
|
"-C",
|
||||||
comment,
|
comment,
|
||||||
@@ -152,7 +152,7 @@ public class InitSshd implements InitStep {
|
|||||||
"ecdsa",
|
"ecdsa",
|
||||||
"-b",
|
"-b",
|
||||||
"256",
|
"256",
|
||||||
"-P",
|
"-N",
|
||||||
emptyPassphraseArg,
|
emptyPassphraseArg,
|
||||||
"-C",
|
"-C",
|
||||||
comment,
|
comment,
|
||||||
@@ -180,7 +180,7 @@ public class InitSshd implements InitStep {
|
|||||||
"ecdsa",
|
"ecdsa",
|
||||||
"-b",
|
"-b",
|
||||||
"384",
|
"384",
|
||||||
"-P",
|
"-N",
|
||||||
emptyPassphraseArg,
|
emptyPassphraseArg,
|
||||||
"-C",
|
"-C",
|
||||||
comment,
|
comment,
|
||||||
@@ -208,7 +208,7 @@ public class InitSshd implements InitStep {
|
|||||||
"ecdsa",
|
"ecdsa",
|
||||||
"-b",
|
"-b",
|
||||||
"521",
|
"521",
|
||||||
"-P",
|
"-N",
|
||||||
emptyPassphraseArg,
|
emptyPassphraseArg,
|
||||||
"-C",
|
"-C",
|
||||||
comment,
|
comment,
|
||||||
|
|||||||
@@ -156,4 +156,41 @@
|
|||||||
// Preloaded plugins should be installed after Gerrit.install() is set,
|
// Preloaded plugins should be installed after Gerrit.install() is set,
|
||||||
// since plugin preloader substitutes Gerrit.install() temporarily.
|
// since plugin preloader substitutes Gerrit.install() temporarily.
|
||||||
Gerrit._pluginLoader.installPreloadedPlugins();
|
Gerrit._pluginLoader.installPreloadedPlugins();
|
||||||
|
|
||||||
|
// TODO(taoalpha): List all internal supported event names.
|
||||||
|
// Also convert this to inherited class once we move Gerrit to class.
|
||||||
|
Gerrit._eventEmitter = new EventEmitter();
|
||||||
|
['addListener',
|
||||||
|
'dispatch',
|
||||||
|
'emit',
|
||||||
|
'off',
|
||||||
|
'on',
|
||||||
|
'once',
|
||||||
|
'removeAllListeners',
|
||||||
|
'removeListener',
|
||||||
|
].forEach(method => {
|
||||||
|
/**
|
||||||
|
* Enabling EventEmitter interface on Gerrit.
|
||||||
|
*
|
||||||
|
* This will enable to signal across different parts of js code without relying on DOM,
|
||||||
|
* including core to core, plugin to plugin and also core to plugin.
|
||||||
|
*
|
||||||
|
* @example
|
||||||
|
*
|
||||||
|
* // Emit this event from pluginA
|
||||||
|
* Gerrit.install(pluginA => {
|
||||||
|
* fetch("some-api").then(() => {
|
||||||
|
* Gerrit.on("your-special-event", {plugin: pluginA});
|
||||||
|
* });
|
||||||
|
* });
|
||||||
|
*
|
||||||
|
* // Listen on your-special-event from pluignB
|
||||||
|
* Gerrit.install(pluginB => {
|
||||||
|
* Gerrit.on("your-special-event", ({plugin}) => {
|
||||||
|
* // do something, plugin is pluginA
|
||||||
|
* });
|
||||||
|
* });
|
||||||
|
*/
|
||||||
|
Gerrit[method] = Gerrit._eventEmitter[method].bind(Gerrit._eventEmitter);
|
||||||
|
});
|
||||||
})(window);
|
})(window);
|
||||||
@@ -381,40 +381,4 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
window.Plugin = Plugin;
|
window.Plugin = Plugin;
|
||||||
// TODO(taoalpha): List all internal supported event names.
|
|
||||||
// Also convert this to inherited class once we move Gerrit to class.
|
|
||||||
Gerrit._eventEmitter = new EventEmitter();
|
|
||||||
['addListener',
|
|
||||||
'dispatch',
|
|
||||||
'emit',
|
|
||||||
'off',
|
|
||||||
'on',
|
|
||||||
'once',
|
|
||||||
'removeAllListeners',
|
|
||||||
'removeListener',
|
|
||||||
].forEach(method => {
|
|
||||||
/**
|
|
||||||
* Enabling EventEmitter interface on Gerrit.
|
|
||||||
*
|
|
||||||
* This will enable to signal across different parts of js code without relying on DOM,
|
|
||||||
* including core to core, plugin to plugin and also core to plugin.
|
|
||||||
*
|
|
||||||
* @example
|
|
||||||
*
|
|
||||||
* // Emit this event from pluginA
|
|
||||||
* Gerrit.install(pluginA => {
|
|
||||||
* fetch("some-api").then(() => {
|
|
||||||
* Gerrit.on("your-special-event", {plugin: pluginA});
|
|
||||||
* });
|
|
||||||
* });
|
|
||||||
*
|
|
||||||
* // Listen on your-special-event from pluignB
|
|
||||||
* Gerrit.install(pluginB => {
|
|
||||||
* Gerrit.on("your-special-event", ({plugin}) => {
|
|
||||||
* // do something, plugin is pluginA
|
|
||||||
* });
|
|
||||||
* });
|
|
||||||
*/
|
|
||||||
Gerrit[method] = Gerrit._eventEmitter[method].bind(Gerrit._eventEmitter);
|
|
||||||
});
|
|
||||||
})(window);
|
})(window);
|
||||||
|
|||||||
Reference in New Issue
Block a user