[SOLVED with chroot] Older App's with snap?

If it doesn't relate to Debian, but you still want to share it, please do it here

[SOLVED with chroot] Older App's with snap?

Postby bester69 » 2017-12-23 16:00

Hi,
I was wondering, can i use snap in order to install some very old linux app's versions.

I was thinking of using a wheezy Virtual machine in order to build the snap's app, so then i can install it in stretch... is this possible?? :roll:


thanks.
Last edited by bester69 on 2017-12-26 13:05, edited 3 times in total.
bester69 wrote:There is nothing to install in linux, from time to time i go to google searching for something fresh to install in linux, but, there is nothing
User avatar
bester69
 
Posts: 1201
Joined: 2015-04-02 13:15

Re: Older App's with snap?

Postby anticapitalista » 2017-12-23 16:20

Try it and let us know how it went.
antiX "Heather Heyer" - lean and mean.
http://antix.mepis.org
anticapitalista
 
Posts: 330
Joined: 2007-12-14 23:16

Re: Older App's with snap?

Postby stevepusser » 2017-12-23 17:57

Examples?

Wheezy is still maintained and gets security updates, but any older and you will get abandoned library versions with known security holes, and that will happen to Wheezy in six months.
The MX Linux repositories: Backports galore! If we don't have something, just ask and we'll try--we like challenges. New packages: GIMP 2.10.6, Pale Moon 28.1.0, wine-staging 3.16, qBittorrent 4.1.3, Linux kernel 4.18.8, virtualbox 5.2.18
User avatar
stevepusser
 
Posts: 9913
Joined: 2009-10-06 05:53

Re: Older App's with snap?

Postby bester69 » 2017-12-23 18:15

stevepusser wrote:Examples?

Wheezy is still maintained and gets security updates, but any older and you will get abandoned library versions with known security holes, and that will happen to Wheezy in six months.


ok, My question, is .. can i install thoses ones in stretch by creating a snap?.. Imagine the scenario when an old app has been abandoned (i.e. an older one than wheezy) and you would like to use it. Snap make use of apparmor isolation, i think there are not big risks.
bester69 wrote:There is nothing to install in linux, from time to time i go to google searching for something fresh to install in linux, but, there is nothing
User avatar
bester69
 
Posts: 1201
Joined: 2015-04-02 13:15

Re: Older App's with snap?

Postby deborah-and-ian » 2017-12-23 18:49

can i install thoses ones in stretch by creating a snap?


I think you'll have more luck asking over at the snapcraft forums[1] or just trying to build a snap yourself[2].

[1] https://forum.snapcraft.io/categories
[2] https://docs.snapcraft.io/build-snaps/
Debian GNU/Linux 9 Stretch w/Openbox

Acer Aspire E5-521G
AMD A8-6410 APU
4 GB RAM
integrated AMD Mullins
dedicated AMD Hainan Radeon R5 M240 2 GB
240 GB Toshiba Q300 SSD
Realtek RTL8111/8168/8411 ethernet
Qualcomm Atheros QCA9565 wireless
deborah-and-ian
 
Posts: 182
Joined: 2016-07-13 08:40

Re: Older App's with snap?

Postby anticapitalista » 2017-12-23 20:30

bester69 wrote:
stevepusser wrote:Examples?

Wheezy is still maintained and gets security updates, but any older and you will get abandoned library versions with known security holes, and that will happen to Wheezy in six months.


ok, My question, is .. can i install thoses ones in stretch by creating a snap?.. Imagine the scenario when an old app has been abandoned (i.e. an older one than wheezy) and you would like to use it. Snap make use of apparmor isolation, i think there are not big risks.


... and again I answer, try it and let us know how it went.
antiX "Heather Heyer" - lean and mean.
http://antix.mepis.org
anticapitalista
 
Posts: 330
Joined: 2007-12-14 23:16

Re: Older App's with snap?

Postby pcalvert » 2017-12-25 11:34

You may be able to run a small Wheezy system on Stretch inside an LXC container. Just another potential way to solve the problem...

Phil
“Property is the fruit of labor; property is desirable; it is a positive good
in the world. That some should be rich shows that others may become
rich, and hence is just encouragement to industry and enterprise.”
— Abraham Lincoln
pcalvert
 
Posts: 1794
Joined: 2006-04-21 11:19
Location: Sol Sector

Re: Older App's with snap?

Postby bester69 » 2017-12-25 19:01

pcalvert wrote:You may be able to run a small Wheezy system on Stretch inside an LXC container. Just another potential way to solve the problem...

Phil

That sound interesting, I will take it a look, Is it easy to deploy?

thanks
bester69 wrote:There is nothing to install in linux, from time to time i go to google searching for something fresh to install in linux, but, there is nothing
User avatar
bester69
 
Posts: 1201
Joined: 2015-04-02 13:15

Re: Older App's with snap?

Postby HuangLao » 2017-12-25 20:25

just run wheezy in a VM or chroot and block all internet access to that VM or chroot. Lots of people run old OS's this way, even satellites etc...
User avatar
HuangLao
 
Posts: 460
Joined: 2015-01-27 01:31

Re: Older App's with snap?

Postby bester69 » 2017-12-26 08:27

HuangLao wrote:just run wheezy in a VM or chroot and block all internet access to that VM or chroot. Lots of people run old OS's this way, even satellites etc...

I cant use VM solution, I cant virtualize 64 bits systems....
I didnt know chroot was able to use it in that way, so i can install a wheezy system and then, run wheezy's apps from streetch by using chroot??. I have to test this!!. thanks.
bester69 wrote:There is nothing to install in linux, from time to time i go to google searching for something fresh to install in linux, but, there is nothing
User avatar
bester69
 
