Skip to content

Fix work with environment variables at xvfb-run (2nd time) #459

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Apr 21, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion NodeChromeDebug/entry_point.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ rm -f /tmp/.X*lock
env | cut -f 1 -d "=" | sort > asroot
sudo -E -u seluser -i env | cut -f 1 -d "=" | sort > asseluser
sudo -E -i -u seluser \
$(for E in $(grep -vxFf asseluser asroot); do echo $E=$(eval echo \$$E); done) \
"$(for E in $(grep -vxFf asseluser asroot); do echo $E=$(eval echo \$$E); done)" \
DISPLAY=$DISPLAY \
xvfb-run -n $SERVERNUM --server-args="-screen 0 $GEOMETRY -ac +extension RANDR" \
java ${JAVA_OPTS} -jar /opt/selenium/selenium-server-standalone.jar \
Expand Down
2 changes: 1 addition & 1 deletion NodeFirefoxDebug/entry_point.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ rm -f /tmp/.X*lock
env | cut -f 1 -d "=" | sort > asroot
sudo -E -u seluser -i env | cut -f 1 -d "=" | sort > asseluser
sudo -E -i -u seluser \
$(for E in $(grep -vxFf asseluser asroot); do echo $E=$(eval echo \$$E); done) \
"$(for E in $(grep -vxFf asseluser asroot); do echo $E=$(eval echo \$$E); done)" \
DISPLAY=$DISPLAY \
xvfb-run -n $SERVERNUM --server-args="-screen 0 $GEOMETRY -ac +extension RANDR" \
java ${JAVA_OPTS} -jar /opt/selenium/selenium-server-standalone.jar \
Expand Down
2 changes: 1 addition & 1 deletion StandaloneDebug/entry_point.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ sudo -E -u seluser -i env | cut -f 1 -d "=" | sort > asseluser

# Add root environment variables that are not present in the seluser
# environment to an environment file.
$(for E in $(grep -vxFf asseluser asroot); do echo $E="'${!E}'" >> ~seluser/selenv; done) \
"$(for E in $(grep -vxFf asseluser asroot); do echo $E="'${!E}'" >> ~seluser/selenv; done)" \
echo "DISPLAY=${DISPLAY}" >> ~seluser/selenv

sudo -E -i -u seluser \
Expand Down
2 changes: 1 addition & 1 deletion sa-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ function test_standalone {
exit 1
fi

if [ ! "$CIRCLECI" == "true" ]; then
if [ ! "${TRAVIS}" == "true" ]; then
echo Tearing down Selenium standalone-$BROWSER$DEBUG container
docker stop $SA_NAME
docker rm $SA_NAME
Expand Down
4 changes: 2 additions & 2 deletions test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ function test_node {
exit 1
fi

if [ ! "$CIRCLECI" == "true" ]; then
if [ ! "${TRAVIS}" == "true" ]; then
echo Removing the test container
docker rm $TEST_CONTAINER
fi
Expand All @@ -72,7 +72,7 @@ if [ -z $DEBUG ]; then
test_node phantomjs $DEBUG
fi

if [ ! "$CIRCLECI" == "true" ]; then
if [ ! "${TRAVIS}" == "true" ]; then
echo Tearing down Selenium Chrome Node container
docker stop $NODE_CHROME
docker rm $NODE_CHROME
Expand Down