Is it safe to use an /etc/apk/cache directory that is shared across
multiple Alpine Linux systems with the same version?
I use Alpine containers on LXD.
I just started using them with a shared /etc/cache/apk as follows, and
it seems to work fine:
One-time setup (using snap lxd 3.9 on Ubuntu):
lxc storage volume create default alpine38-apk
lxc profile copy default alpine38
lxc storage volume attach-profile default alpine38-apk alpine38
/etc/apk/cache
Then create alpine/3.8 containers like this:
lxc launch images:alpine/3.8 a1 -p alpine38
lxc launch images:alpine/3.8 a2 -p alpine38
The resulting containers a1, a2 have read/write permission on the same
volume, which is mounted on /etc/apk/cache.
When alpine/3.9 is released, I'll make a new shared volume alpine39-apk,
so as not to mix different versions with the same cache.
Reference:
https://wiki.alpinelinux.org/wiki/Local_APK_cache
- Alex
---
Unsubscribe: alpine-user+unsubscribe@lists.alpinelinux.org
Help: alpine-user+help@lists.alpinelinux.org
---
El jue., 17 de ene. de 2019 a la(s) 08:10, Alex Athanasopoulos (
alex@melato.org) escribió:
> Is it safe to use an /etc/apk/cache directory that is shared across> multiple Alpine Linux systems with the same version?>
as i know, the index and packages to take will be "controled" by the index
of the repository so.. if in the cache directory we have two versions only
those registered by the index repository loaded will be taken and make
effect!
> I use Alpine containers on LXD.>
was a great idea, can you make a wiki page about it? seems wiki NEED A LOVE!
> I just started using them with a shared /etc/cache/apk as follows, and> it seems to work fine:>
on same versions or differents versions of alpine? more than one.?
i guess if two alpine version close will not have too much conflicts.. but
as i said in firts.. there's no techincally problems
>>
I recently looked-up the code related to caching. I'd say it's safe to
"sequentially" use a common cache for the same Alpine version.
Your method for sharing it is right.
On 17/01/2019 13:10, Alex Athanasopoulos wrote:
> Is it safe to use an /etc/apk/cache directory that is shared across> multiple Alpine Linux systems with the same version?>> - Alex
---
Unsubscribe: alpine-user+unsubscribe@lists.alpinelinux.org
Help: alpine-user+help@lists.alpinelinux.org
---
I have made a wiki page about how to use Alpine containers on LXD:
https://wiki.alpinelinux.org/wiki/Install_Alpine_on_LXD
On 1/17/19 2:37 PM, PICCORO McKAY Lenz wrote:
> >> I use Alpine containers on LXD.>> was a great idea, can you make a wiki page about it? seems wiki NEED A> LOVE!