Skip to content

Commit

Permalink
Deployed a4e0457 with MkDocs version: 1.5.3
Browse files Browse the repository at this point in the history
  • Loading branch information
programarivm committed Jul 30, 2024
1 parent d4f4925 commit 7bcd3d2
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 33 deletions.
23 changes: 8 additions & 15 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -122,25 +122,18 @@ <h1 id="website">Website</h1>
<h2 id="development-environment">Development Environment</h2>
<p>The following repositories are required to run a complete chess platform in a local development environment:</p>
<ul>
<li><a href="https://github.com/chesslablab/website">Website</a></li>
<li><a href="https://github.com/chesslablab/chess-server">PHP Chess Server</a></li>
<li><a href="https://github.com/chesslablab/chess-api">PHP Chess API</a></li>
<li><a href="https://github.com/chesslablab/chess-data">Chess Data</a></li>
<li><a href="https://github.com/chesslablab/website">Website</a> on port 443.</li>
<li><a href="https://github.com/chesslablab/chess-server">PHP Chess Server</a> on port 8443.</li>
<li><a href="https://github.com/chesslablab/chess-api">PHP Chess API</a> on port 9443.</li>
<li><a href="https://github.com/chesslablab/chess-data">Chess Data</a> on port 3306.</li>
</ul>
<p>The documentation examples are run using these ports for each of the repositories, respectively.</p>
<ul>
<li>443</li>
<li>8443</li>
<li>9443</li>
<li>3306</li>
</ul>
<p>Remember, this is because multiple applications can't listen on the same port on the same host. Finally make sure to add your API endpoint as well as your WebSocket host to your <code>assets/env.js</code> file.</p>
<p>This is because multiple applications can't listen on the same port on the same host. Remember to add your PHP Chess API endpoint and your PHP Chess Server host name to the <code>assets/env.js</code> file of your website.</p>
<h2 id="decentralized-environment">Decentralized Environment</h2>
<p>With decentralized chess (DeChess) a complete chess platform can be run using one ChesslaBlab repository only:</p>
<ul>
<li><a href="https://github.com/chesslablab/website">Website</a></li>
<li><a href="https://github.com/chesslablab/website">Website</a> on port 443.</li>
</ul>
<p>Make sure to add at least one API endpoint as well as a WebSocket host from the <a href="https://github.com/chesslablab#chesslablab-node-list">ChesslaBlab Node List</a> to your <code>assets/env.js</code> file.</p>
<p>Make sure to add at least a PHP Chess API endpoint and a PHP Chess Server host name from the <a href="https://github.com/chesslablab#chesslablab-node-list">ChesslaBlab Node List</a> to the <code>assets/env.js</code> file of your website.</p>

</div>
</div><footer>
Expand Down Expand Up @@ -189,5 +182,5 @@ <h2 id="decentralized-environment">Decentralized Environment</h2>

<!--
MkDocs version : 1.5.3
Build Date UTC : 2024-07-29 21:51:04.742250+00:00
Build Date UTC : 2024-07-30 09:03:25.148507+00:00
-->
2 changes: 1 addition & 1 deletion search/search_index.json

Large diffs are not rendered by default.

