FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
docker-lambda/base/dump-provided.sh at build-java8 · sdscgithub/docker-lambda · GitHub
sdscgithub
/
docker-lambda
Public
forked from
lambci/docker-lambda
Notifications
You must be signed in to change notification settings
Fork
0
Star
0
Code
Pull requests
0
Actions
Projects
Security and quality
0
Insights
Additional navigation options
Code
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
docker-lambda
/
base
/
dump-provided.sh
Copy path
More file actions
More file actions
Latest commit
History
History
History
executable file
·
38 lines (25 loc) · 889 Bytes
Breadcrumbs
docker-lambda
/
base
/
dump-provided.sh
Copy path
File metadata and controls
executable file
·
38 lines (25 loc) · 889 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
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
#!
/bin/sh
set
-euo pipefail
export
HOME=/tmp
export
PATH=/tmp/.local/bin:
$PATH
cd
/tmp
curl -sSL https://bootstrap.pypa.io/get-pip.py -o get-pip.py
python get-pip.py --user
pip install --user awscli
while
true
do
HEADERS=
"
$(
mktemp
)
"
EVENT_DATA=
$(
curl -v -sS -LD
"
$HEADERS
"
-X GET
"
http://
${AWS_LAMBDA_RUNTIME_API}
/2018-06-01/runtime/invocation/next
"
)
INVOCATION_ID=
$(
grep -Fi Lambda-Runtime-Aws-Request-Id
"
$HEADERS
"
|
tr -d
'
[:space:]
'
|
cut -d: -f2
)
tar -cpzf /tmp/provided.tgz --numeric-owner --ignore-failed-read /var/runtime /var/lang
echo
'
Zipping done! Uploading...
'
aws s3 cp /tmp/provided.tgz s3://lambci/fs/ --acl public-read
echo
'
Uploading done!
'
RESPONSE=
"
$(
env
)
$(
ps aux
)
$(
xargs -n 1 -0
<
/proc/1/environ
)
"
echo
$RESPONSE
curl -v
"
http://
${AWS_LAMBDA_RUNTIME_API}
/2018-06-01/runtime/invocation/
$INVOCATION_ID
/response
"
-d
"
$RESPONSE
"
done
Back
|
FazBrowse Home
|
New Git URL