Skip to content

Commit 7363a9c

Browse files
authored
Merge pull request #30 from DataDog/tian.chu/rm-botocore
Remove botocore from the published layers
2 parents d12d9cb + 21ed8c3 commit 7363a9c

File tree

4 files changed

+7
-5
lines changed

4 files changed

+7
-5
lines changed

Dockerfile

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,8 @@ COPY . .
1212
RUN pip install . -t ./python/lib/$runtime/site-packages
1313

1414
# Remove *.pyc files
15-
RUN find ./python/lib/$runtime/site-packages -name \*.pyc -delete
15+
RUN find ./python/lib/$runtime/site-packages -name \*.pyc -delete
16+
17+
# Remove botocore (40MB) to reduce package size. aws-xray-sdk
18+
# installs it, while it's already provided by the Lambda Runtime.
19+
RUN rm -rf ./python/lib/$runtime/site-packages/botocore*

setup.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,13 @@
3232
'ddtrace==0.28.0',
3333
'wrapt==1.11.1',
3434
'setuptools==40.8.0',
35-
'boto3==1.9.160'
3635
],
3736
extras_require={
3837
'dev': [
3938
'nose2==0.9.1',
4039
'flake8==3.7.7',
41-
'requests==2.21.0'
40+
'requests==2.21.0',
41+
'boto3==1.9.160',
4242
]
4343
}
4444
)

tests/test_tags.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,4 +43,3 @@ def test_get_runtime_tag(self):
4343

4444
self.mock_python_version_tuple.return_value = ("3", "7", "2")
4545
self.assertEqual(get_runtime_tag(), "runtime:python3.7")
46-

tests/test_wrapper.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -242,4 +242,3 @@ def lambda_handler(event, context):
242242
lambda_handler(lambda_event, get_mock_context())
243243

244244
self.mock_lambda_metric.assert_not_called()
245-

0 commit comments

Comments
 (0)