This repository has been archived by the owner on Oct 24, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Check names for invalid characters and lengths
closes #46
- Loading branch information
Showing
4 changed files
with
101 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#! /bin/bash -w | ||
|
||
ctrlc() | ||
{ | ||
echo " Exiting..." | ||
rm ~/.aws/credentials | ||
exit 1 | ||
} | ||
set -e | ||
|
||
if [[ "`which serverless`" == "" ]] | ||
then | ||
echo "Hrm, serverless is not installed. " | ||
echo "See https://serverless.com/framework/docs/providers/aws/guide/installation/" | ||
return | ||
fi | ||
if [[ ! -e ~/.aws/credentials ]] | ||
then | ||
trap ctrlc SIGINT | ||
echo " credential file was not found. Let's make one." | ||
echo "" | ||
echo " If you haven't already, you'll need to create an access key." | ||
echo " e.g. go to https://console.aws.amazon.com/iam/home#/users/${USER}/?security_credientials" | ||
echo " and click [Create access key]." | ||
echo "" | ||
read -p "Access Key ID: " access_key | ||
read -p "Secret Key ID: " secret_key | ||
echo " Thanks! Running configuration"; | ||
echo serverless config credentials --provider aws --key $access_key --secret $secret_key | ||
serverless config credentials --provider aws --key $access_key --secret $secret_key | ||
fi | ||
echo " You're configured. The next step is to deploy." | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters