From 623bd0b69f9ad3fe3889acc463955630946275d2 Mon Sep 17 00:00:00 2001 From: Peter Amstutz Date: Sun, 26 Jun 2022 19:03:54 -0400 Subject: [PATCH] 18870: Updating params.local Arvados-DCO-1.1-Signed-off-by: Peter Amstutz --- tools/salt-install/installer.sh | 24 +++++++++++-------- .../local.params.example.multiple_hosts | 17 +++++++++++++ ...ams.example.single_host_multiple_hostnames | 12 ++++++++++ ...params.example.single_host_single_hostname | 12 ++++++++++ 4 files changed, 55 insertions(+), 10 deletions(-) diff --git a/tools/salt-install/installer.sh b/tools/salt-install/installer.sh index 7bd789f689..d9666cbc04 100755 --- a/tools/salt-install/installer.sh +++ b/tools/salt-install/installer.sh @@ -67,17 +67,21 @@ case "$subcmd" in git commit -m"prepare for deploy" for NODE in "${!NODES[@]}" do - if ! ssh $NODE test -d arvados-setup.git ; then - ssh $NODE git init --bare arvados-setup.git - git add remote $NODE $DEPLOY_USER@$NODE:arvados-setup.git - git push $NODE - ssh $NODE git clone arvados-setup.git arvados-setup + if test $NODE = localhost ; then + sudo ./provision.sh --config local.params --roles ${NODES[$NODE]} + else + if ! ssh $NODE test -d arvados-setup.git ; then + ssh $NODE git init --bare arvados-setup.git + git add remote $NODE $DEPLOY_USER@$NODE:arvados-setup.git + git push $NODE + ssh $NODE git clone arvados-setup.git arvados-setup + fi + + git push $NODE master + ssh $NODE git -C arvados-setup pull + + ssh $DEPLOY_USER@$NODE "cd arvados-setup && sudo ./provision.sh --config local.params --roles ${NODES[$NODE]}" fi - - git push $NODE master - ssh $NODE git -C arvados-setup pull - - ssh $DEPLOY_USER@$NODE "cd arvados-setup && sudo ./provision.sh --config local.params --roles ${NODES[$NODE]}" done ;; *) diff --git a/tools/salt-install/local.params.example.multiple_hosts b/tools/salt-install/local.params.example.multiple_hosts index 31a69e9840..404d8b005b 100644 --- a/tools/salt-install/local.params.example.multiple_hosts +++ b/tools/salt-install/local.params.example.multiple_hosts @@ -11,6 +11,23 @@ CLUSTER="cluster_fixme_or_this_wont_work" # The domainname you want tou give to your cluster's hosts DOMAIN="domain_fixme_or_this_wont_work" +# For multi-node installs, the ssh log in for each node +# must be root or able to sudo +DEPLOY_USER=root + +# The mapping of nodes to roles +# installer.sh will log in to each of these nodes and then provision +# it for the specified roles. +declare -A NODES +NODES=( + [controller.$DOMAIN]=api,controller,websocket,dispatcher,keepbalance + [keep0.$DOMAIN]=keepstore + [keep1.$DOMAIN]=keepstore + [keep.$DOMAIN]=keepproxy,keepweb + [workbench.$DOMAIN]=workbench,workbench2,webshell + [shell.$DOMAIN]=shell +) + # Host SSL port where you want to point your browser to access Arvados # Defaults to 443 for regular runs, and to 8443 when called in Vagrant. # You can point it to another port if desired diff --git a/tools/salt-install/local.params.example.single_host_multiple_hostnames b/tools/salt-install/local.params.example.single_host_multiple_hostnames index 2ce1556511..f6b6526129 100644 --- a/tools/salt-install/local.params.example.single_host_multiple_hostnames +++ b/tools/salt-install/local.params.example.single_host_multiple_hostnames @@ -11,6 +11,18 @@ CLUSTER="cluster_fixme_or_this_wont_work" # The domainname you want tou give to your cluster's hosts DOMAIN="domain_fixme_or_this_wont_work" +# For multi-node installs, the ssh log in for each node +# must be root or able to sudo +DEPLOY_USER=root + +# The mapping of nodes to roles +# installer.sh will log in to each of these nodes and then provision +# it for the specified roles. +declare -A NODES +NODES=( + [localhost]=api,controller,websocket,dispatcher,keepbalance,keepstore,keepproxy,keepweb,workbench,workbench2,webshell +) + # External ports used by the Arvados services CONTROLLER_EXT_SSL_PORT=443 KEEP_EXT_SSL_PORT=25101 diff --git a/tools/salt-install/local.params.example.single_host_single_hostname b/tools/salt-install/local.params.example.single_host_single_hostname index 7add9868d9..58847e3c5e 100644 --- a/tools/salt-install/local.params.example.single_host_single_hostname +++ b/tools/salt-install/local.params.example.single_host_single_hostname @@ -11,6 +11,18 @@ CLUSTER="cluster_fixme_or_this_wont_work" # The domainname for your cluster's hosts DOMAIN="domain_fixme_or_this_wont_work" +# For multi-node installs, the ssh log in for each node +# must be root or able to sudo +DEPLOY_USER=root + +# The mapping of nodes to roles +# installer.sh will log in to each of these nodes and then provision +# it for the specified roles. +declare -A NODES +NODES=( + [localhost]=api,controller,websocket,dispatcher,keepbalance,keepstore,keepproxy,keepweb,workbench,workbench2,webshell +) + # Set this value when installing a cluster in a single host with a single # hostname to access all the instances. HOSTNAME_EXT should be set to the # external hostname for the instance. -- 2.30.2