• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login
UBports Robot Logo UBports Forum
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login

Adding an app to a container using the tweak tool?

Scheduled Pinned Locked Moved Libertine
14 Posts 5 Posters 928 Views 3 Watching
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • K Offline
      Keneda @jojumaxx
      last edited by 18 Mar 2022, 23:44

      @jojumaxx said in Adding an app to a container using the tweak tool?:

      I tried using a 'root' terminal within the container, but it didn't work out due to errors...

      https://forums.ubports.com/topic/7572/problem-with-sudo-is-my-system-broken/2?_=1647646805260

      2015-2023 : Meizu MX4 ☠️⚰️✝️
      2023-2024 : Nexus 5 ☠️⚰️✝️
      2024-***** : FPOS Fairphone 5 waiting UT for freedom 😉
      🇲🇫🇬🇧

      1 Reply Last reply Reply Quote 0
      • P Offline
        Pulsar33 @bre34
        last edited by 19 Mar 2022, 06:27

        @bre34 @jojumaxx Why are you trying to use Tweak tool or root terminal ?
        It is so simple with the normal way : https://forums.ubports.com/post/57032
        Good luck
        Pulsar33

        Aquaris BQ E5 HD UBports OTA-25 (currently testing features)
        Aquaris BQ E5 HD Ubuntu Edition Canonical OTA-15 (last Canonical version, daily use)
        Raspberry Pi 4 B - 4 GB & 8 GB with various OS and Desktops (UBports not OK)

        J 1 Reply Last reply 19 Mar 2022, 09:05 Reply Quote 0
        • J Offline
          jojumaxx @Pulsar33
          last edited by jojumaxx 19 Mar 2022, 09:05

          @pulsar33 The idea was to install an application not yet listet or mentioned. I thought, maybe within a Libertine container that could be possible. What I tried simply was to open a terminal using

          libertine-container-manager exec -c bash
          

          and run a 'snap install' inside it. Since that failes, I'm curious on how that might be possible.

          Happily running Ubuntu Touch:

          • BQ Aquaris E5 HD (Retired)
          • BQ Aquaris M10 HD (Retired)
          • Meizu MX4 Pro (Retired)
          • Meizu Pro 5 (Retired)
          • PinePhone UBPorts Edition
          • Volla Phone
          • Volla Phone X
          P 1 Reply Last reply 19 Mar 2022, 11:16 Reply Quote 0
          • P Offline
            Pulsar33 @jojumaxx
            last edited by 19 Mar 2022, 11:16

            @jojumaxx As said in the linked post above, I've been facing some disappointments following the documentation about the shell commands for Libertine containers. That's why I wrote some tips.

            For bash, install a terminal in Libertine with the normal way then use it to launch your commands instead trying to "bash" from the outside. Here are a lot of terminal instance which have been tested : https://forums.ubports.com/post/62677

            For Flatpack : @Keneda has replied above

            BR
            Pulsar33

            Aquaris BQ E5 HD UBports OTA-25 (currently testing features)
            Aquaris BQ E5 HD Ubuntu Edition Canonical OTA-15 (last Canonical version, daily use)
            Raspberry Pi 4 B - 4 GB & 8 GB with various OS and Desktops (UBports not OK)

            J 1 Reply Last reply 19 Mar 2022, 18:57 Reply Quote 0
            • J Offline
              jojumaxx @Pulsar33
              last edited by jojumaxx 19 Mar 2022, 18:57

              @pulsar33
              I think, I am missing some basic understanding, so please keep being patient.

              I read the thread you linked, but I got no luck:

              I installed the gnome-terminal in the Libertine container. Trying to launch it results in an immediate crash. I guess, that's why I have to do this:

              "gnome-terminal: in /usr/share/applications/gnome-terminal.desktop Exec=gnome-terminal must be edited to Exec=dbus-launch gnome-terminal. There are multiple Exec entries in the file do this for all of them."

              When I do navigate there (in my standard terminal, not within the Libertine container), there is no file named 'gnome-terminal.desktop' (though there is a symbol present on the homescreen).
              So what do I have to do now, exactly?

              Happily running Ubuntu Touch:

              • BQ Aquaris E5 HD (Retired)
              • BQ Aquaris M10 HD (Retired)
              • Meizu MX4 Pro (Retired)
              • Meizu Pro 5 (Retired)
              • PinePhone UBPorts Edition
              • Volla Phone
              • Volla Phone X
              B P 2 Replies Last reply 20 Mar 2022, 00:35 Reply Quote 0
              • B Offline
                bre34 @jojumaxx
                last edited by bre34 20 Mar 2022, 00:35

                @jojumaxx This happened to me, too. This is what I did.

                Go to the regular UT terminal app that was there already when you installed UT on your phone and launch it.

                Type in at the prompt and do not use "sudo":
                libertine-container-manager exec -i xenial -c bash

                I did not use "sudo" for anything while doing this.

                There was a series of lines that say something like:

                groups: cannot find name for group ID 10
                01
                groups: cannot find name for group ID 10
                02
                groups: cannot find name for group ID 10
                03
                groups: cannot find name for group ID 10
                04
                groups: cannot find name for group ID 10
                05
                groups: cannot find name for group ID 10
                13
                groups: cannot find name for group ID 10
                15
                groups: cannot find name for group ID 10
                21
                groups: cannot find name for group ID 20
                01
                groups: cannot find name for group ID 30
                02
                groups: cannot find name for group ID 30
                03
                groups: cannot find name for group ID 30
                04
                groups: cannot find name for group ID 99
                97
                groups: cannot find name for group ID 32
                011
                bash: /home/phablet/.bashrc: Permission
                denied
                root@ubuntu-phablet:/#

                I typed at the prompt: cd /usr/share/applications

                and got then got this:

                root@ubuntu-phablet:/usr/share/applicati
                ons#

                I typed at the prompt: ls

                The above two characters are a little "L" and small "S". This will list the files in the applications folder.

                Among the files that show up should be "gnome-terminal.desktop". You should still have the same prompt as before after the listing is complete. Then, I typed in at the prompt "nano gnome-terminal.desktop". You should have "nano" installed in the container before you do any of these steps. "nano" is a nice little editor that I use to modify files. It has methods to select keys like "Control-X", etc. that you will need to save your modified file. There is also a selection you will make inside "nano" that will select arrow keys that you can navigate up, down, right, and left to get to that line you have to change. It took me some time to get it all done with the small keyboard.

                This allowed me to launch the new "gnome-terminal" icon. I then tried to "apt install" an app and it hung in the middle of my typing it. The keyboard disappeared and the gnome-terminal app froze.

                I put in another topic entry for it. If you get past my problem, please post your solution here or on my other topic. I hope this helps. If I did something wrong or need to fix things, still, please let me know.

                1 Reply Last reply Reply Quote 0
                • P Offline
                  Pulsar33 @jojumaxx
                  last edited by 20 Mar 2022, 06:05

                  @jojumaxx @bre34 Hello
                  I don't understand very well all what you say and do. I can just say you "don't look for complicated solutions !"

                  If you read this message you will see that FakeShell and me had not the same experience with gnome-terminal (highlighted in yellow). I didn't try his workaround for gnome-terminal, I use LXterminal

                  Another tip I can give is this: when you've done a lot of testing and gotten a lot of errors, DELETE your container and reinstall everything that worked from the beginning.

                  Good luck
                  Pulsar33

                  Aquaris BQ E5 HD UBports OTA-25 (currently testing features)
                  Aquaris BQ E5 HD Ubuntu Edition Canonical OTA-15 (last Canonical version, daily use)
                  Raspberry Pi 4 B - 4 GB & 8 GB with various OS and Desktops (UBports not OK)

                  P 1 Reply Last reply 21 Mar 2022, 06:31 Reply Quote 0
                  • D Offline
                    doniks @bre34
                    last edited by 20 Mar 2022, 08:23

                    @bre34

                    there are a lot of things in here. A few points I know for a fact:

                    • you cannot install applications from LTT. I don't think this feature is needed
                    • you can install applications from the Libertine system settings
                    • you can add alternate ppa archives from the Libertine system settings

                    A few more points, I think might apply to you:

                    • I don't know protonvpn, but I could imagine whatever vpn software you come up with needs deep (kernel) level integration. I'm not sure how much luck you will have with this.
                    • at some point you talk about snap, that's an entirely different beast. I would not be surprised if there is no way to make snap work in libertine.
                    • not quite sure why you try to use gnome-terminal. I guess in the best case you would get the same features that you already have in ubuntu touch terminal. And I wouldn't be surprised if you run into a lot of issues that make it a lot of work with a much worse user experience the UT terminal

                    Bottom line, I have the feeling you are asking too specific questions. Like someone asking "How can I avoid the nail from bending when I try to hammer it into concrete with my wrench?", rather than asking "How can I hang my pictures?"... I would suggest a new thread with a question about what you try to achieve.

                    1 Reply Last reply Reply Quote 1
                    • B Offline
                      bre34
                      last edited by bre34 21 Mar 2022, 01:56

                      Pulsar33 and doniks:

                      Thanks for the information. I've tried three times to install the container and I still get errors. The Libertine GUI in Settings would not delete the container. I had to manually go into two directories with terminal to delete it all. I also had to delete the name of the container using the terminal. This was mentioned in another post. According to the Libertine documentation, my two options (ADB and SSH) did not work either. I had been using ADB to flash my phone and I have ADB on both my computer and Pixel 3a. I set up keys on my computer and phone and still could not get SSH to work. I had Developer Mode on and also SSH was enabled on the phone with UT Tweak Tool. The documentation said that I needed to use either ADB or SSH to use Libertine commands due to AppArmor. I just tried them in a terminal and they did not work. If you can point me to a real good tutorial on ADB or even SSH or a third option I do not know about, then I would appreciate that.

                      1 Reply Last reply Reply Quote 0
                      • P Offline
                        Pulsar33 @Pulsar33
                        last edited by Pulsar33 21 Mar 2022, 06:31

                        @pulsar33 said in Adding an app to a container using the tweak tool?:

                        I don't understand very well all what you say and do. I can just say you "don't look for complicated solutions !"

                        @bre34 I'm not a developer like @doniks and he would certainly have good explanations for the problems you are facing. But it seems to me that with so many problems, you should reinstall UBports entirely. Maybe you destroyed or changed something important during your so many attempts.

                        Then, for Libertine, follow that and only that : https://forums.ubports.com/post/57032
                        For the choice of applications to install with Libertine Preference follow that : https://forums.ubports.com/post/62789

                        Good luck
                        Pulsar33

                        Aquaris BQ E5 HD UBports OTA-25 (currently testing features)
                        Aquaris BQ E5 HD Ubuntu Edition Canonical OTA-15 (last Canonical version, daily use)
                        Raspberry Pi 4 B - 4 GB & 8 GB with various OS and Desktops (UBports not OK)

                        1 Reply Last reply Reply Quote 0
                        • B Offline
                          bre34
                          last edited by 22 Mar 2022, 00:04

                          Thanks. It's a work in progress. 🙂

                          1 Reply Last reply Reply Quote 0
                          13 out of 14
                          • First post
                            13/14
                            Last post