Skip to content

Add AppImage Packaging to CI#859

Merged
GyulyVGC merged 3 commits intoGyulyVGC:mainfrom
AlleM43:squashed_commits
Aug 3, 2025
Merged

Add AppImage Packaging to CI#859
GyulyVGC merged 3 commits intoGyulyVGC:mainfrom
AlleM43:squashed_commits

Conversation

@AlleM43
Copy link
Contributor

@AlleM43 AlleM43 commented Jul 7, 2025

AppImage packaging using pkg2appimage to convert the Debian package into an AppImage as part of the packaging workflow.

As mentioned in #252

@GyulyVGC GyulyVGC added the enhancement New feature, request, or improvement label Jul 7, 2025
@GyulyVGC
Copy link
Owner

GyulyVGC commented Jul 7, 2025

Thank you 🙏

Will review and test this as soon as I get enough time.

@AlleM43
Copy link
Contributor Author

AlleM43 commented Jul 7, 2025

Alright. I had some issues getting the existing build workflow running without secrets, but the second to last commit in the unsquashed branch (https://github.com/AlleM43/sniffnet/tree/d2577161117d8361c483347430ad3ea1238f3744) is what ended up running the AppImage build to completion. It should work without those modifications as long as the deb builds.

@GyulyVGC GyulyVGC added this to the v1.4.1 milestone Jul 9, 2025
@GyulyVGC GyulyVGC added the packaging Application packaging label Jul 16, 2025
@GyulyVGC GyulyVGC added the Linux Something related to Linux operating system label Jul 24, 2025
@GyulyVGC GyulyVGC linked an issue Jul 24, 2025 that may be closed by this pull request
@GyulyVGC
Copy link
Owner

I noticed you're packaging it only for amd64... I'm wondering how AppImages are usually packed for different arch?
Would it be possible to also support at least aarch64 or arm64 or also 32-bit architectures? Would it make sense?

@AlleM43
Copy link
Contributor Author

AlleM43 commented Jul 24, 2025

I haven't really looked into that, partially because the only system I have with a DE installed is amd64, and partially because I thought it best to get amd64 working first and try to expand compatibility later. I can take a look at it though.

@GyulyVGC
Copy link
Owner

GyulyVGC commented Jul 24, 2025

Thanks.

Some other observations:

  • sniffnet.yml should be under the resources/packaging/linux folder
  • make sure the produced artifact name matches the style of other existing artefacts (Sniffnet_LinuxAppImage_arch.AppImage)
  • if it's possible, execute a test workflow on dispatch from your repo so we can test the produced artifact

@AlleM43
Copy link
Contributor Author

AlleM43 commented Aug 1, 2025

I've moved the yaml recipe and changed the artifact name.

https://github.com/AlleM43/sniffnet/actions/runs/16672113220 produced AppImages for amd64, i386, arm64, and armhf. I haven't tested running them, but I tested amd64 and i386 appimages built locally with the same recipe, and checked all executables and libraries in each AppDir to ensure they were for the correct platfor

I also changed cargo clean to be a separate step in order to deal with an issue I was having with cross. (cross-rs/cross#724)

@GyulyVGC
Copy link
Owner

GyulyVGC commented Aug 1, 2025

Thank you.

https://github.com/AlleM43/sniffnet/actions/runs/16672113220

Do you have any idea why the dmg and msi fail?

produced AppImages for amd64, i386, arm64, and armhf. I haven't tested running them, but I tested amd64 and i386 appimages built locally with the same recipe, and checked all executables and libraries in each AppDir to ensure they were for the correct platfor

Awesome, I'll also test at least the amd64.
If you could also directly test such artifacts it'd amazing.

I also changed cargo clean to be a separate step in order to deal with an issue I was having with cross. (cross-rs/cross#724)

I added that cargo clean exactly because I was having issues with cross IIRC... 🤨

@AlleM43
Copy link
Contributor Author

AlleM43 commented Aug 1, 2025

I disabled Windows and MacOS builds in my testing runs because Windows builds failed because of a lack of a secret and MacOS builds take too many GitHub Actions minutes. The one in the PR branch has those reenabled.

The cargo clean only ran when the tests were ran, which I also disabled to save time. Thus, I moved it to a separate step, to ensure it runs every time.

@GyulyVGC
Copy link
Owner

GyulyVGC commented Aug 1, 2025

Oh ok, then I guess I can move it back to the original place.

Again thanks so much for your time 🙌

@GyulyVGC GyulyVGC merged commit 575951d into GyulyVGC:main Aug 3, 2025
@GyulyVGC
Copy link
Owner

GyulyVGC commented Aug 3, 2025

@all-contributors please add @AlleM43 for platform.

@allcontributors
Copy link
Contributor

@GyulyVGC

I've put up a pull request to add @AlleM43! 🎉

@GyulyVGC
Copy link
Owner

GyulyVGC commented Aug 3, 2025

I've just tested the amd64 and it perfectly works.
Wow. AppImages are cool actually.

@GyulyVGC
Copy link
Owner

GyulyVGC commented Aug 4, 2025

I just had a doubt @AlleM43

Are we sure libpcap is the only needed dependency? See https://github.com/GyulyVGC/sniffnet/wiki/Required-dependencies

It may work on our systems if we already have the other dependencies installed, but not sure if it works in general...

@AlleM43
Copy link
Contributor Author

AlleM43 commented Aug 4, 2025

The other dependencies are part of those assumed by the pkg2appimage devs to be present on every system (see https://github.com/AppImageCommunity/pkg2appimage/blob/master/excludedeblist) and would thus not be installed anyway.

@GyulyVGC
Copy link
Owner

GyulyVGC commented Aug 4, 2025

Perfect 👌

@GyulyVGC
Copy link
Owner

Hey @AlleM43 some users reported a problem with the libpcap dependency when installing the AppImage.

Could you please check this thread: https://www.reddit.com/r/linux/s/x8lRJeJXCv

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature, request, or improvement Linux Something related to Linux operating system packaging Application packaging

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Package Sniffnet as AppImage

2 participants