Why do you need Python virtual environment? Because we don't want to messed up Python installed with the MacOS.
- Of course you are a Python Developer.
- Work with multiple Python versions.
- Work with multiple Python projects.
| # | |
| # This is the "master security properties file". | |
| # | |
| # An alternate java.security properties file may be specified | |
| # from the command line via the system property | |
| # | |
| # -Djava.security.properties=<URL> | |
| # | |
| # This properties file appends to the master security properties file. | |
| # If both properties files specify values for the same key, the value |
| user root; | |
| worker_processes auto; | |
| error_log /var/log/nginx/error.log warn; | |
| pid /var/run/nginx.pid; | |
| events { | |
| worker_connections 1024; | |
| } |
| import requests | |
| class SendGrid: | |
| def __init__(self, **kwargs): | |
| self.api_key: str = kwargs.get('api_key') | |
| self.subject: str = kwargs.get('subject') | |
| self.sender: str = kwargs.get('sender') | |
| self.receivers: [str] = kwargs.get('receivers') | |
| self.content_type: str = kwargs.get('content_type', 'text/plain') |
| >>> from ldap3 import Server, Connection, ALL | |
| >>> server = Server('localhost', get_info=ALL) | |
| >>> conn = Connection(server, 'cn=admin,dc=codium,dc=com', 'codium123', auto_bind=True) | |
| >>> conn.search('dc=codium,dc=com', '(objectclass=person)') | |
| True | |
| >>> conn.entries | |
| [DN: cn=Htet Naing Aung,ou=people,dc=codium,dc=com - STATUS: Read - READ TIME: 2016-12-27T21:23:11.662103 | |
| , DN: cn=Than Htike Aung,ou=people,dc=codium,dc=com - STATUS: Read - READ TIME: 2016-12-27T21:23:11.662241 | |
| ] | |
| >>> conn.add('cn=Noark,ou=people,dc=codium,dc=com', ['inetOrgPerson', 'organizationalPerson', 'person', 'top'], {'cn': 'Norak', 'sn': 'Khath', 'mail': '[email protected]'}) |