Skip to content

Commit d33963d

Browse files
Merge pull request #922 from booxter/ipv6-lab-misc-fixes
Misc fixes for ipv6 lab scripts
2 parents 60827c3 + 1713128 commit d33963d

File tree

4 files changed

+8
-5
lines changed

4 files changed

+8
-5
lines changed

devsetup/scripts/ipv6-nat64/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,8 @@ options:
6060
* nftables - Firewall for IPv4 NAT (Masqurade NAT64 pool behind a single ip
6161
address)
6262

63+
Note: you will have to detach from the VM console by pressing `Ctrl+]`.
64+
6365

6466
sno.sh
6567
------

devsetup/scripts/ipv6-nat64/nat64_router.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
# License for the specific language governing permissions and limitations
1515
# under the License.
1616

17-
set -e
17+
set -ex
1818

1919
if [ "$EUID" -eq 0 ]; then
2020
echo "Please do not run as root."
@@ -321,7 +321,7 @@ function create_nat64_vm {
321321
popd
322322

323323
echo "NAT64 router instance ${NAT64_INSTANCE_NAME} created"
324-
${VIRSH_CMD} start ${NAT64_INSTANCE_NAME}
324+
${VIRSH_CMD} start ${NAT64_INSTANCE_NAME} || true
325325
}
326326

327327
function cleanup_nat64_vm {

devsetup/scripts/ipv6-nat64/network.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
# License for the specific language governing permissions and limitations
1515
# under the License.
1616

17-
set -e
17+
set -ex
1818

1919
if [ "$EUID" -eq 0 ]; then
2020
echo "Please do not run as root."
@@ -259,7 +259,7 @@ function cleanup_firewalld_config {
259259
echo "firewalld.service not active, enable it or disable firewalld managment (MANAGE_FIREWALLD=false)"
260260
exit 1
261261
fi
262-
sudo firewall-cmd --permanent --delete-zone=${NETWORK_NAME}
262+
sudo firewall-cmd --permanent --delete-zone=${NETWORK_NAME} || true
263263
}
264264

265265
function create {

devsetup/scripts/ipv6-nat64/sno.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
# License for the specific language governing permissions and limitations
1515
# under the License.
1616

17-
set -e
17+
set -ex
1818

1919
if [ "$EUID" -eq 0 ]; then
2020
echo "Please do not run as root."
@@ -214,6 +214,7 @@ function destroy_sno_instance {
214214
${VIRSH_CMD} undefine "${SNO_INSTANCE_NAME}" --nvram --remove-all-storage
215215
echo "OCP single-node instance: ${SNO_INSTANCE_NAME} deleted"
216216
fi
217+
sudo virsh vol-delete --pool ${LIBVIRT_STORAGE_POOL} ${BOOTSTRAP_ISO_FILENAME} || true
217218
}
218219

219220
function create_dnsmasq_config {

0 commit comments

Comments
 (0)