blob: d434b47351089d19c908e42e7854e793e855f900 [file] [log] [blame]
Nathaniel Manistad4cb0d62015-02-15 01:21:53 +00001# Dockerfile for GRPC Python
2FROM grpc/python_base
3
4# Build the C library
5RUN cd /var/local/git/grpc \
6 && git pull --recurse-submodules \
7 && git submodule update --init --recursive
8
9# Build the C core.
10RUN make install_c -C /var/local/git/grpc
11
12# Build Python GRPC
13RUN cd /var/local/git/grpc \
14 && pip install src/python/src \
15 && pip install src/python/interop
16
17# Run Python GRPC's tests
18RUN cd /var/local/git/grpc \
19 # TODO(nathaniel): It would be nice for these to be auto-discoverable?
Nathaniel Manistac25a3b32015-02-18 02:46:17 +000020 && python2.7 -B -m grpc._adapter._blocking_invocation_inline_service_test
21 && python2.7 -B -m grpc._adapter._c_test
22 && python2.7 -B -m grpc._adapter._event_invocation_synchronous_event_service_test
23 && python2.7 -B -m grpc._adapter._future_invocation_asynchronous_event_service_test
24 && python2.7 -B -m grpc._adapter._links_test
25 && python2.7 -B -m grpc._adapter._lonely_rear_link_test
26 && python2.7 -B -m grpc._adapter._low_test
27 && python2.7 -B -m grpc._framework.base.packets.implementations_test
28 && python2.7 -B -m grpc._framework.face.blocking_invocation_inline_service_test
29 && python2.7 -B -m grpc._framework.face.event_invocation_synchronous_event_service_test
30 && python2.7 -B -m grpc._framework.face.future_invocation_asynchronous_event_service_test
31 && python2.7 -B -m grpc._framework.foundation._later_test
32 && python2.7 -B -m grpc._framework.foundation._logging_pool_test
Nathaniel Manistad4cb0d62015-02-15 01:21:53 +000033
34# Add a cacerts directory containing the Google root pem file, allowing the interop client to access the production test instance
35ADD cacerts cacerts
36
37# Specify the default command such that the interop server runs on its known testing port
38CMD ["/bin/bash", "-l", "-c", "python2.7 -m interop.server --use_tls --port 8050"]