Skip to content

Commit c0cb6e2

Browse files
authored
Remove egrep usage from scripts (#1767)
1 parent e689894 commit c0cb6e2

File tree

3 files changed

+9
-3
lines changed

3 files changed

+9
-3
lines changed

etc/kayobe/ansible/rabbitmq-reset.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
ansible.builtin.shell:
1313
cmd: >-
1414
set -o pipefail &&
15-
systemctl -a | egrep 'kolla-(barbican|blazar|cinder|cloudkitty|designate|heat|ironic|keystone|magnum|manila|neutron|nova|octavia)' |
15+
systemctl -a | grep -E 'kolla-(barbican|blazar|cinder|cloudkitty|designate|heat|ironic|keystone|magnum|manila|neutron|nova|octavia)' |
1616
awk '{ print $NF }' |
1717
xargs systemctl stop
1818
executable: "/bin/bash"
@@ -87,7 +87,7 @@
8787
cmd: >-
8888
set -o pipefail &&
8989
systemctl list-units --type=service --all --no-legend --plain |
90-
egrep 'kolla-(barbican|blazar|cinder|cloudkitty|designate|heat|ironic|keystone|magnum|manila|neutron|nova|octavia)' |
90+
grep -E 'kolla-(barbican|blazar|cinder|cloudkitty|designate|heat|ironic|keystone|magnum|manila|neutron|nova|octavia)' |
9191
awk '{ print $1 }' |
9292
xargs -r systemctl restart
9393
executable: "/bin/bash"

etc/kayobe/ansible/stop-openstack-services.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@
2929
executable: "/bin/bash"
3030
cmd: >-
3131
set -o pipefail &&
32-
systemctl -a | egrep 'kolla-({{ stop_service_list | join('|') }})' | awk '{ print $1 }' | xargs systemctl stop
32+
systemctl -a | grep -E 'kolla-({{ stop_service_list | join('|') }})' | awk '{ print $1 }' | xargs systemctl stop
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
fixes:
3+
- |
4+
Removed ``egrep`` usage from scripts. Instances have been replaced with
5+
``grep -E``. This resolves the warning ``egrep: warning: egrep is
6+
obsolescent; using grep -E``.

0 commit comments

Comments
 (0)