sshd_config file resets when creating a container

dxomgmyfriend

New Member
Aug 12, 2022
7
0
1
Hello! I'm new here but I'd like to know if there is any fix for this, I have this issue, I modified some templates and noticed that the sshd_config file resets every time you create a new container, thanks in regards.
 
I just tested it and it's not the case for me, maybe your container does that? What changed in the file?
I mean when i change it in the TEMPLATE not in the already deployed container
the only thing that i changed was the #PermitRootLogin Section
 
Last edited:
Could you descibe more what's your problem? It's very unspecific and already established, that the file is not changed for my templates, so please share what type of guest os this is and what the setting PermitRootLogin changed from/to.
 
Last edited:
Could you descibe more what's your problem?
1 OP has lxc running and changes option in /etc/ssh/sshd_config
2 OP makes new template of lxc
3 OP deploys new lxc using said template
4 change from 1 is nor reflected in new lxc
 
1 OP has lxc running and changes option in /etc/ssh/sshd_config
2 OP makes new template of lxc
3 OP deploys new lxc using said template
4 change from 1 is nor reflected in new lxc
Thank you for clearing that up, yet I still stand by my #4 comment. It works for me:

1) used a Debian Bullseye image, created a container
2) I changed the default #PermitRootLogin prohibit-password to PermitRootLogin yes
3) converted the container to a template
4) cloned the template (not creating a new container with a container template!) and started the newly created container
5) Looked at the sshd_config and my change is still present.
 
Thank you for clearing that up, yet I still stand by my #4 comment. It works for me:

1) used a Debian Bullseye image, created a container
2) I changed the default #PermitRootLogin prohibit-password to PermitRootLogin yes
3) converted the container to a template
4) cloned the template (not creating a new container with a container template!) and started the newly created container
5) Looked at the sshd_config and my change is still present.
I guess i'll have to double check
the way i do the template is by backups
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!