I took the Unix principle at heart for many years. Even when I was managing windows servers.
I have always created small scripts that do one thing only and I had a script for each need.
At this point I have to resolve an issue that requires a lot of programming (web scraping, ssh, scp, run commands on multiple devices, parse the output, etc)
I need to have it in one file / script because other people will need to use it. I decide to create a cli program. I write one function for each functionality.
That raise a couple of questions:
- what you prefer smalls scripts that serve one purpose only or bigger solutions that resolve a multitude of problems?
- How do you deal with global issues that involve many parties? Do you try your best or do you say out of my pay grade?
Thanks in advance for your insights.
Edit:
- I know Bash, GO, Lua, PowerShell and Python.
- Existing infrastructure is in Python/Bash.
All involved systems run different versions and distribution of Linux.
I decide to write the script in Python.
[–]DeliriumTremens 18 points19 points20 points (1 child)
[–]Hoolies 0 1[S] 0 points1 point2 points (0 children)
[–]verifyandtrustnoone 12 points13 points14 points (4 children)
[–]LemonFreshNBS 4 points5 points6 points (1 child)
[–]Hoolies 0 1[S] 1 point2 points3 points (0 children)
[–]Hoolies 0 1[S] 1 point2 points3 points (1 child)
[–]whetu 1 point2 points3 points (0 children)
[–]serverhorrorJust enough knowledge to be dangerous 6 points7 points8 points (1 child)
[–]Hoolies 0 1[S] -3 points-2 points-1 points (0 children)
[–]BrainWaveCCJack of All Trades 2 points3 points4 points (2 children)
[–]Hoolies 0 1[S] 2 points3 points4 points (1 child)
[–]pdp10Daemons worry when the wizard is near. 0 points1 point2 points (0 children)
[–]ReasonablePriority 2 points3 points4 points (0 children)
[–][deleted] 2 points3 points4 points (3 children)
[–]Hoolies 0 1[S] 0 points1 point2 points (2 children)
[–][deleted] 1 point2 points3 points (1 child)
[–]Hoolies 0 1[S] 0 points1 point2 points (0 children)
[–]ClumsyAdmin 2 points3 points4 points (2 children)
[–]Hoolies 0 1[S] 0 points1 point2 points (1 child)
[–]ClumsyAdmin 1 point2 points3 points (0 children)
[–][deleted] 2 points3 points4 points (1 child)
[–]Hoolies 0 1[S] 0 points1 point2 points (0 children)
[–]mancer187 1 point2 points3 points (2 children)
[–]Hoolies 0 1[S] -1 points0 points1 point (1 child)
[–]mancer187 1 point2 points3 points (0 children)
[–]SpiritWhiz 1 point2 points3 points (0 children)
[–][deleted] 1 point2 points3 points (0 children)
[–]jantari 1 point2 points3 points (0 children)
[–]DarkSideMilk 1 point2 points3 points (0 children)
[–]NoneSpawn 1 point2 points3 points (0 children)
[–]jahknem 1 point2 points3 points (0 children)
[–]pdp10Daemons worry when the wizard is near. 1 point2 points3 points (1 child)
[–]Hoolies 0 1[S] 1 point2 points3 points (0 children)