From 43baa8f0cca640afc2934e6e65f51e5465e0ec88 Mon Sep 17 00:00:00 2001 From: Ward Vandewege Date: Wed, 29 Jul 2020 09:58:25 -0400 Subject: [PATCH] 16616: incorporate review comments. Arvados-DCO-1.1-Signed-off-by: Ward Vandewege --- .../install-compute-node.html.textile.liquid | 12 ++++++------ .../install-dispatch-cloud.html.textile.liquid | 2 +- .../install-compute-node.html.textile.liquid | 2 +- lib/dispatchcloud/worker/worker.go | 1 + tools/compute-images/arvados-images-aws.json | 4 ++-- tools/compute-images/arvados-images-azure.json | 4 ++-- tools/compute-images/scripts/base.sh | 4 ++-- ...loud.cfg.d-07_compute_arvados_dispatch_cloud.cfg} | 0 8 files changed, 15 insertions(+), 14 deletions(-) rename tools/compute-images/scripts/{etc-cloud-cloud.cfg.d-07_compute_puppetless_arvados_dispatch_cloud.cfg => etc-cloud-cloud.cfg.d-07_compute_arvados_dispatch_cloud.cfg} (100%) diff --git a/doc/install/crunch2-cloud/install-compute-node.html.textile.liquid b/doc/install/crunch2-cloud/install-compute-node.html.textile.liquid index 4659ccb1e0..23da428b39 100644 --- a/doc/install/crunch2-cloud/install-compute-node.html.textile.liquid +++ b/doc/install/crunch2-cloud/install-compute-node.html.textile.liquid @@ -10,7 +10,7 @@ SPDX-License-Identifier: CC-BY-SA-3.0 {% endcomment %} {% include 'notebox_begin_warning' %} -arvados-dispatch-cloud is only relevant for cloud installations. Skip this section if you are installing a on premises cluster that will spool jobs to Slurm. +arvados-dispatch-cloud is only relevant for cloud installations. Skip this section if you are installing an on premises cluster that will spool jobs to Slurm. {% include 'notebox_end' %} # "Introduction":#introduction @@ -21,7 +21,7 @@ arvados-dispatch-cloud is only relevant for cloud installations. Skip this secti h2(#introduction). Introduction -This page describes how to build a compute node image that it can be used to run containers dispatched by Arvados in the cloud. +This page describes how to build a compute node image that can be used to run containers dispatched by Arvados in the cloud. Packer templates for AWS and Azure are provided with Arvados. To use them, the following are needed: @@ -30,11 +30,11 @@ Packer templates for AWS and Azure are provided with Arvados. To use them, the f * configuration details for your cloud account -h2(#sshkeypair). Create an SSH keypair +h2(#sshkeypair). Create a SSH keypair -@arvados-dispatch-cloud@ communicates with the compute nodes via SSH. To do this securely, an SSH keypair is needed. +@arvados-dispatch-cloud@ communicates with the compute nodes via SSH. To do this securely, a SSH keypair is needed. -Generate an SSH keypair with no passphrase. The private key needs to be stored in the cluster configuration file (see @Containers/DispatchPrivateKey@) for use by @arvados-dispatch-cloud@, as described in the "next section":install-dispatch-cloud.html#update-config. The public key will be baked into the compute node images, see the cloud-specific documentation below. +Generate a SSH keypair with no passphrase. The private key needs to be stored in the cluster configuration file (see @Containers/DispatchPrivateKey@) for use by @arvados-dispatch-cloud@, as described in the "next section":install-dispatch-cloud.html#update-config. The public key will be baked into the compute node images, see the cloud-specific documentation below.
~$ ssh-keygen -N '' -f ~/.ssh/id_dispatcher
@@ -170,7 +170,7 @@ h2(#aws). Build an AWS image
 
 For @ClusterID@, fill in your cluster ID. The @VPC@ and @Subnet@ should be configured for where you want the compute image to be generated and stored. The @AMI@ is the identifier for the base image to be used. Current AMIs are maintained by "Debian":https://wiki.debian.org/Cloud/AmazonEC2Image/Buster and "Ubuntu":https://cloud-images.ubuntu.com/locator/ec2/.
 
-@AWSProfile@ should be replaced name of an AWS profile with sufficient permissions to create the image.
+@AWSProfile@ should be replaced with the name of an AWS profile with sufficient permissions to create the image.
 
 @ArvadosDispatchCloudPublicKeyPath@ should be replaced with the path to the ssh *public* key file generated in "Create an SSH keypair":#sshkeypair, above.
 
diff --git a/doc/install/crunch2-cloud/install-dispatch-cloud.html.textile.liquid b/doc/install/crunch2-cloud/install-dispatch-cloud.html.textile.liquid
index 3d6352ccb7..c858f32032 100644
--- a/doc/install/crunch2-cloud/install-dispatch-cloud.html.textile.liquid
+++ b/doc/install/crunch2-cloud/install-dispatch-cloud.html.textile.liquid
@@ -10,7 +10,7 @@ SPDX-License-Identifier: CC-BY-SA-3.0
 {% endcomment %}
 
 {% include 'notebox_begin_warning' %}
-arvados-dispatch-cloud is only relevant for cloud installations. Skip this section if you are installing a on premises cluster that will spool jobs to Slurm.
+arvados-dispatch-cloud is only relevant for cloud installations. Skip this section if you are installing an on premises cluster that will spool jobs to Slurm.
 {% include 'notebox_end' %}
 
 # "Introduction":#introduction
diff --git a/doc/install/crunch2-slurm/install-compute-node.html.textile.liquid b/doc/install/crunch2-slurm/install-compute-node.html.textile.liquid
index f25d1f0a39..8c01c44ed3 100644
--- a/doc/install/crunch2-slurm/install-compute-node.html.textile.liquid
+++ b/doc/install/crunch2-slurm/install-compute-node.html.textile.liquid
@@ -24,7 +24,7 @@ crunch-dispatch-slurm is only relevant for on premises clusters that will spool
 
 h2(#introduction). Introduction
 
-This page describes how to configure a compute node so that it can be used to run containers dispatched by Arvados, with Slurm on a static cluster. These steps must be duplicated on every compute node.
+This page describes how to configure a compute node so that it can be used to run containers dispatched by Arvados, with Slurm on a static cluster. These steps must be performed on every compute node.
 
 h2(#docker). Set up Docker
 
diff --git a/lib/dispatchcloud/worker/worker.go b/lib/dispatchcloud/worker/worker.go
index 357ac20a03..9e8cf51ee6 100644
--- a/lib/dispatchcloud/worker/worker.go
+++ b/lib/dispatchcloud/worker/worker.go
@@ -224,6 +224,7 @@ func (wkr *worker) probeAndUpdate() {
 	defer wkr.mtx.Unlock()
 	if reportedBroken && wkr.idleBehavior == IdleBehaviorRun {
 		logger.Info("probe reported broken instance")
+    // FIXME add prometheus tick
 		wkr.setIdleBehavior(IdleBehaviorDrain)
 	}
 	if !ok || (!booted && len(ctrUUIDs) == 0 && len(wkr.running) == 0) {
diff --git a/tools/compute-images/arvados-images-aws.json b/tools/compute-images/arvados-images-aws.json
index 4832208e41..b83207bd28 100644
--- a/tools/compute-images/arvados-images-aws.json
+++ b/tools/compute-images/arvados-images-aws.json
@@ -61,8 +61,8 @@
     "destination": "/tmp/1078ECD7.asc"
   },{
     "type": "file",
-    "source": "scripts/etc-cloud-cloud.cfg.d-07_compute_puppetless_arvados_dispatch_cloud.cfg",
-    "destination": "/tmp/etc-cloud-cloud.cfg.d-07_compute_puppetless_arvados_dispatch_cloud.cfg"
+    "source": "scripts/etc-cloud-cloud.cfg.d-07_compute_arvados_dispatch_cloud.cfg",
+    "destination": "/tmp/etc-cloud-cloud.cfg.d-07_compute_arvados_dispatch_cloud.cfg"
   },{
     "type": "file",
     "source": "scripts/usr-local-bin-ensure-encrypted-partitions.sh",
diff --git a/tools/compute-images/arvados-images-azure.json b/tools/compute-images/arvados-images-azure.json
index 3a80f9c12c..f7fc1a07b4 100644
--- a/tools/compute-images/arvados-images-azure.json
+++ b/tools/compute-images/arvados-images-azure.json
@@ -56,8 +56,8 @@
     "destination": "/tmp/1078ECD7.asc"
   },{
     "type": "file",
-    "source": "scripts/etc-cloud-cloud.cfg.d-07_compute_puppetless_arvados_dispatch_cloud.cfg",
-    "destination": "/tmp/etc-cloud-cloud.cfg.d-07_compute_puppetless_arvados_dispatch_cloud.cfg"
+    "source": "scripts/etc-cloud-cloud.cfg.d-07_compute_arvados_dispatch_cloud.cfg",
+    "destination": "/tmp/etc-cloud-cloud.cfg.d-07_compute_arvados_dispatch_cloud.cfg"
   },{
     "type": "file",
     "source": "scripts/usr-local-bin-ensure-encrypted-partitions.sh",
diff --git a/tools/compute-images/scripts/base.sh b/tools/compute-images/scripts/base.sh
index 4b134b9dbe..73c7b9dac0 100644
--- a/tools/compute-images/scripts/base.sh
+++ b/tools/compute-images/scripts/base.sh
@@ -106,5 +106,5 @@ $SUDO sed -i "s/#prepend domain-name-servers 127.0.0.1;/prepend domain-name-serv
 $SUDO mv /tmp/usr-local-bin-ensure-encrypted-partitions.sh /usr/local/bin/ensure-encrypted-partitions.sh
 $SUDO chmod 755 /usr/local/bin/ensure-encrypted-partitions.sh
 $SUDO chown root:root /usr/local/bin/ensure-encrypted-partitions.sh
-$SUDO mv /tmp/etc-cloud-cloud.cfg.d-07_compute_puppetless_arvados_dispatch_cloud.cfg /etc/cloud/cloud.cfg.d/07_compute_puppetless_arvados_dispatch_cloud.cfg
-$SUDO chown root:root /etc/cloud/cloud.cfg.d/07_compute_puppetless_arvados_dispatch_cloud.cfg
+$SUDO mv /tmp/etc-cloud-cloud.cfg.d-07_compute_arvados_dispatch_cloud.cfg /etc/cloud/cloud.cfg.d/07_compute_arvados_dispatch_cloud.cfg
+$SUDO chown root:root /etc/cloud/cloud.cfg.d/07_compute_arvados_dispatch_cloud.cfg
diff --git a/tools/compute-images/scripts/etc-cloud-cloud.cfg.d-07_compute_puppetless_arvados_dispatch_cloud.cfg b/tools/compute-images/scripts/etc-cloud-cloud.cfg.d-07_compute_arvados_dispatch_cloud.cfg
similarity index 100%
rename from tools/compute-images/scripts/etc-cloud-cloud.cfg.d-07_compute_puppetless_arvados_dispatch_cloud.cfg
rename to tools/compute-images/scripts/etc-cloud-cloud.cfg.d-07_compute_arvados_dispatch_cloud.cfg
-- 
2.30.2