From dea47c92c1c2b571fc95ceed01944b411e2409f2 Mon Sep 17 00:00:00 2001 From: Rahul Desai Date: Wed, 3 Jul 2024 22:36:55 -0700 Subject: [PATCH] add iptables configuration to AMI --- sysbox-eks.pkr.hcl | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/sysbox-eks.pkr.hcl b/sysbox-eks.pkr.hcl index 53449c1..9a131a4 100644 --- a/sysbox-eks.pkr.hcl +++ b/sysbox-eks.pkr.hcl @@ -416,4 +416,15 @@ build { "sudo dasel put string --parser toml --selector 'nvidia-container-runtime.runtimes.[]' --file /etc/nvidia-container-runtime/config.toml 'runc'" ] } + + provisioner "shell" { + inline_shebang = "/usr/bin/env bash" + inline = [ + "sudo iptables -P INPUT ACCEPT", + "sudo iptables -P FORWARD ACCEPT", + "sudo iptables -P OUTPUT ACCEPT", + "sudo iptables -F", + ] + } + }