16 changes: 8 additions & 8 deletions sitemap.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,42 +2,42 @@
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
<loc>https://chesslablab.github.io/website/</loc>
<lastmod>2024-07-29</lastmod>
<lastmod>2024-07-30</lastmod>
<changefreq>daily</changefreq>
</url>
<url>
<loc>https://chesslablab.github.io/website/api-connection/</loc>
<lastmod>2024-07-29</lastmod>
<lastmod>2024-07-30</lastmod>
<changefreq>daily</changefreq>
</url>
<url>
<loc>https://chesslablab.github.io/website/blog/</loc>
<lastmod>2024-07-29</lastmod>
<lastmod>2024-07-30</lastmod>
<changefreq>daily</changefreq>
</url>
<url>
<loc>https://chesslablab.github.io/website/html-iframes/</loc>
<lastmod>2024-07-29</lastmod>
<lastmod>2024-07-30</lastmod>
<changefreq>daily</changefreq>
</url>
<url>
<loc>https://chesslablab.github.io/website/installation/</loc>
<lastmod>2024-07-29</lastmod>
<lastmod>2024-07-30</lastmod>
<changefreq>daily</changefreq>
</url>
<url>
<loc>https://chesslablab.github.io/website/ssl-certificate-setup/</loc>
<lastmod>2024-07-29</lastmod>
<lastmod>2024-07-30</lastmod>
<changefreq>daily</changefreq>
</url>
<url>
<loc>https://chesslablab.github.io/website/website-architecture/</loc>
<lastmod>2024-07-29</lastmod>
<lastmod>2024-07-30</lastmod>
<changefreq>daily</changefreq>
</url>
<url>
<loc>https://chesslablab.github.io/website/websocket-connection/</loc>
<lastmod>2024-07-29</lastmod>
<lastmod>2024-07-30</lastmod>
<changefreq>daily</changefreq>
</url>
</urlset>
Binary file modified sitemap.xml.gz
Binary file not shown.
29 changes: 20 additions & 9 deletions ssl-certificate-setup/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,15 @@
<ul class="current">
<li class="toctree-l1 current"><a class="reference internal current" href="./">SSL Certificate Setup</a>
<ul class="current">
<li class="toctree-l2"><a class="reference internal" href="#self-signed-wildcard-ssl-certificate-with-openssl">Self-Signed Wildcard SSL Certificate with OpenSSL</a>
<ul>
<li class="toctree-l3"><a class="reference internal" href="#conclusion">Conclusion</a>
<li class="toctree-l2"><a class="reference internal" href="#development-environment">Development Environment</a>
</li>
</ul>
<li class="toctree-l2"><a class="reference internal" href="#decentralized-environment">Decentralized Environment</a>
</li>
<li class="toctree-l2"><a class="reference internal" href="#free-ssl-certificate-with-certbot">Free SSL Certificate with Certbot</a>
</li>
<li class="toctree-l2"><a class="reference internal" href="#self-signed-ssl-certificate-with-openssl">Self-Signed SSL Certificate with OpenSSL</a>
</li>
<li class="toctree-l2"><a class="reference internal" href="#conclusion">Conclusion</a>
</li>
</ul>
</li>
Expand Down Expand Up @@ -104,6 +108,7 @@

