diff --git a/sdks/python/container/Dockerfile b/sdks/python/container/Dockerfile index 9cb65a4631e7..ee59316eae1f 100644 --- a/sdks/python/container/Dockerfile +++ b/sdks/python/container/Dockerfile @@ -80,11 +80,9 @@ RUN \ # Check that the fast implementation of protobuf is used. python -c "from google.protobuf.internal import api_implementation; assert api_implementation._default_implementation_type == 'cpp'; print 'Verified fast protobuf used.'" -ADD target/apache-beam.tar.gz /opt/apache/beam/tars/ - -RUN \ - cd /opt/apache/beam/tars/* && \ - python setup.py install +COPY target/apache-beam.tar.gz /opt/apache/beam/tars/ +RUN pip install /opt/apache/beam/tars/apache-beam.tar.gz[gcp] && \ + rm /opt/apache/beam/tars/apache-beam.tar.gz ADD target/linux_amd64/boot /opt/apache/beam/ diff --git a/sdks/python/container/boot.go b/sdks/python/container/boot.go index 69f031b76311..7cf5ee88aca5 100644 --- a/sdks/python/container/boot.go +++ b/sdks/python/container/boot.go @@ -92,16 +92,16 @@ func main() { dir := filepath.Join(*semiPersistDir, "staged") - files, err := artifact.Materialize(ctx, *artifactEndpoint, dir) + _, err = artifact.Materialize(ctx, *artifactEndpoint, dir) if err != nil { log.Fatalf("Failed to retrieve staged files: %v", err) } // TODO(herohde): the packages to install should be specified explicitly. It // would also be possible to install the SDK in the Dockerfile. - if setupErr := installSetupPackages(files, dir); setupErr != nil { - log.Fatalf("Failed to install SDK: %v", setupErr) - } + // if setupErr := installSetupPackages(files, dir); setupErr != nil { + // log.Fatalf("Failed to install SDK: %v", setupErr) + // } // (3) Invoke python diff --git a/sdks/python/container/build.gradle b/sdks/python/container/build.gradle index 0e870d76bea7..49f84f2e2285 100644 --- a/sdks/python/container/build.gradle +++ b/sdks/python/container/build.gradle @@ -44,8 +44,7 @@ dependencies { task copyDockerfileDependencies(type: Copy) { from configurations.dockerDependency - // rename "apache-beam.*\\.tar.gz", "apache-beam.tar.gz" - rename "apache-beam-2.5.0.dev0.tar.gz", "apache-beam.tar.gz" + rename "apache-beam.*\\.tar.gz", "apache-beam.tar.gz" into "build/target" }