-
Notifications
You must be signed in to change notification settings - Fork 0
/
Taskfile.yml
68 lines (63 loc) · 1.8 KB
/
Taskfile.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
#https://www.cdata.com/kb/tech/salesforce-jdbc-aws-glue.rst
version: "3"
dotenv: ['.env']
includes:
tf:
taskfile: ./cmd/Taskfile-terraform.yml
dotenv: ['.env']
tasks:
env:add:
desc: "Add environment"
silent: true
dir: ./
cmds:
- |
echo "Type the project name:"
read PROJECT;
echo "PROJECT=$PROJECT" > .env
echo "Type the environment name:"
read ENV;
echo "ENV=$ENV" >> .env
echo "Type the AWS_ACCESS_KEY_ID:"
read AWS_ACCESS_KEY_ID;
echo "AWS_ACCESS_KEY_ID=$AWS_ACCESS_KEY_ID"
echo "Type the AWS_SECRET_ACCESS_KEY:"
read AWS_SECRET_ACCESS_KEY;
echo "AWS_SECRET_ACCESS_KEY=$AWS_SECRET_ACCESS_KEY"
# aws-vault add $PROJECT-$ENV --env
env:set:
desc: Set environment
cmds:
- |
echo "Type the Project name:"
read PROJECT;
echo "PROJECT=$PROJECT" >> .env
echo "Type the environment name:"
read ENV;
echo "ENV=$ENV" > .env
echo "Type the region name:"
read REGION;
echo "REGION=$REGION" >> .env
unset AWS_VAULT
aws-vault exec $PROJECT-$ENV --region $REGION --no-session
silent: true
env:install:
desc: Download and install tools
cmds:
- |
echo "install terraform? [yes/no]:"
read TERRAFORM;
echo "TERRAFORM=$TERRAFORM" > .temp
echo "install tfenv? [yes/no]:"
read TF_ENV;
echo "TF_ENV=$TF_ENV" >> .temp
echo "install kubectl?: [yes/no]"
read KUBECTL;
echo "KUBECTL=$KUBECTL" >> .temp
echo "install aws-cli?: [yes/no]"
read AWS_CLI;
echo "AWS_CLI=$AWS_CLI" >> .temp
echo "install aws-vault?: [yes/no]"
read AWS_VAULT;
echo "AWS_VAULT=AWS_VAULT" >> .temp
silent: true