# Remove \`sudo\` from shellscripts

**URL:** <https://forum.commonvisionblox.com/t/remove-sudo-from-shellscripts/1837>\
**Category:** Tools\
**Tags:** linux\
**Created:** [November 24, 2022, 10:37am UTC](https://forum.commonvisionblox.com/t/remove-sudo-from-shellscripts/1837 "2022-11-24T10:37:08Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![KKulikovskis](https://avatars.discourse-cdn.com/v4/letter/k/ba9def/32.png) [@KKulikovskis](https://forum.commonvisionblox.com/u/KKulikovskis)\
**Post date:** [November 24, 2022, 10:37am UTC](https://forum.commonvisionblox.com/t/remove-sudo-from-shellscripts/1837/1 "2022-11-24T10:37:08Z")

</div>

Hi, could you please remove `sudo` from install\_cvb and uninstall\_cvb shell scripts? This creates a huge incovenience when using containerized environment since containers don’t have sudo by default and usually don’t even need it.

Removing sudo before commands and instead using something like:

```auto
if test $? != 0
then
    echo "[ERROR] Please run this file with sudo"
    exit 1
fi

```

Would improve the install file usability in different environments.

Removing sudo within shell script and running the whole script with sudo (i.e. `sudo ./install_cvb.sh`) still gives the script root permissions so everything can be installed properly if sudo is needed

---

<div class="post-metadata">

**Author:** ![illusive](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.commonvisionblox.com/illusive/32/61_2.png) [@illusive](https://forum.commonvisionblox.com/u/illusive)\
**Post date:** [December 2, 2022, 2:38pm UTC](https://forum.commonvisionblox.com/t/remove-sudo-from-shellscripts/1837/2 "2022-12-02T14:38:02Z")

</div>

Thanks @KKulikovskis for sharing this - we will definitely consider that for the next release!
