In Git you can add a submodule to a repository. This is basically a repository embedded in your main repository. This can be very useful. A couple of advantages of using submodules:
- You can separate the code into different repositories.
<figure> | |
<img src="{{ .Get `src` }}" alt="{{ .Get `alt` }}"> | |
<figcaption> | |
{{ .Inner }} | |
</figcaption> | |
</figure> |
-<VirtualHost *:80> | |
+<VirtualHost *:443> | |
DocumentRoot "/path/to/example.com" | |
ServerName example.com | |
+ SSLEngine on | |
+ SSLCertificateFile "/path/to/ssl.crt" | |
+ SSLCertificateKeyFile "/path/to/ssl.key" | |
# ... | |
</VirtualHost> |
sudo security add-trusted-cert \ | |
-d -r trustRoot \ | |
-k /Library/Keychains/System.keychain \ | |
/path/to/ssl.crt |
openssl req \ | |
-new \ | |
-newkey rsa:2048 \ | |
-sha1 \ | |
-days 3650 \ | |
-nodes \ | |
-x509 \ | |
-keyout ssl.key \ | |
-out ssl.crt \ | |
-config ssl.conf |
[req] | |
prompt = no | |
default_bits = 4096 | |
default_md = sha256 | |
distinguished_name = dn | |
x509_extensions = v3_req | |
[dn] | |
C=CN | |
ST=Shanghai |
<VirtualHost *:80> | |
DocumentRoot "/path/to/example.com" | |
ServerName example.com | |
# ... | |
</VirtualHost> | |
<VirtualHost *:80> | |
DocumentRoot "/path/to/example_another.com" | |
ServerName example_another.com | |
# ... |
certbot | |
certonly \ | |
--webroot \ | |
--agree-tos \ | |
--email [email protected] \ | |
--webroot-path /var/www/subdomain \ | |
--expand --domains subdomain.example.com |
certbot \ | |
certonly \ | |
--webroot \ | |
--agree-tos \ | |
--email [email protected] \ | |
--webroot-path /var/www/example.com --domains example.com | |
--webroot-path /var/www/subdomain1 --domains subdomain1.example.com | |
--webroot-path /var/www/subdomain2 --domains subdomain2.example.com |