Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle sysctl VLANs #405

Merged

Conversation

sgnsys3
Copy link
Contributor

@sgnsys3 sgnsys3 commented Oct 3, 2023

Referring to Issue #404

If the Interface name has a "." in the name then replace "." with "/".

@sgnsys3 sgnsys3 requested a review from konstruktoid as a code owner October 3, 2023 08:41
@konstruktoid
Copy link
Owner

Hi @sgnsys3 and thanks for the PR.
However it returns:

Syntax Error while loading YAML.
  found unknown escape character

Please test with | regex_replace('\\.', '/')

tasks/sysctl.yml Outdated Show resolved Hide resolved
@konstruktoid
Copy link
Owner

Hi again @sgnsys3
Any updates on this one?

@sgnsys3
Copy link
Contributor Author

sgnsys3 commented Dec 19, 2023

@konstruktoid Hi Sorry for the late reply, Last month was very tight for me.
I've updated the change according to your latest code.

In Vagrantfile, I have updated the serial connection method because I have run it on Windows and it always failed
To make this easier I set it to disconnected. Or Does It need to be connected?

@konstruktoid
Copy link
Owner

@konstruktoid Hi Sorry for the late reply, Last month was very tight for me. I've updated the change according to your latest code.

No worries at all :)

In Vagrantfile, I have updated the serial connection method because I have run it on Windows and it always failed To make this easier I set it to disconnected. Or Does It need to be connected?

Nah, it can be connected when needed.

@konstruktoid
Copy link
Owner

Just one comment regarding the Vagrantfile

@konstruktoid
Copy link
Owner

diff --git a/Vagrantfile b/Vagrantfile
index eb900cd..7c5c24b 100644
--- a/Vagrantfile
+++ b/Vagrantfile
@@ -22,10 +22,10 @@ Vagrant.configure("2") do |config|
       a.extra_vars = {
         "ansible_become_pass" => "vagrant",
         "ansible_python_interpreter" => "/usr/bin/python3",
-        "sshd_admin_net" => "0.0.0.0/0",
-        "sshd_allow_groups" => "vagrant sudo debian ubuntu",
-        "system_upgrade" => "no",
-        "install_aide" => "false"
+        "sshd_admin_net" => ["0.0.0.0/0"],
+        "sshd_allow_groups" => ["vagrant", "sudo", "debian", "ubuntu"],
+        "system_upgrade" => "false",
+        "install_aide" => "false",
       }
     end
   end
@@ -47,7 +47,7 @@ Vagrant.configure("2") do |config|
         "ansible_python_interpreter" => "/usr/bin/python3",
         "sshd_admin_net" => ["0.0.0.0/0"],
         "sshd_allow_groups" => ["vagrant", "sudo", "debian", "ubuntu"],
-        "system_upgrade" => "no",
+        "system_upgrade" => "false",
      }
     end
   end

@konstruktoid
Copy link
Owner

Closes #404

@sgnsys3
Copy link
Contributor Author

sgnsys3 commented Dec 21, 2023

@konstruktoid Updated

@konstruktoid konstruktoid changed the title Replace "." with "/" for sysctl Handle sysctl VLANs Dec 21, 2023
tasks/sysctl.yml Outdated Show resolved Hide resolved
tasks/sysctl.yml Outdated Show resolved Hide resolved
tasks/sysctl.yml Outdated Show resolved Hide resolved
Vagrantfile Outdated
"ansible_become_pass" => "vagrant",
"ansible_python_interpreter" => "/usr/bin/python3",
"sshd_admin_net" => "0.0.0.0/0",
"sshd_allow_groups" => "vagrant sudo debian ubuntu",
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be ["vagrant", "sudo", "debian", "ubuntu"],

@@ -17,6 +17,12 @@ provisioner:
log: true
inventory:
host_vars:
bullseye_vlan:
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need to add bullseye_vlan since no VLAN is actually configured

@konstruktoid
Copy link
Owner

Thanks @sgnsys3!

@konstruktoid konstruktoid merged commit d9c9a35 into konstruktoid:master Dec 21, 2023
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants