Skip to content

Instantly share code, notes, and snippets.

@jdickey
Last active January 17, 2018 02:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jdickey/c9a4f6166bcf1b91ad2b02b815d54a47 to your computer and use it in GitHub Desktop.
Save jdickey/c9a4f6166bcf1b91ad2b02b815d54a47 to your computer and use it in GitHub Desktop.
Running script functions pushed in Commit 7d40a28
➜ deploy git:(dockerising) ✗ export OTHER_PB_ARGS=--step
➜ deploy git:(dockerising) ✗ source droplet_functions.sh
➜ deploy git:(dockerising) ✗ new_droplet
[WARNING]: Host file not found: /etc/ansible/hosts
[WARNING]: provided hosts list is empty, only localhost is available
PLAY [Initialise a new DigitalOcean Droplet as a Docker app host] ****************************************************************************************************************************************************************************
Perform task: TASK: Gathering Facts (N)o/(y)es/(c)ontinue: y
Perform task: TASK: Gathering Facts (N)o/(y)es/(c)ontinue: ***********************************************************************************************************************************************************************************
TASK [Gathering Facts] ***********************************************************************************************************************************************************************************************************************
ok: [localhost]
Perform task: TASK: Deploy new Droplet (N)o/(y)es/(c)ontinue: y
Perform task: TASK: Deploy new Droplet (N)o/(y)es/(c)ontinue: ********************************************************************************************************************************************************************************
TASK [Deploy new Droplet] ********************************************************************************************************************************************************************************************************************
changed: [localhost]
Perform task: TASK: Create in_process tag if not already created (N)o/(y)es/(c)ontinue: y
Perform task: TASK: Create in_process tag if not already created (N)o/(y)es/(c)ontinue: ******************************************************************************************************************************************************
TASK [Create in_process tag if not already created] ******************************************************************************************************************************************************************************************
changed: [localhost -> 127.0.0.1]
Perform task: TASK: Tag new droplet as in_process (N)o/(y)es/(c)ontinue: y
Perform task: TASK: Tag new droplet as in_process (N)o/(y)es/(c)ontinue: *********************************************************************************************************************************************************************
TASK [Tag new droplet as in_process] *********************************************************************************************************************************************************************************************************
changed: [localhost -> 127.0.0.1]
Perform task: TASK: Remove IP address from local known_hosts file if it exists (N)o/(y)es/(c)ontinue: y
Perform task: TASK: Remove IP address from local known_hosts file if it exists (N)o/(y)es/(c)ontinue: ****************************************************************************************************************************************
TASK [Remove IP address from local known_hosts file if it exists] ****************************************************************************************************************************************************************************
ok: [localhost]
PLAY RECAP ***********************************************************************************************************************************************************************************************************************************
localhost : ok=5 changed=3 unreachable=0 failed=0
➜ deploy git:(dockerising) ✗ provision_droplet
PLAY [Finalise user and firewall setup on a new Droplet] *************************************************************************************************************************************************************************************
Perform task: TASK: Gathering Facts (N)o/(y)es/(c)ontinue: y
Perform task: TASK: Gathering Facts (N)o/(y)es/(c)ontinue: ***********************************************************************************************************************************************************************************
TASK [Gathering Facts] ***********************************************************************************************************************************************************************************************************************
fatal: [188.166.250.23]: FAILED! => {"changed": false, "failed": true, "module_stderr": "Shared connection to 188.166.250.23 closed.\r\n", "module_stdout": "/bin/sh: 1: /usr/bin/python: not found\r\n", "msg": "MODULE FAILURE", "rc": 0}
to retry, use: --limit @/Users/jeffdickey/src/ruby/conversagence/deploy/provision_droplet.retry
PLAY RECAP ***********************************************************************************************************************************************************************************************************************************
188.166.250.23 : ok=0 changed=0 unreachable=0 failed=1
➜ deploy git:(dockerising) ✗
@jdickey
Copy link
Author

jdickey commented Jan 17, 2018

The provision_droplet (which invokes the provision_droplet.yml Playbook) tries to

  • Verify that the normal user exists on the Droplet
  • Verify that the user's .authorized_keys file exists and is correct
  • Verify that the normal user has been added to docker and sudo groups
  • ...

It bombs when it tries to establish a connection to the remote host, because root login is locked out. That wasn't the case 10 hours ago as I type this; this script hadn't been touched for several iterations (through previous repos) because it (heretofore) worked.

I'm deeply confused.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment