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

Move testflinger-server code to monorepo layout #131

Merged
merged 856 commits into from
Oct 20, 2023
Merged

Move testflinger-server code to monorepo layout #131

merged 856 commits into from
Oct 20, 2023

Conversation

plars
Copy link
Collaborator

@plars plars commented Oct 17, 2023

Description

This moves the testflinger-server code into the structure that we need for monorepo

Resolved issues

CERTTF-166 (partially)

Documentation

Docs directory already exists and was moved to the root of the monorepo along with the .readthedocs.yaml

Tests

In progress...

plars and others added 30 commits January 12, 2023 13:53
Fix changes requested by new version of black formatting
Improve handling of maas errors and a few more pylint cleanups
Remove currently unused logstash support
Fix a few use-dict-literal warnings from pylint
Break out code to update results from the phase from run_test_phase
Remove rpi3 device agent since we use muxpi instead now
Convert to using pyproject.toml for setup
@plars plars marked this pull request as ready for review October 19, 2023 13:56
@plars plars requested a review from a team October 19, 2023 13:56
Copy link
Collaborator

@jocave jocave left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bit of bike-shedding - I feel like the testflinger- prefix on all the component sub directories is redundant. Should we remove it?

@plars
Copy link
Collaborator Author

plars commented Oct 19, 2023

Bit of bike-shedding - I feel like the testflinger- prefix on all the component sub directories is redundant. Should we remove it?

Just to clarify, do you mean just from the directory name? For instance, things like "testflinger-agent" or especially the user facing "testflinger-cli" would be a little confusing if you executed them as just "agent" or "cli". So I think internally, keeping testflinger as part of the name is ok. I'm ok with removing it from the names of the directories if you think that looks cleaner though. The directory structure would then look like this:
/testflinger
/agent
/cli
/device-connectors
/server
...but the cmdline used to call them would still be the same as it was previously.
The is one small advantage I can see to keeping it as-is. We know the agent charm will need some modification. Each agent currently gets a dir on the agent host under /srv/testflinger/<agent_name>/... and under there, we have the git repo for testflinger-agent and snappy-device-agents. It would be nice to keep that mostly the same, although obviously the device agents dir is going to need to change. But I think I have a way of checking out the git repo so that only those two directories show up there, but we still get a shallow git tree, which can have the advantage of being able to update it later, pull other branches for testing, etc. It's a small thing but could be useful. I'm not stuck on it either way though if you have a preference.

@plars plars requested a review from jocave October 19, 2023 19:44
@jocave
Copy link
Collaborator

jocave commented Oct 20, 2023

Bit of bike-shedding - I feel like the testflinger- prefix on all the component sub directories is redundant. Should we remove it?

Just to clarify, do you mean just from the directory name? For instance, things like "testflinger-agent" or especially the user facing "testflinger-cli" would be a little confusing if you executed them as just "agent" or "cli". So I think internally, keeping testflinger as part of the name is ok. I'm ok with removing it from the names of the directories if you think that looks cleaner though. The directory structure would then look like this: /testflinger /agent /cli /device-connectors /server ...but the cmdline used to call them would still be the same as it was previously. The is one small advantage I can see to keeping it as-is. We know the agent charm will need some modification. Each agent currently gets a dir on the agent host under /srv/testflinger/<agent_name>/... and under there, we have the git repo for testflinger-agent and snappy-device-agents. It would be nice to keep that mostly the same, although obviously the device agents dir is going to need to change. But I think I have a way of checking out the git repo so that only those two directories show up there, but we still get a shallow git tree, which can have the advantage of being able to update it later, pull other branches for testing, etc. It's a small thing but could be useful. I'm not stuck on it either way though if you have a preference.

Yes, just meant the directory name

Copy link
Collaborator

@jocave jocave left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, looks good to me.

I think there is some cruft from old repositories (e.g. pmr-merge-hooks), but happy for the merge to proceed with what is in the source repos now and tidy these things up in later PRs.

@plars plars merged commit afd71a5 into main Oct 20, 2023
10 checks passed
@plars plars deleted the server-monorepo branch October 20, 2023 16:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants