Changeset 38594 for gs3-extensions


Ignore:
Timestamp:
2024-01-22T14:15:10+13:00 (5 months ago)
Author:
davidb
Message:

Next round of changes to streamline things further

Location:
gs3-extensions/selfcontained-gcloud/trunk/spin-up-gce-vm
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • gs3-extensions/selfcontained-gcloud/trunk/spin-up-gce-vm/create-vm-with-static-ip-example.sh

    r38591 r38594  
    11#!/bin/bash
    22
    3 # Edit the following to the name of the VM you want to create
    4 export GSVM_INSTANCE=greenstone3-debian-ansible-test
     3. ./_local_config.bash
    54
    6 gsvm_instance_disk=$GSVM_INSTANCE-disk
    7 gsvm_instance_nic=$GSVM_INSTANCE-nic
    8 
    9 gsvm_project=atea-storage
    10 gsvm_subproject=bluff
    11 gsvm_region=australia-southeast1
    12 gsvm_zone=australia-southeast1-b
    13 
    14 if [ ! -f $gsvm_project--$gsvm_subproject ] ; then
     5if [ ! -f $gsvm_project--$gsvm_subproj ] ; then
    156    echo ""
    167    echo "----"
    178    echo "- Generating RSA key-pair for ssh access"
    189    echo "- [Press enter twice to set with an empty passphrase]"
    19     ssh-keygen -t rsa -f $gsvm_project--$gsvm_subproject -C $gsvm_project--$gsvm_subproject
     10    ssh-keygen -t rsa -f $gsvm_project--$gsvm_subproj -C $gsvm_project--$gsvm_subproj
    2011    echo "----"
    2112    echo ""
     
    2516#ssh_rsa_pubkey=$(cat $gsvm_project--$gsvm_subproject.pub | sed 's/ [a-z-]\+$//i')
    2617
    27 ssh_rsa_pubkey=$(cat $gsvm_project--$gsvm_subproject.pub | awk '{ print $2 }')
     18ssh_rsa_pubkey=$(cat $gsvm_project--$gsvm_subproj.pub | awk '{ print $2 }')
    2819#ssh_rsa_esc_pubkey=$(echo $ssh_rsa_pubkey | sed 's/+/\\+/g')
    2920
     
    4031echo " than the default 10GB]"
    4132
     33#--metadata="^%^ssh-keys=ateaspace:ssh-rsa $ssh_rsa_pubkey google-ssh {\"userName\":\"[email protected]\",\"expireOn\":\"2024-02-21T02:40:49+0000\"}" \
     34     
    4235         
    4336gcloud compute instances create $GSVM_INSTANCE \
     
    4639    --machine-type=e2-medium \
    4740    --network-interface=network-tier=STANDARD,stack-type=IPV4_ONLY,subnet=default,no-address \
    48     --metadata="^%^ssh-keys=ateaspace:ssh-rsa $ssh_rsa_pubkey google-ssh {\"userName\":\"ateaspace@gmail.com\",\"expireOn\":\"2024-02-21T02:40:49+0000\"}" \
     41    --metadata="^%^ssh-keys=$GSVM_USER:ssh-rsa $ssh_rsa_pubkey ssh-$gsvm_project--$gsvm_subproj {\"userName\":\"$GSVM_USER@gmail.com\",\"expireOn\":\"2024-02-21T02:40:49+0000\"}" \
    4942    --maintenance-policy=MIGRATE \
    5043    --provisioning-model=STANDARD \
  • gs3-extensions/selfcontained-gcloud/trunk/spin-up-gce-vm/ssh-login.sh

    r38591 r38594  
    1 ssh -i atea-storage--bluff [email protected]
     1#!/bin/bash
     2
     3. ./_local_config.bash
     4
     5#ssh -i atea-storage--bluff [email protected]
     6
     7ssh -i $gsvm_project--$gsvm_subproj [email protected]
Note: See TracChangeset for help on using the changeset viewer.