How to clean an 'updated' nginx proxy manager LXC? #14920
Replies: 3 comments 1 reply
-
|
That are Node Caches (f.e. yarn, pnpm, npm) you can run f.e. yarn cache clean with yarn tools to remove the build Cache. We have removed this cleaning in our core, because some apps constantly broke after cleaning. You can try it by your own, but i recommend to do an snapshot or backup before. |
Beta Was this translation helpful? Give feedback.
-
|
Ill paste below what I usually do and Ill try to make it a bit lxc agnostic so you can use it for any lxc, not just NPM: Housekeeping:
Checkup:
First two will show space used and what folders are the highest space users. Next two shows you how big are apt caches and logs. There are more commands that you can run but these will start giving you a sense how do go about this process. Cleanup:
First two will cleanup previous updates leftovers; third one will delete all logs older than 7 days - Im assuming if the service is running well you dont need old logs; next 3 will remove old node caches whether it relies on pnpm, npm or yarn - if it doesnt it will just say - not found. That is the most basic setup - you can investigate more folders using the Checkup section by editing those commands. Just never delete node modules or service main folder and always backup before making cuts. |
Beta Was this translation helpful? Give feedback.
-
|
Thanks, Gentlemen These two commands reclaimed 75% of my storage for this particular lxc! npm cache clean --force (the pnpm command didn't work in this lxc - 'command not found'). It doesn't seem to have broken anything on the NPM lxc, but I have a snapshot & backup to fall back to just in case there is an issue at the next update. Appreciate the help. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hey guys,
I have an nginx proxy manager LXC that I've updated a few times. It always seems to work great, but each update increases the disk usage about a gigabyte or so. I've had to resize the disk a couple times now and it's approaching capacity again.
Does anyone know why it keeps increasing in space and never re-claiming any space? It's like it keeps adding and not replacing during each update... Is there a way to 'clean' it? 'apt autoremove' does nothing...
I really hate to start 'fresh' with a new lxc because there's no backup/restore functionality (why in the world there isn't is beyond me) and I have quite a few hosts that I'd prefer not to reconfigure.
Thanks in advance!
Beta Was this translation helpful? Give feedback.
All reactions