pelican-dev / panel

https://pelican.dev
GNU Affero General Public License v3.0
775 stars 80 forks source link

Allocation are deleted, when you delete a Server #541

Closed gOOvER closed 1 month ago

gOOvER commented 1 month ago

Current Behavior

If you delete an existing server, the allocated ports in the node are also deleted

Expected Behavior

The allocated ports in the node should not be deleted, but released

Steps to Reproduce

Panel Version

1.0.0-beta7

Wings Version

1.0.0-beta3

Games and/or Eggs Affected

No response

Docker Image

No response

Error Logs

No response

Is there an existing issue for this?

RMartinOscar commented 1 month ago

https://github.com/pelican-dev/panel/blob/953ee940aa5955dfdad452dbdc46f48ca5e5bb55/app/Services/Servers/ServerDeletionService.php#L80

It shouldn't delete it What's your Database driver ?

gOOvER commented 1 month ago

https://github.com/pelican-dev/panel/blob/main/app/Services/Servers/ServerDeletionService.php#L80

It shouldn't delete it What's your Database driver ?

sqlite

RMartinOscar commented 1 month ago

Could it be this ?

https://github.com/pelican-dev/panel/blob/10806d6d6bcad8a875bdfc7fec7ecce2c6bced6c/database/migrations/2024_07_12_095213_fix_missing_sqlite_foreign_keys.php#L161

Im trying my best but im not at home rn

gOOvER commented 1 month ago

Before delete: Pelican: MoQgYW

sqlite.db: bthETk

After Server delete: Pelican: AbUe45

sqlite.db: 5vGkY0