Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Mattermost to v10.3.1 #1948

Merged
merged 1 commit into from
Dec 18, 2024
Merged

Conversation

al-lac
Copy link
Contributor

@al-lac al-lac commented Dec 18, 2024

Tested update and install on Raspberry Pi 5 and Umbrel Home.

Copy link

🎉   Linting finished with no errors or warnings   🎉

Thank you for your submission! This is an automated linter that checks for common issues in pull requests to the Umbrel App Store.

Please review the linting results below and make any necessary changes to your submission.

Linting Results

Severity File Description
ℹ️ mattermost/docker-compose.yml External port mapping "8443:8443/tcp":
Port mappings may be unnecessary for the app to function correctly. Docker's internal DNS resolves container names to IP addresses within the same network. External access to the web interface is handled by the app_proxy container. Port mappings are only needed if external access is required to a port not proxied by the app_proxy, or if an app needs to expose multiple ports for its functionality (e.g., DHCP, DNS, P2P, etc.).
ℹ️ mattermost/docker-compose.yml External port mapping "8443:8443/udp":
Port mappings may be unnecessary for the app to function correctly. Docker's internal DNS resolves container names to IP addresses within the same network. External access to the web interface is handled by the app_proxy container. Port mappings are only needed if external access is required to a port not proxied by the app_proxy, or if an app needs to expose multiple ports for its functionality (e.g., DHCP, DNS, P2P, etc.).

Legend

Symbol Description
Error: This must be resolved before this PR can be merged.
⚠️ Warning: This is highly encouraged to be resolved, but is not strictly mandatory.
ℹ️ Info: This is just for your information.

@nmfretz
Copy link
Contributor

nmfretz commented Dec 18, 2024

Excellent. Thanks for this @al-lac. Tested and working great.

image

Shall I add Mattermost to the list of apps that our auto-update script will update? Or would you rather keep doing them manually?

@nmfretz nmfretz merged commit 9b60535 into getumbrel:master Dec 18, 2024
1 check passed
@al-lac al-lac deleted the mattermost-10-3-1 branch December 18, 2024 01:15
@al-lac
Copy link
Contributor Author

al-lac commented Dec 18, 2024

Great, thanks for testing as well! :-)

Feel free to add it to the auto-update script. Is the script / action also open source? Would be really interesting to see how you automatically deploy and screenshot an app.

@nmfretz
Copy link
Contributor

nmfretz commented Dec 18, 2024

Feel free to add it to the auto-update script.

Great, I've added it!

Is the script / action also open source? Would be really interesting to see how you automatically deploy and screenshot an app.

Ah, it's just code I have locally on my computer at the moment. It's in a bit of a hacky state as I tweak/modify it to get it to be even more automated. I haven't touched it in quite a long time, so will need to improve and clean things up.

But at a high level this is what it does:

  • Checks for a new version of the app by fetching latest version from GitHub and comparing against current version in the umbrel-app.yml. I've got some logic to deal with tags and versions... for example, we want to grab the latest version if available and not use a pre-release. Also fetches release notes.

  • Uses AI to analyze the release notes and compose files and identify which Docker images need updating.

  • Checks that the identified images we're updating to support both linux/amd64 and linux/arm64 architectures (I'm using mplatform/mquery as a super easy way to do this) and fetches the verified digests.

  • Uses AI to update the docker-compose.yml and umbrel-app.yml files. This is the trickiest part and relies on good prompting. You'll see by the completed updates in this repo that I now usually don't need to make edits, but occasionally do when it can't grab the right image for some reason or it adds some irrelevant release note point, etc.

  • Creates a new local branch, commits changes, creates a remote PR.

  • Installs the app in an umbrel-dev instance, verifies that the app was installed, tests the UI accessibility, and then uses a headless browser to take a screenshot of the UI. Then it adds these testing results to the PR.

Overall, this allows me to focus on testing and checking the release notes for breaking changes instead of getting bogged down in manually making the update. The auto-tester gives me the "fresh install" test that I can quickly verify because it will be freshly installed in my umbrel-dev instance. And then I can focus on testing that an app update persists data, etc.

I haven't updated this table in a bit, but here's a rough look at how many apps the updater-script is "responsible" for:

 * Update Process for Maintained Apps (141 total):
 * +------------------------------------------------+-------+-------+
 * | Update Method                                  | Count |     % |
 * +------------------------------------------------+-------+-------+
 * | Maintained by app developer                    |    35 |  25%  |
 * | Updateable via script without manual input     |    76 |  54%  |
 * | Updateable via script with manual input        |    22 |  16%  |
 * | Maintained by Umbrel (development work needed) |     8 |   6%  |
 * +------------------------------------------------+-------+-------+
 *

For the update script to work without intervention the app's github repo must have (1) tags and (2) release notes. If they don't have both of these then they fall under the Updateable via script with manual input category where I pass in version and raw release notes via the command line when running the update script.

@al-lac
Copy link
Contributor Author

al-lac commented Dec 18, 2024

Wow, really nice workflow! 🚀

I thought that those release notes maybe are refined by AI 😁

I guess with some effort most of it could be done via GitHub Actions, so it is not dependent on a local machine. But not sure how the umbrel-dev tests and so on would work there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants