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

IBM Cloud fortigate driver for non-global commands #3394

Open
wants to merge 7 commits into
base: develop
Choose a base branch
from

Conversation

SaneiSaya
Copy link

Adding a driver that will work with IBM Cloud 1500D as users are restricted and not able to run global commands. This driver allows non-global commands to be run

Created folder for fortinet-ibmcloud
Updated Linters and cache
@SaneiSaya
Copy link
Author

@ktbyers Can you check this again after the changes I made?

@ktbyers
Copy link
Owner

ktbyers commented May 4, 2024

@SaneiSaya So you are trying to get the fortinet driver to work, but without needing any global commands--correct?

@SaneiSaya
Copy link
Author

SaneiSaya commented May 4, 2024 via email

@ktbyers
Copy link
Owner

ktbyers commented Jan 21, 2025

@SaneiSaya Sorry for very delayed response--is this still an issue that you are looking to fix/work on?

@SaneiSaya
Copy link
Author

SaneiSaya commented Jan 22, 2025 via email

return result_mode
return "more"
else:
return "more"
Copy link
Owner

Choose a reason for hiding this comment

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

I am confused as to why you made this change? Why did you make any changes to the non-IBM driver?

return ""

if self._vdoms:
output += self._config_global()
Copy link
Owner

Choose a reason for hiding this comment

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

I didn't understand this? I thought your purpose was to get rid of config global, but it still does config global (depending on VDoms)?

@ktbyers
Copy link
Owner

ktbyers commented Jan 22, 2025

How do you want this to behave?

So we can't execute config global and we are using config global to determine and configure the following:

  1. Config Output Mode to "standard" in disable_paging() when VDOMs are in use.
  2. Determine current output mode "more" or "standard" when VDOMs are in use for V6 or earlier (_get_output_mode_v6)
  3. Determine current output mode "more" or "standard" when VDOMs are in use for V7 or later (_get_output_mode_v7)
  4. Restore the original output mode in cleanup(), if it was changed in step1 (and VDOMs are used).

So one working option is for the end-user to set an environment variable named NETMIKO_FORTINET_STANDARD=True and then if this is set we bypass all four of the above items.

In other words, the end-user configure the device so there is no output paging and then set the above environment variable. Once this, happens we can bypass all of the above.

I don't see how your current PR fixes the original issue you were running into?

Regards, Kirk

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants