-
-
Notifications
You must be signed in to change notification settings - Fork 648
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
Match files in /var/lib/cobbler/autoinstall_scripts only #1811
Conversation
Revert unnecessary change
eb3d18e
to
6eb56d0
Compare
@@ -1063,9 +1063,16 @@ def generate_script(self, what, objname, script_name): | |||
else: | |||
blended['img_path'] = os.path.join("/images", distro.name) | |||
|
|||
template = os.path.normpath(os.path.join("/var/lib/cobbler/autoinstall_scripts", script_name)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When generate_scripts
was introduced (I believe here: 955568d#diff-7ae3873d5c766467d4634ede08a8e6d6R1037) the path was /var/lib/cobbler/scripts
and it actually existed. The new path /var/lib/cobbler/autoinstall_scripts
does not exist.
Is this intended?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In fact there still are another references to /var/lib/cobbler/autoinstall_scripts
MANIFEST.in:recursive-include autoinstall_scripts *
setup.py: ("%s/scripts" % libpath, glob("autoinstall_scripts/*")),
Without checking the whole git history.., it looks as if a setup.py install should create the directory or the .spec file and autoinstall_scripts (former kickstart_ functionality naming) has been split out from other scripts?
Not sure, but if, then the other autoinstall_scripts occurences should be taken care for too, to aovid other leftovers.
BTW: What is your problem/error?
Maybe simply creating the directory solves things. Then the correct fix might be to create the dir in the .spec file?
Hi ! Sorry for the late response. But /var/lib/cobbler/scripts does exist after a fresh install. |
@jmaas should I change the path in tftpgen.py to |
@dincamihai Could you rebase this on the futurize branch please? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please do change the path then we can get this into the tree.
@dincamihai Could you please rebease and we then see if this works? |
I also agree that autoinstall_scripts is much nicer than scripts. |
This PR restricts matching
script_name
with files found in/var/lib/cobbler/autoinstall_scripts
only.PS: this is my first PR here so please be gentle :)