Skip to content

Commit 9c165f4

Browse files
committed
Fixed pip install directory
1 parent 4c1f3f7 commit 9c165f4

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

pip_install.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#!/bin/bash
2-
DIR="/pip/libs/python/lib/python$PYTHON_VERSION/site-packages"
2+
DIR="/libs/python/lib/python$PYTHON_VERSION/site-packages"
33
pip3 install "$@" --target "$DIR"
44
zip -r libraries.zip pip/

run_docker.sh

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
#!/bin/bash
2-
rm -rf "$(dirname "${BASH_SOURCE[0]}")"/build
3-
mkdir "$(dirname "${BASH_SOURCE[0]}")"/build
2+
DIR="$(dirname "${BASH_SOURCE[0]}")"/build
3+
rm -rf "$DIR"
4+
mkdir "$DIR"
45
docker run --name build-lambda-layer "$@" > /dev/null 2>&1
5-
docker cp build-lambda-layer:/libraries.zip "$(dirname "${BASH_SOURCE[0]}")"/build/libraries.zip > /dev/null 2>&1
6+
docker cp build-lambda-layer:/libraries.zip "$DIR"/libraries.zip > /dev/null 2>&1
67
docker rm build-lambda-layer > /dev/null 2>&1
7-
jq -n "{ path: \"$(dirname "${BASH_SOURCE[0]}")/build/libraries.zip\" }"
8+
jq -n "{ path: \"$DIR/libraries.zip\" }"

0 commit comments

Comments
 (0)