jclouds-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aled Sage <notificati...@github.com>
Subject [jclouds] UserAdd: guard groupadd with check if group exists (#868)
Date Thu, 22 Oct 2015 23:06:52 GMT
On SUSE, the “-f” force option is not available for groupadd,
so `groupadd -f wheel` returns exit code 9 if the group already
exists. To avoid this, first check if the group exists.

In normal usage, this doesn’t matter: the script continues with the
next command anyway.

However, if the statements generated by UserAdd or AdminAccess are
used outside of that context (e.g. by code external to jclouds), then
this can cause them to fail.
You can view, comment on, or merge this pull request online at:

  https://github.com/jclouds/jclouds/pull/868

-- Commit Summary --

  * UserAdd: guard groupadd with check if group exists

-- File Changes --

    M compute/src/test/resources/initscript_with_java.sh (2)
    M compute/src/test/resources/initscript_with_jetty.sh (2)
    M compute/src/test/resources/runscript_adminUpdate.sh (2)
    M scriptbuilder/src/main/java/org/jclouds/scriptbuilder/statements/login/UserAdd.java
(2)
    M scriptbuilder/src/test/java/org/jclouds/scriptbuilder/statements/login/UserAddTest.java
(6)
    M scriptbuilder/src/test/resources/test_adminaccess_flipped.sh (2)
    M scriptbuilder/src/test/resources/test_adminaccess_params.sh (2)
    M scriptbuilder/src/test/resources/test_adminaccess_params_and_fullname.sh (2)
    M scriptbuilder/src/test/resources/test_adminaccess_standard.sh (2)

-- Patch Links --

https://github.com/jclouds/jclouds/pull/868.patch
https://github.com/jclouds/jclouds/pull/868.diff

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/868

Mime
View raw message