Skip to content

Instantly share code, notes, and snippets.

@bitmand
Last active December 20, 2017 13:51
Show Gist options
  • Star 7 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save bitmand/c6b7332214d858130c52 to your computer and use it in GitHub Desktop.
Save bitmand/c6b7332214d858130c52 to your computer and use it in GitHub Desktop.
Salt Stack state for creating a uniq 2048-bit diffie hellman group
# Create a unique 2048 Diffie Hellman group
# https://weakdh.org
/etc/ssl/dhparams.pem:
cmd.run:
- name: openssl dhparam -out /etc/ssl/dhparams.pem 2048
- unless: test -f /etc/ssl/dhparams.pem
@ajdexter
Copy link

Thanks for posting this. Was just working on this myself :)

Copy link

ghost commented Apr 21, 2016

Any special reason for doing - unless: test -f /etc/ssl/dhparams.pem instead of - creates: /etc/ssl/dhparams.pem, or are they completely equivalent?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment