HTTP 401 Unauthorized when uploading SSH key
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 25/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Cần làm rõ
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- ansible
- Lĩnh vực
- cloud, infrastructure
Hướng nghiên cứu
Tái hiện tác vụ “Ensure SSH keypairs are registered” và bắt đầu với module ansible_collections.openstack.cloud keypair được hiển thị trong traceback, đặc biệt là keypair.py và module_utils/openstack.py. Truy vết cấu hình xác thực liên quan đến request bị lỗi; được xem là hoàn tất khi tác vụ hoàn thành mà không có HTTP 401 và khóa SSH được cung cấp đã được đăng ký.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
If you provide an SSH key to assign to user it will fail with HTTP 401 Unauthorized.
TASK [stackhpc.openstack.os_projects : Ensure SSH keypairs are registered] ***************************************************************************************************************************************************************************************************************************
Friday 22 August 2025 12:53:56 +0000 (0:00:00.091) 0:00:20.321 *********
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: keystoneauth1.exceptions.http.Unauthorized: The request you have made requires authentication. (HTTP 401) (Request-ID: req-430ec8e6-8f20-483c-a0c8-1a791189b211)
failed: [localhost] (item=demo: id_ed25519) => changed=false
ansible_loop_var: item
item:
- description: OpenStack demo project
name: demo
project_domain: Default
quotas:
backup_gigabytes: -1
backups: -1
cores: -1
floatingip: -1
gigabytes: -1
injected_file_size: -1
injected_files: -1
instances: -1
key_pairs: -1
per_volume_gigabytes: -1
ram: -1
security_group: -1
security_group_rule: -1
snapshots: -1
volumes: -1
user_domain: Default
users:
- description: StackHPC Demo user
email: demo@stackhpc.com
name: demo
password: *****
roles:
- member
- reader
- name: id_ed25519
public_key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICKx4TMa8vtpOe3qHeMX4Z7JZyucBcqlfv8iFY6dZkzB
module_stderr: |-
Traceback (most recent call last):
File "/home/stack/.ansible/tmp/ansible-tmp-1755867236.4199255-709459-103411628663297/AnsiballZ_keypair.py", line 107, in <module>
_ansiballz_main()
File "/home/stack/.ansible/tmp/ansible-tmp-1755867236.4199255-709459-103411628663297/AnsiballZ_keypair.py", line 99, in _ansiballz_main
invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)
File "/home/stack/.ansible/tmp/ansible-tmp-1755867236.4199255-709459-103411628663297/AnsiballZ_keypair.py", line 47, in invoke_module
runpy.run_module(mod_name='ansible_collections.openstack.cloud.plugins.modules.keypair', init_globals=dict(_module_fqn='ansible_collections.openstack.cloud.plugins.modules.keypair', _modlib_path=modlib_path),
File "/usr/lib64/python3.9/runpy.py", line 225, in run_module
return _run_module_code(code, init_globals, run_name, mod_spec)
File "/usr/lib64/python3.9/runpy.py", line 97, in _run_module_code
_run_code(code, mod_globals, init_globals,
File "/usr/lib64/python3.9/runpy.py", line 87, in _run_code
exec(code, run_globals)
File "/tmp/ansible_openstack.cloud.keypair_payload_ve79l7iy/ansible_openstack.cloud.keypair_payload.zip/ansible_collections/openstack/cloud/plugins/modules/keypair.py", line 178, in <module>
File "/tmp/ansible_openstack.cloud.keypair_payload_ve79l7iy/ansible_openstack.cloud.keypair_payload.zip/ansible_collections/openstack/cloud/plugins/modules/keypair.py", line 174, in main
File "/tmp/ansible_openstack.cloud.keypair_payload_ve79l7iy/ansible_openstack.cloud.keypair_payload.zip/ansible_collections/openstack/cloud/plugins/module_utils/openstack.py", line 417, in __call__
File "/tmp/ansible_openstack.cloud.keypair_payload_ve79l7iy/ansible_openstack.cloud.keypair_payload.zip/ansible_collections/openstack/cloud/plugins/modules/keypair.py", line 140, in run
File "/home/stack/openstack-config/ansible/openstack-config-venv/lib64/python3.9/site-packages/openstack/service_description.py", line 89, in __get__
proxy = self._make_proxy(instance)
File "/home/stack/openstack-config/ansible/openstack-config-venv/lib64/python3.9/site-packages/openstack/service_description.py", line 289, in _make_proxy
found_version = temp_adapter.get_api_major_version()
File "/home/stack/openstack-config/ansible/openstack-config-venv/lib64/python3.9/site-packages/keystoneauth1/adapter.py", line 352, in get_api_major_version
return self.session.get_api_major_version(auth or self.auth, **kwargs)
File "/home/stack/openstack-config/ansible/openstack-config-venv/lib64/python3.9/site-packages/keystoneauth1/session.py", line 1289, in get_api_major_version
return auth.get_api_major_version(self, **kwargs)
File "/home/stack/openstack-config/ansible/openstack-config-venv/lib64/python3.9/site-packages/keystoneauth1/identity/base.py", line 497, in get_api_major_version
data = get_endpoint_data(discover_versions=discover_versions)
File "/home/stack/openstack-config/ansible/openstack-config-venv/lib64/python3.9/site-packages/keystoneauth1/identity/base.py", line 268, in get_endpoint_data
service_catalog = self.get_access(session).service_catalog
File "/home/stack/openstack-config/ansible/openstack-config-venv/lib64/python3.9/site-packages/keystoneauth1/identity/base.py", line 131, in get_access
self.auth_ref = self.get_auth_ref(session)
File "/home/stack/openstack-config/ansible/openstack-config-venv/lib64/python3.9/site-packages/keystoneauth1/identity/generic/base.py", line 205, in get_auth_ref
return self._plugin.get_auth_ref(session, **kwargs)
File "/home/stack/openstack-config/ansible/openstack-config-venv/lib64/python3.9/site-packages/keystoneauth1/identity/v3/base.py", line 185, in get_auth_ref
resp = session.post(token_url, json=body, headers=headers,
File "/home/stack/openstack-config/ansible/openstack-config-venv/lib64/python3.9/site-packages/keystoneauth1/session.py", line 1162, in post
return self.request(url, 'POST', **kwargs)
File "/home/stack/openstack-config/ansible/openstack-config-venv/lib64/python3.9/site-packages/keystoneauth1/session.py", line 985, in request
raise exceptions.from_response(resp, method, url)
keystoneauth1.exceptions.http.Unauthorized: The request you have made requires authentication. (HTTP 401) (Request-ID: req-430ec8e6-8f20-483c-a0c8-1a791189b211)
module_stdout: ''
msg: |-
MODULE FAILURE
See stdout/stderr for the exact error
rc: 1
- Ngôn ngữ chính
- Jinja
- Star
- 5
- Fork
- 8
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của stackhpc/openstack-config
-
KeyError when assigning quotas Đang mởbug
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 52/100
stackhpc/openstack-config#58 ·
-
enhancement magnum
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 45/100
stackhpc/openstack-config#37 ·
Tất cả issue của stackhpc/openstack-config
Issue tương tự
-
Language: Terraform :globe_with_meridians: Needs: Triage :mag: Type: Bug :bug:
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
Azure/terraform-azurerm-avm-res-containerregistry-registry#230 · 1 bình luận ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
-
level/task module/gcp type/bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100