HowTo: Etcher AppImage on Debian

I figured out how to get the AppImage working on Debian if anyone want’s to do the same (as repository errors occured using apt method)

1st I tried launching it via terminal to see any errors shown.
I saw a ‘ffmpeg’ missing error so I installed ffmpeg with…
apt-get install ffmpeg

Then it worked launching from terminal…
sudo ./balenaEtcher-1.5.101-x64.AppImage

Next I needed to add the AppImage to pkexec list of allowed apps…
like so…
Open or create the file (as root)
/usr/share/polkit-1/actions/org.freedesktop.policykit.pkexec.policy

Add the following text…
(If policy file is not empty only add the text from <action id=…> to </action>)

<?xml version=“1.0” encoding=“UTF-8”?>
<!DOCTYPE policyconfig PUBLIC
“-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN”
http://www.freedesktop.org/standards/PolicyKit/1/policyconfig.dtd”>
<policyconfig>

<action id=“org.freedesktop.policykit.pkexec.run-balenaEtcher-1.5.101-x64.AppImage”>
<description>Balena Etcher</description>
<message>Etcher requires SuperUser access</message>
<defaults>
<allow_any>no</allow_any>
<allow_inactive>no</allow_inactive>
<allow_active>auth_admin_keep</allow_active>
</defaults>
<annotate key=“org.freedesktop.policykit.exec.path”>/path/balenaEtcher-1.5.101-x64.AppImage</annotate>
<annotate key=“org.freedesktop.policykit.exec.allow_gui”>TRUE</annotate>
</action>

</policyconfig>

Change the line…
<annotate key=“org.freedesktop.policykit.exec.path”>/path/balenaEtcher-1.5.101-x64.AppImage</annotate>
setting /path/balenaEtcher-1.5.101-x64.AppImage to the correct path to where your AppImage is.

Now save the policy config file.

Now you can create a launcher in the menu’s or on the desktop or anywhere.
Set the launchers command to the path of the AppImage and prefix with pkexec command…
Eg.
pkexec /path/to/prog/balenaEtcher-1.5.101-x64.AppImage

I hope this helps some :slight_smile:
Bruce

Hey @Brucey,
Welcome to the Forums and thanks for sharing this resource and your insights with us.
Hopefully, other users will find this helpful.

Keep up the nice job!
Georgia

Hi Georgiats
You’re welcome and thank you all at balena for such a useful app.

I’ve gone one better and written a script to do all the work for those who might find the manual way a bit complicated :slight_smile:

Download it from my googleDrive here…
Etcher_Launcher_Setup

The script auto configures the pkexec policy for you and then adds a launcher to the users desktop.

To anyone who wants to try it just download the zip and extract
open a terminal and cd to the extracted folder
then type…
sudo ./Setup_Etcher

it uses zenity for nice gui dialogues

note, do not run from a root terminal. use sudo from non root

I hope it helps.
Bruce
(Edit. I fixed a bug, was missing quote marks in case the launcher name had a space. , re-uploaded and fixed and tested)

Hey Brucey, thanks again! Just a note, it might be better to put it on Github as a repo or a gist, I’m sure most users are more comfortable with that rather than downloading files from google drive. Anyhow, I hope other users find this useful!

okay thanks…
I’ve just done that now too :wink:

or use a terminal and type the following…

git clone https://github.com/BruceSteers/debian_etcher_setup
cd ./debian_etcher_setup
chmod +x ./Setup_Etcher
sudo ./Setup_Etcher

Just an additional note…

I would suggest Renaming the AppImage first from
balenaEtcher-1.5.101-x64.AppImage
to simply
balenaEtcher.AppImage

Then if a new version comes out all you will need to do is rename that too and overwrite the old one.
Otherwise the new version will need configuring the same way.
Unless of course the issue gets resolved
I had no problems at all with ubuntu or mint only debian so i assume it’s a simple issue that will soon be resolved.

Hi @Brucey – that’s good feedback to have. Can I ask you to file an issue for that in the Etcher repo at https://github.com/balena-io/etcher/issues/? That’s the best way to bring that to the attention of the Etcher team.

One workaround for this that I use is to create a symlink to the particular AppImage:

ln -s path/to/balenaEtcher-1.0.101-x64.AppImage balenaEtcher.AppImage

I wonder if that’s something that would work for you?

All the best,
Hugh

thank you sir, just trying to help :slight_smile:
I’ve never used links Hugh so i’m unfamiliar with the techniques

I’ve just edited the setup script to check for existing Etcher entries to the policy file and omit them.
so if the next version still does not work the script can just be run again and will cleanly reconfigure the pkexec policy file to the new Etcher file name.

Feel free to have the script and modify it in anyway :smile:
or suggest any additions.
like i say i don’t know how symlinks work but if you think it could be a better option that renaming the AppImage file please explain.

Nice!