Posts: 1201
Joined: 2015-04-02 13:15

Re: Older App's with snap?

Postby bester69 » 2017-12-26 09:56

bester69 wrote:
HuangLao wrote:just run wheezy in a VM or chroot and block all internet access to that VM or chroot. Lots of people run old OS's this way, even satellites etc...

I cant use VM solution, I cant virtualize 64 bits systems....
I didnt know chroot was able to use it in that way, so i can install a wheezy system and then, run wheezy's apps from streetch by using chroot??. I have to test this!!. thanks.


Ive seen chroot works, thats very cool to play with btrfs's snapshots, I can now run olders apps and some frankendebian apps without having to restore my sytem backup by playing with "chroots the snapshots".

This is very cool!!, you can run several differents versions at the same time. :o
bester69 wrote:There is nothing to install in linux, from time to time i go to google searching for something fresh to install in linux, but, there is nothing
User avatar
bester69
 
Posts: 1201
Joined: 2015-04-02 13:15

Re: Older App's with snap?

Postby pcalvert » 2017-12-26 12:03

bester69 wrote:That sound interesting, I will take it a look, Is it easy to deploy?

Not really. Expect to read a bunch of documentation and/or tutorials to get everything working. Even so, I'm not sure how mature LXC is on Debian at present.

Phil
“Property is the fruit of labor; property is desirable; it is a positive good
in the world. That some should be rich shows that others may become
rich, and hence is just encouragement to industry and enterprise.”
— Abraham Lincoln
pcalvert
 
Posts: 1794
Joined: 2006-04-21 11:19
Location: Sol Sector

Re: Older App's with snap?

Postby bester69 » 2017-12-26 13:01

pcalvert wrote:
bester69 wrote:That sound interesting, I will take it a look, Is it easy to deploy?

Not really. Expect to read a bunch of documentation and/or tutorials to get everything working. Even so, I'm not sure how mature LXC is on Debian at present.

Phil

ok, THANKS Phill
I tried LXD, but i gave it up, It seems some difficult to deploy, at the moment I will pick chroot solution for my own, Im really delighted with it, i didnt know chroot could work that way.

Ive just installed a Wheezy's VLC/chromium and runned in stretch with chroot and debootstrap; its very easy do implement.
(sudo debootstrap --variant=minbase wheezy tt/ http://ftp.us.debian.org/debian )--> Minimal debian
bester69 wrote:There is nothing to install in linux, from time to time i go to google searching for something fresh to install in linux, but, there is nothing
User avatar
bester69
 
Posts: 1201
Joined: 2015-04-02 13:15

Re: Older App's with snap?

Postby Head_on_a_Stick » 2017-12-26 13:16

bester69 wrote:(sudo debootstrap --variant=minbase wheezy tt/ http://ftp.us.debian.org/debian )--> Minimal debian

I like to debootstrap containers into btrfs subvolumes so that they are independently bootable (once a kernel is installed ofc) :)

EDIT: any filesystem trees (including subvolumes) installed under /var/lib/machines/ can be managed via machinectl(1):
Code: Select all
~ $ machinectl --all --no-pager
MACHINE CLASS     SERVICE        OS   VERSION ADDRESSES
.host   host      -              arch -       192.168.1.69...
chroot  container systemd-nspawn arch -       -

2 machines listed.
~ $

EDIT2: that won't work with wheezy though 'cos it doesn't use systemd.
ESTRAGON: We always find something, eh, Didi, to give us the impression we exist?
VLADIMIR (impatiently): Yes, yes, we're magicians.
User avatar
Head_on_a_Stick
 
Posts: 7893
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: [SOLVED with chroot] Older App's with snap?

Postby bester69 » 2017-12-26 22:02

Any limitation/consideration with running an application within chroot?,

Ive seen some applicactions seems to get problems with dbus and some daemon..I dont know if can run anything..and the properly way to do it; Im mounting like this running kodi16.1 with success in stretch (adding /run/dbus and /dev/shm to typical chroot mount points.):

Running Jessie_kodi 16.1 in Stretch debian with chroot:
run kodi
###run.sh###
Code: Select all
export APP=$1
ruta=/media/jessie
sudo cp /home/myuser/scripts/linux_app.sh $ruta/
#Mount folders
echo /run /sys /proc /dev/pts /dev/shm /dev | xargs -n1 |sudo xargs -I{} umount $ruta/{}
sleep 5
echo /dev /dev/shm /dev/pts /proc /sys /run | xargs -n1 |sudo xargs -I{} mount -o bind {} $ruta/{}
#Launch Script in chroot
sudo chroot $ruta /linux_app.sh $APP
sleep 2
#Exit Umount
echo /run /sys /proc /dev/pts /dev/shm /dev | xargs -n1 |sudo xargs -I{} umount $ruta/{}

###linux_app.sh###
Code: Select all
mount  -t btrfs -o subvol=home /dev/sda2 /home
mount  -t btrfs -o subvol=kodi /dev/sda8 /media/kodi
su myuser -c $1
sleep 5
su myuser -c "pkill -x $1"
sleep 2
su myuser -c "pkill -x $1 -9"
umount -a
su myuser -c "exit"
bester69 wrote:There is nothing to install in linux, from time to time i go to google searching for something fresh to install in linux, but, there is nothing
User avatar
bester69
 
Posts: 1201
Joined: 2015-04-02 13:15


Return to Offtopic

Who is online

Users browsing this forum: No registered users and 1 guest

fashionable