Inodes in Docker image


#1

Good morning/afternoon. I’m currently using a docker image of Reaction Commerce. The number of inodes used by this image is very high. I am not able to create a new/backup image due to this problem. Is there anything that I might be able to safely delete in the .meteor & .reaction directories or is my only option to create a new file system & relocate the docker fs?

Thank you.


#2

Can you be more specific about what you’re doing and what errors you’re seeing? Also, why are you trying to backup a Reaction image? There’s no persistent data inside of it. It’s a snapshot of versioned ephemeral code, so you should always be able to pull that same image back down again whenever you need it. Or even pick any git commit and create a new build from it. You should be able to scrap any running image and replace/upgrade it at any time without losing anything because all persistent data should always be in a database outside of the container. Even if you opted to use an internal database (not recommended outside of development), you could still expose the data volume and persist the contents outside of the container.


#3

Also, the .meteor and .reaction directories don’t exist inside the container. They’re disposed of at the end of the build.


#4

Thank you for the reply, Jeremy. I pulled the “reactioncommerce/reation:latest” image & it has the “.meteor” directory with 1.4G of data. So, I can delete this directory?

Also, I was creating a backup because there is already some minor within it & I’m trying something new. So, if I botch things badly, I wanted to be able to fall back to a “clean” version.

Thank you!


#5

The .meteor directory where? The local one in the app source is deleted here and the global one is deleted here. The total image size is only 156MB, so I’m not sure how you’re seeing a 1.4GB Meteor directory unless you’ve reinstalled meteor manually yourself.

More importantly, are you doing development inside a prebuilt production image? That’s definitely not the recommended approach. You should be working in the local development environment that you get with the reaction init command. The filesystem is completely different and is tailored to the development workflow.


#6

I see one under /root/:
drwxr-xr-x 4 root root 4096 Apr 12 15:37 .meteor/

So, I am doing this all wrong, I guess. Go figure. :slight_smile:

Thank you for your help. I’ll start over.