<h1 id="ssl-certificate-setup">SSL Certificate Setup</h1>
<p>Some familiarity with Public Key Infrastructure (PKI) is recommended in order to follow this section.</p>
<h2 id="development-environment">Development Environment</h2>
<p>The first thing you need to understand about setting up a ChesslaBlab website in a local development environment is that you have to create an SSL certificate to secure four different domain names at once.</p>
<ul>
<li><code>chesslablab.org</code></li>
Expand All @@ -113,6 +118,7 @@ <h1 id="ssl-certificate-setup">SSL Certificate Setup</h1>
</ul>
<p>This is because nowadays, major browsers want all traffic to be secure, and as a web developer you want the development environment to mimic production as much as possible.</p>
<p>The first two domain names, <code>chesslablab.org</code> and <code>www.chesslablab.org</code>, will point to the IP of the <a href="https://github.com/chesslablab/website">website</a>. When it comes to websites, it is a common practice to create a domain alias that redirects to the primary domain. Hence the two domain names for the website, one starting with www. The <code>api.chesslablab.org</code> domain name will point to the IP of the <a href="https://github.com/chesslablab/chess-api">REST-like API</a> and <code>async.chesslablab.org</code> to the IP of the <a href="https://github.com/chesslablab/chess-server">asynchronous chess server</a>.</p>
<h2 id="decentralized-environment">Decentralized Environment</h2>
<p>In a decentralized environment only two domain names need to be secured.</p>
<ul>
<li><code>chesslablab.org</code></li>
Expand All @@ -123,7 +129,8 @@ <h1 id="ssl-certificate-setup">SSL Certificate Setup</h1>
<li><code>gmalice.com</code></li>
<li><code>www.gmalice.com</code></li>
</ul>
<p>Probably the easiest way to proceed is to purchase a wildcard certificate from a Certificate Authority (CA) however you may want to consider to get your free certificates using <a href="https://certbot.eff.org/">Certbot</a> instead. Be that as it may, keep in mind that before any CA can issue an SSL certificate, a validation process is required to verify that it can be sent to the Certificate Signing Request (CSR) requester.</p>
<h2 id="free-ssl-certificate-with-certbot">Free SSL Certificate with Certbot</h2>
<p>Probably the easiest way to proceed is to purchase a wildcard certificate from a Certificate Authority (CA) however you may want to consider to get your free certificate using <a href="https://certbot.eff.org/">Certbot</a> instead. Be that as it may, keep in mind that before any CA can issue an SSL certificate, a validation process is required to verify that it can be sent to the Certificate Signing Request (CSR) requester.</p>
<p>This is typically achieved through one of the following methods.</p>
<ul>
<li>
Expand Down Expand Up @@ -163,8 +170,8 @@ <h1 id="ssl-certificate-setup">SSL Certificate Setup</h1>
<li>chesslablab/chess-server</li>
</ul>
<p>It is worth saying that for this to function properly, Certbot's documentation recommends to have a working web site that can already be accessed using HTTP on port 80.</p>
<h2 id="self-signed-wildcard-ssl-certificate-with-openssl">Self-Signed Wildcard SSL Certificate with OpenSSL</h2>
<p>If issuing a wildcard certificate with DNS validation sounds too complicated to you, OpenSSL might be an alternate solution for the development environment. You may want to create a self-signed multi-domain SSL certificate using OpenSSL.</p>
<h2 id="self-signed-ssl-certificate-with-openssl">Self-Signed SSL Certificate with OpenSSL</h2>
<p>If issuing a certificate with DNS validation sounds too complicated to you, OpenSSL might be an alternate solution for the development environment. You may want to create a self-signed multi-domain SSL certificate using OpenSSL.</p>
<pre><code class="language-text">openssl genrsa -aes256 -passout pass:foobar -out chesslablab.org.pem 2048
openssl req -passin pass:foobar -new -sha256 -key chesslablab.org.pem -subj &quot;/C=US/ST=CA/O=ChesslaBlab, Inc./CN=chesslablab.org&quot; -reqexts SAN -config &lt;(cat /etc/ssl/openssl.cnf &lt;(printf &quot;[SAN]\nsubjectAltName=DNS:*.mydomain.org&quot;)) -out chesslablab.org.csr
openssl x509 -passin pass:foobar -req -days 365 -in chesslablab.org.csr -signkey chesslablab.org.pem -out chesslablab.org.crt
Expand Down Expand Up @@ -202,13 +209,17 @@ <h2 id="self-signed-wildcard-ssl-certificate-with-openssl">Self-Signed Wildcard
</code></pre>
<p><img alt="Figure 4" src="https://raw.githubusercontent.com/chesslablab/website/main/docs/ssl-certificate-setup_04.png" /></p>
<p><strong>Figure 4</strong>. The browser doesn't recognize the API's certificate.</p>
<h3 id="conclusion">Conclusion</h3>
<p>In order to run a ChesslaBlab website, a wildcard SSL certificate needs to be issued and installed in the following repos:</p>
<h2 id="conclusion">Conclusion</h2>
<p>In order to set up a local development environment, four different domain names need to be secured at once. The SSL certificate is to be installed in each of the following repositories.</p>
<ul>
<li>chesslablab/website</li>
<li>chesslablab/chess-api</li>
<li>chesslablab/chess-server</li>
</ul>
<p>In a decentralized environment only two domain names need to be secured. The SSL certificate is to be installed in the following repository.</p>
<ul>
<li>chesslablab/website</li>
</ul>
<p><a href="https://certbot.eff.org/">Certbot</a> can be used to automatically get a free HTTPS certificate, however, if this still sounds too complicated, OpenSSL might be an alternate solution for the development environment.</p>

</div>
Expand Down

0 comments on commit 7bcd3d2

Please sign in to comment.