启动ansible在Ubuntu 20.10节点安装服务
ansible-playbook -i ./hosts inventory/nginx.yml
提示错误: E: Package 'python-apt' has no installation candidate
Ubuntu 20.10移除了python2环境
ansible host文件中添加以下内容
ansible_python_interpreter=/usr/bin/python3
再重试,问题解决。