查询镜像
podman search mongo
![在这里插入图片描述](https://img-blog.csdnimg.cn/direct/e1239ad3657945caacba6d761e2364fb.png)
拉取镜像
podman pull docker.io/library/mongo
![在这里插入图片描述](https://img-blog.csdnimg.cn/direct/0edb87cf70594b1fa91fe733e6684804.png)
查看镜像
podman images
![在这里插入图片描述](https://img-blog.csdnimg.cn/direct/22ea1e751cac4432bf45f581531b69ec.png)
运行容器
podman run -d -p 27017:27017 --name=mongodb-test docker.io/library/mongo
![在这里插入图片描述](https://img-blog.csdnimg.cn/direct/ab1fd3f40b74420f91db1358542383c5.png)
创建root用户
podman exec -it mongodb-test mongosh
![在这里插入图片描述](https://img-blog.csdnimg.cn/direct/41750be70925416394c305993a6fc67f.png)
use admin
db.createUser({user:'root',pwd:'1234',roles:[{role:'root',db:'admin'}]})
![在这里插入图片描述](https://img-blog.csdnimg.cn/direct/eac7a258142342d5983514b2ec250824.png)