instead of 'newgrp' and a pipe, use 'sg'
sg and newgrp basically do the same thing, but sg takes a command to execute rather than just executing sh. This just seems cleaner.
This commit is contained in:
parent
b94f4bf35b
commit
8ab1ade42e
1 changed files with 2 additions and 3 deletions
5
stack.sh
5
stack.sh
|
@ -592,9 +592,8 @@ fi
|
||||||
# have to do a little more than that in our script. Since we add the group
|
# have to do a little more than that in our script. Since we add the group
|
||||||
# ``libvirtd`` to our user in this script, when nova-compute is run it is
|
# ``libvirtd`` to our user in this script, when nova-compute is run it is
|
||||||
# within the context of our original shell (so our groups won't be updated).
|
# within the context of our original shell (so our groups won't be updated).
|
||||||
# We can send the command nova-compute to the ``newgrp`` command to execute
|
# Use 'sg' to execute nova-compute as a member of the libvirtd group.
|
||||||
# in a specific context.
|
screen_it n-cpu "cd $NOVA_DIR && sg libvirtd $NOVA_DIR/bin/nova-compute"
|
||||||
screen_it n-cpu "cd $NOVA_DIR && echo $NOVA_DIR/bin/nova-compute | newgrp libvirtd"
|
|
||||||
screen_it n-net "cd $NOVA_DIR && $NOVA_DIR/bin/nova-network"
|
screen_it n-net "cd $NOVA_DIR && $NOVA_DIR/bin/nova-network"
|
||||||
screen_it n-sch "cd $NOVA_DIR && $NOVA_DIR/bin/nova-scheduler"
|
screen_it n-sch "cd $NOVA_DIR && $NOVA_DIR/bin/nova-scheduler"
|
||||||
screen_it n-vnc "cd $NOVNC_DIR && ./utils/nova-wsproxy.py 6080 --web . --flagfile=../nova/bin/nova.conf"
|
screen_it n-vnc "cd $NOVNC_DIR && ./utils/nova-wsproxy.py 6080 --web . --flagfile=../nova/bin/nova.conf"
|
||||||
|
|
Loading…
Reference in a new issue