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

Ensure the remote connection using simplestreams is valid before adding it #12442

Merged

Conversation

gabrielmougard
Copy link
Contributor

closes #12414

test/suites/remote.sh Outdated Show resolved Hide resolved
lxc/remote.go Outdated Show resolved Hide resolved
…reams remote

Signed-off-by: Gabriel Mougard <gabriel.mougard@canonical.com>
Signed-off-by: Gabriel Mougard <gabriel.mougard@canonical.com>
@tomponline tomponline merged commit e03a9ab into canonical:main Oct 24, 2023
26 checks passed
# a connectivity issue returns an error
! lxc_remote remote add ubuntu1 https://cloud-images.ubuntu.com:1234/releases --protocol=simplestreams
# a malformed url path returns an error
! lxc_remote remote add ubuntu2 https://cloud-images.ubuntu.com/buildd/releases/ --protocol=simplestreams --public
Copy link
Member

Choose a reason for hiding this comment

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

If the issue is the trailing "/", I would update the comment to say that trailing "/" are not permitted, rather than it being a malformed URL.

Copy link
Member

Choose a reason for hiding this comment

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

Ive not had time to debug it much, but that line is one of the issues.

The other thing is that it broke adding valid simplestreams URLs without --public being specified as it then treated them as LXD image servers.

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.

lxc remote add --protocol=simplestreams doesn't test connectivity until the remote is actually used
3 participants