Merged
Conversation
This commit introduces a new GitHub Actions workflow job, `snap-test`, to automate the building, installation, and testing of the xTeVe snap. The `snap-test` job performs the following actions: - Builds the snap using `snapcraft`. - Installs the built snap locally on the runner. - Waits for 10 seconds to allow the xTeVe service to start. - Checks if the `xteve` service is active. - Dumps the service logs (`snap logs xteve`) to STDOUT for debugging. If the service is not found to be active after installation, the CI job will fail, ensuring that issues with the snap packaging or service startup are caught early.
This commit introduces a GitHub Actions workflow job (`snap-test`) for building, installing, and testing the xTeVe snap. The `snap-test` job includes the following operations: - Builds the snap using `snapcraft`. - Installs the snap on the CI runner. - Waits for the service to start. - Verifies that the `xteve` service is active. - Dumps service logs to STDOUT. Additionally, this commit adds a new markdown file `.github/workflows/SNAP_CI_EXPECTED_OUTPUT.md`. This document details the expected console output for the key commands within the `snap-test` CI job, serving as a reference for developers and you.
This commit fixes the installation method for snapcraft and LXD in the
`snap-test` GitHub Actions workflow job.
The previous method used `apt-get` for these tools, which failed as
they are primarily distributed as snaps.
Changes include:
- Modified `.github/workflows/ci.yml`:
- `snapcraft` is now installed via `sudo snap install snapcraft --classic`.
- `lxd` is now installed via `sudo snap install lxd`.
- `qemu-kvm` is added as an explicit apt dependency.
- Ensured LXD group creation and user addition to the group.
- Updated `.github/workflows/SNAP_CI_EXPECTED_OUTPUT.md`:
- Reflected the new installation commands and added a section for
LXD group configuration.
These changes should resolve the package installation errors encountered
in the CI environment.
This commit updates the snap CI build process to use
`sudo snapcraft --destructive-mode`.
This change is intended to resolve network access issues encountered
when snapcraft attempts to build within an LXD container in the
CI environment. Building with `--destructive-mode` runs the build
directly on the host, which can bypass such networking problems.
Changes:
- Modified `.github/workflows/ci.yml`:
- The "Build the snap" step now uses `sudo snapcraft --destructive-mode`
instead of `sg lxd -c "snapcraft"`.
- Updated `.github/workflows/SNAP_CI_EXPECTED_OUTPUT.md`:
- Reflected the new snapcraft command and added a note explaining
`--destructive-mode`.
This commit fixes the service name verification in the snap CI job.
The `snap services xteve` command outputs the service as `xteve.xteve`,
but the previous pattern was looking for `xteve`.
Changes:
- Modified `.github/workflows/ci.yml`:
- The command in the "Check service status and dump logs" step
now correctly uses the pattern `^xteve\.xteve\s+.*active` to
match the actual service name.
- Updated `.github/workflows/SNAP_CI_EXPECTED_OUTPUT.md`:
- Reflected the corrected service name in the example output and
the command.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.