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

Supportting other distros #9

Open
RamonGiovane opened this issue Apr 9, 2024 · 4 comments
Open

Supportting other distros #9

RamonGiovane opened this issue Apr 9, 2024 · 4 comments
Labels
enhancement New feature or request

Comments

@RamonGiovane
Copy link
Owner

RamonGiovane commented Apr 9, 2024

I've tested Cockpit on non-RHEL-like systems and it works very well.
So as long as Cockpit is running in a distro and it has iptables, I think guiptables is good to go.

The problem comes when we need to install iptables within guiptables, as RHEL-like systems use yum and other distros has different package mangers.
For this I can think in two options:

  1. Supportting other package managers. This would be the most complex way. I was thinking about allowing the user to pass the desired package manager name in settings.json and then the code identifies the right command to call. A release .deb package would have apt configured by default, and so on...
    But on second tought, I don't know if it's worth the effort. There's currently no other task to package managers here besides installing iptables if it's not installed.
  2. Dropping the option to install Iptables for non RHEL-like systems and show error on the current widget.

That is the only code related thing I see that would impact supporting other distros.
Besides that, the really challenge would be writing the scripts to create release packages. From my experience with .rpms, it wasn't as easy how I thought it would be.

@RamonGiovane RamonGiovane added the enhancement New feature or request label Apr 10, 2024
@bambosd
Copy link

bambosd commented Jun 30, 2024

Hello Ramon,
i'm trying to have guiptables on cockpit on a debian 12 bookworm system.
is there any workaround to have it functioning ?
Even if a add the backports repository there is no guiptables package.

Do you think will work if i enable yum packages on debian and reinstall everything from yum repositories ?
any suggestions appreciated.

@RamonGiovane
Copy link
Owner Author

Hello Ramon, i'm trying to have guiptables on cockpit on a debian 12 bookworm system. is there any workaround to have it functioning ? Even if a add the backports repository there is no guiptables package.

Do you think will work if i enable yum packages on debian and reinstall everything from yum repositories ? any suggestions appreciated.

Hi.
Have you tried the second method of installation described on READ ME?

You can basically install Cockpit  then download guiptables source code and place it inside the Cockpit plugins directory.

https://github.com/RamonGiovane/guiptables?tab=readme-ov-file#using-the-source-code

@bambosd
Copy link

bambosd commented Jul 1, 2024

This is the steps i have followed to have step by step setup on Debian 12. Please publish on your next documentation.

sudo apt install iptables
sudo apt install git
sudo git clone https://github.com/RamonGiovane/guiptables.git
sudo cp -r guiptables/ /usr/share/cockpit/

Since iptables require root login:
system change:

sudo nano /etc/ssh/sshd_config
In the configuration file, find the line that says PermitRootLogin
and change it to yes. This action allows the root user to log in via SSH.
sudo systemctl restart ssh

cockpit change:

Root login disabled by /etc/cockpit/disallowed-users,
so if you want to allow root login you will need to remove the
root entry from that file

Navigate to : https://systemip:9090/ and login as root. You should have iptables menu on the left.
image

@RamonGiovane
Copy link
Owner Author

Version 1.4 now supports access for non root users. https://github.com/RamonGiovane/guiptables/releases/tag/1.4.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants