Forum Discussion
Aug 02, 2022
Unable to update device cert
Hi!
Working on a hobby project to manage F5 certificates using Kubernetes and cert-manager (Ref: https://community.f5.com/t5/technical-forum/kubernetes-cert-manager-letsencrypt-f5/td-p/299218). How...
- Aug 07, 2022
Final solution:
def set_management_cert(self, cert_name, key_name): self.run_bash_command(f'restorecon -RvF /config/httpd/conf/ssl.crt/{cert_name}') self.run_bash_command(f'restorecon -RvF /config/httpd/conf/ssl.key/{key_name}') self.session.put( f'https://{self.device}/mgmt/tm/sys/httpd', json={ 'sslCertfile': '/config/httpd/conf/ssl.crt/management.crt', 'sslCertkeyfile': '/config/httpd/conf/ssl.key/management.key'} ) try: logger.info('Restarting httpd') self.run_bash_command('bigstart restart httpd; killall -9 httpd;bigstart restart httpd;') except: logger.info('Waiting for management interface to restart') time.sleep(3) httpd_config = self.get_httpd_config() if os.path.basename(httpd_config['sslCertfile']) == cert_name \ and os.path.basename(httpd_config['sslCertkeyfile']) == key_name: print('Certificate has been updated and the httpd interface is responding') else: raise Exception('Failed to update the certificate')
Thank you for the suggestions and tips Dario_Garrido . Definitely helped me find the solution!
Aug 04, 2022
Hello mate!
Looking forward to know more about your project. Are you planning a future article for this? 😊
Regarding your issue, never faced before, but I was wondering if tomcat daemon could be involved.
https://support.f5.com/csp/article/K03531511
- Aug 04, 2022
No article planned, but that was a good idea. Might write one if I can get it to work. 👍
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects