When trying to setup a database server through drush like I did with 6.x-1.9 then I get the error, "Unknown option: --master_db" and I don't see any alternatives in 'drush help provision-save'. In irc ergonlogic noticed, "it's been removed from db.drush.inc... hmm, now it's in db/Provision/Service/db.php"

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

trrroy’s picture

The attached patch is working for me. Now I can use:

drush provision-save @server_192168123123 --context_type=server --remote_host=192.168.123.123 --db_service_type='mysql' --master_db='mysql://aegir:123pwd@192.168.123.123'

trrroy’s picture

Title: Unknown option: --master_db » Unknown options for provision-save
FileSize
1.22 KB

I also found some other options related to web packs are missing in 2.x, --master_web_servers and --slave_web_servers. Here's an update to this patch to add those too.

anarcat’s picture

Status: Active » Needs review
anarcat’s picture

Priority: Normal » Critical
Status: Needs review » Needs work

i don't think this is the right way to do this.

+++ b/Provision/Context/server.phpundefined
@@ -68,6 +71,10 @@ class Provision_Context_server extends Provision_Context {
+    $this->setProperty('master_web_servers');
+    $this->setProperty('slave_web_servers');

normally, those parameters are set directly in the service subclass. in #1784108: pack (and cluster?) modules incompatible with SSL i have a similar issue, and i tried to fix this the "right way", but it failed, see commit 7a86f47 in provision.

those parameters should really propagate upwards, and they don't, and that's a bug that's blocking other functionality so i'm marking this as critical.

Steven Jones’s picture

Given the nature of the provision-save command, maybe we should just allow any option to be sent.

We can do this by specifying the 'allow-additional-options' => TRUE in the Drush command definition.

anarcat’s picture

Status: Needs work » Fixed

So I did that, but it seems to me this should be better implemented in the hook_command. I'll open a separate issue about this: #2009408: missing documentation for sub-classes of Provision_Context_*

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

  • Commit 4571874 on dev-drupal-8, 6.x-2.x, dev-ssl-ip-allocation-refactor, 7.x-3.x, dev-subdir-multiserver, 6.x-2.x-backports, dev-helmo-3.x by anarcat:
    Issue #1972286 by darthsteven: don't check arguments on provision-save...