1234567891011121314151617181920212223242526272829303132333435 |
- resource "tls_private_key" "key_pair" {
- algorithm = "RSA"
- rsa_bits = 4096
- }
- resource "aws_key_pair" "key_pair" {
- key_name = "dolphinscheduler"
- public_key = tls_private_key.key_pair.public_key_openssh
- }
- resource "local_file" "ssh_key" {
- filename = "${aws_key_pair.key_pair.key_name}.pem"
- content = tls_private_key.key_pair.private_key_pem
- file_permission = "0700"
- }
|