Thomas' Tidbits: A few tidbits from Thomas about a variety of topics like programming, gaming, sports and other things.



Installing snaps offline
By: Thomas Hawkins     Published Date: 2021-09-08 13:11:00
linux snapd snap

I was trying to install a Linux application that was packaged via snap.  For some reason, my virtual machine could not access the api.snapcraft.io, but it could access the internet in general.  After waiting a day to see if the situation would resolve itself, I eventually discovered that api.snapcraft.io was blocked at the firewall level (for some reason).  So without access to that site, you cannot use the command line commands to install a snap:

sudo snap install freeorion

So, I downloaded the snap from another computer, transferred it to the VM, and then installed it using the following commands:

$ snap download freeorion
Fetching snap "freeorion"
Fetching assertions for "freeorion"
Install the snap with:
   snap ack freeorion_231.assert
   snap install freeorion_231.snap
--- Transfer snap to the other computer ---
$ sudo snap ack freeorion_231.assert
[sudo] password for thomas: 
$ sudo snap install freeorion_231.snap
freeorion v0.4.10.2 from A333 (agrrr3) installed

You can use a process like this to install any snap package on an offline computer with snap support.

Hope this helps someone.


Comment on this post:
You can choose to post your email with your message.
Your name as it will appear on the comments section.
Showing comments:
#ByCommentPost DateLikes
Subscribe to our blog


© Thomas' Tidbits