Skip to content

Conversation

@rimolive
Copy link
Contributor

What changes were proposed in this pull request?

As described in SPARK-23680, entrypoint.sh returns an error code because of a command pipeline execution where it is expected in case of Openshift environments, where arbitrary UIDs are used to run containers

How was this patch tested?

This patch was manually tested by using docker-image-toll.sh script to generate a Spark driver image and running an example against an OpenShift cluster.

Please review http://spark.apache.org/contributing.html before opening a pull request.

@erikerlandson
Copy link
Contributor

@rimolive thanks for this!

@erikerlandson
Copy link
Contributor

jenkins please test this

mygid=$(id -g)
uidentry=$(getent passwd $myuid)

set -e
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it is probably best to limit the "no -e" specifically to getent, such as:

set -ex
myuid=$(id -u)
mygid=$(id -g)
# turn off -e for getent because it will return error code in anonymous uid case
set +e
uidentry=$(getent passwd $myuid)
set -e

Fixes SPARK-23680
@erikerlandson
Copy link
Contributor

LGTM, pending tests

@felixcheung
Copy link
Member

Jenkins, ok to test

@SparkQA
Copy link

SparkQA commented Mar 16, 2018

Test build #88296 has finished for PR 20822 at commit d6f5446.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@erikerlandson
Copy link
Contributor

Merged to master

@asfgit asfgit closed this in 9945b02 Mar 16, 2018
mstewart141 pushed a commit to mstewart141/spark that referenced this pull request Mar 24, 2018
## What changes were proposed in this pull request?

As described in SPARK-23680, entrypoint.sh returns an error code because of a command pipeline execution where it is expected in case of Openshift environments, where arbitrary UIDs are used to run containers

## How was this patch tested?

This patch was manually tested by using docker-image-toll.sh script to generate a Spark driver image and running an example against an OpenShift cluster.

Please review http://spark.apache.org/contributing.html before opening a pull request.

Author: Ricardo Martinelli de Oliveira <[email protected]>

Closes apache#20822 from rimolive/rmartine-spark-23680.
@rimolive rimolive deleted the rmartine-spark-23680 branch October 8, 2019 13:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants