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

2.2 : rename project with docker and symbolic link #2427

Closed
Raizo62 opened this issue Oct 5, 2024 · 3 comments · Fixed by #2428
Closed

2.2 : rename project with docker and symbolic link #2427

Raizo62 opened this issue Oct 5, 2024 · 3 comments · Fixed by #2428
Labels

Comments

@Raizo62
Copy link
Contributor

Raizo62 commented Oct 5, 2024

Hi

  • I am creating a new template docker "alpine" with an alpine image.

  • I'm configuring this image with the persistent folder "/link"

  • I'm creating the new project "untitled"

  • I'm running the VM "alpine"

  • In the console, i'm creating a symbolic link :

cd /link
ln -s ../etc/os-release  os-release

(This is the type of syntax in /etc/network of Debian)

  • I'm stopping the VM

  • With GNS3, i'm renaming the project with this new name : newname
    I have this error message :
    2024-10-05 13:13:44 ERROR project:336 Error while duplicating project: Cannot duplicate project: [('/home/user/projects/untitled/project-files/docker/ec050da8-26c0-4012-b254-3a304385c6d9/link/os-release', '/home/user/projects/43087ed0-73d8-4841-9c97-a78fe212c6b3/project-files/docker/ec050da8-26c0-4012-b254-3a304385c6d9/link/os-release', "[Errno 2] No such file or directory: '/home/user/projects/untitled/project-files/docker/ec050da8-26c0-4012-b254-3a304385c6d9/link/os-release'")]

No error if the symbolic link is created with the command

cd /link
ln -s /etc/os-release  os-release

But the file /link/os-release is no longer a symbolic link but a standard file

@Raizo62 Raizo62 added the Bug label Oct 5, 2024
@grossmj
Copy link
Member

grossmj commented Oct 17, 2024

I think the reason is because use the zipfile module in Python https://docs.python.org/3/library/zipfile.html which does not support symbolic links. I could try to implement an alternative.

@grossmj grossmj transferred this issue from GNS3/gns3-gui Oct 19, 2024
@grossmj grossmj linked a pull request Oct 19, 2024 that will close this issue
@grossmj
Copy link
Member

grossmj commented Oct 19, 2024

I have added support for symbolic links. It will work in v2.2.50 onward.

Please don't hesitate to comment back if you spot a problem related to this issue.

@grossmj grossmj closed this as completed Oct 19, 2024
@Raizo62
Copy link
Contributor Author

Raizo62 commented Oct 20, 2024

This seems to work :-) Thanks :-)

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

Successfully merging a pull request may close this issue.

2 participants