File tree Expand file tree Collapse file tree 2 files changed +14
-16
lines changed
tests/serverless-plugins-integration Expand file tree Collapse file tree 2 files changed +14
-16
lines changed Original file line number Diff line number Diff line change 1
1
#! /bin/sh
2
2
trap " exit 1" INT
3
3
4
- AWS_ENDPOINT_URL=${AWS_ENDPOINT_URL:- http:// s3: 9000}
5
- AWS_ACCESS_KEY_ID=${AWS_ACCESS_KEY_ID:- local}
6
- AWS_SECRET_ACCESS_KEY=${AWS_SECRET_ACCESS_KEY:- local}
7
- AWS_DEFAULT_REGION=${AWS_DEFAULT_REGION:- eu-west-1}
4
+ AWS_ENDPOINT_URL=${AWS_ENDPOINT_URL:- http:// localhost: 9000}
8
5
9
- echo " here is ${AWS_ACCESS_KEY_ID} "
10
-
11
- aws configure set aws_access_key_id ${AWS_ACCESS_KEY_ID}
12
- aws configure set aws_secret_access_key ${AWS_SECRET_ACCESS_KEY}
13
- aws configure set default.region ${AWS_DEFAULT_REGION}
14
-
15
-
16
- aws --endpoint-url ${AWS_ENDPOINT_URL} s3 mb s3://documents
17
- aws --endpoint-url ${AWS_ENDPOINT_URL} s3 mb s3://pictures
18
- aws --endpoint-url ${AWS_ENDPOINT_URL} s3 mb s3://files
6
+ BUCKETS=" documents pictures files"
7
+ for BUCKET in $BUCKETS
8
+ do
9
+ until aws --endpoint-url ${AWS_ENDPOINT_URL} s3 ls s3://${BUCKET} > /dev/null 2> /dev/null
10
+ do
11
+ echo " Creating bucket $BUCKET "
12
+ aws --endpoint-url ${AWS_ENDPOINT_URL} s3 \
13
+ mb s3://${BUCKET} \
14
+ > /dev/null 2> /dev/null
15
+ done &
16
+ done
19
17
20
18
wait
21
19
22
- trap - INT
20
+ trap - INT
Original file line number Diff line number Diff line change 7
7
"start:sqs" : " sls --config serverless.sqs.yml offline" ,
8
8
"start:s3" : " sls --config serverless.s3.yml offline" ,
9
9
"start:dynamodb-streams" : " sls --config serverless.dynamodb-streams.yml offline" ,
10
- "test" : " npm run test:s3 && npm run test:sqs && npm run test:sqs:autocreate && npm run test:kinesis && npm run test:dynamodb-streams " ,
10
+ "test" : " npm run test:dynamodb-streams && npm run test:kinesis && npm run test:s3 && npm run test:sqs && npm run test:sqs:autocreate " ,
11
11
"setup-service" : " ../../scripts/clean-start.sh" ,
12
12
"pretest:dynamodb-streams" : " npm run -s setup-service dynamodb" ,
13
13
"test:dynamodb-streams" : " node test-dynamodb-streams" ,
You can’t perform that action at this time.
0 commit comments