<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Francisco Paul Sotelo Rocha</title>
    <description>The latest articles on DEV Community by Francisco Paul Sotelo Rocha (@ravehunter05).</description>
    <link>https://dev.to/ravehunter05</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F302153%2F516b8cd0-21da-4e40-9694-4f7e5c91aca3.png</url>
      <title>DEV Community: Francisco Paul Sotelo Rocha</title>
      <link>https://dev.to/ravehunter05</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ravehunter05"/>
    <language>en</language>
    <item>
      <title>How to host another page in digital ocean (nginx), with SSL for free (the easy way)</title>
      <dc:creator>Francisco Paul Sotelo Rocha</dc:creator>
      <pubDate>Thu, 10 Sep 2020 06:37:55 +0000</pubDate>
      <link>https://dev.to/ravehunter05/how-to-host-another-page-in-digital-ocean-nginx-with-ssl-for-free-the-easy-way-497c</link>
      <guid>https://dev.to/ravehunter05/how-to-host-another-page-in-digital-ocean-nginx-with-ssl-for-free-the-easy-way-497c</guid>
      <description>&lt;h2&gt;
  
  
  1) Create a folder for every web page in /var/www
&lt;/h2&gt;

&lt;p&gt;To go to /var/www you got to write these lines:&lt;br&gt;
cd ..&lt;br&gt;
cd var/www&lt;/p&gt;

&lt;p&gt;In my case i have a folder named html, inside of html y have 3 folders for three different websites i'm hosting, and an index.html that comes for default with nginx&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Liy7DbRu--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/ob3vohp5ekmm088ef1uf.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Liy7DbRu--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/ob3vohp5ekmm088ef1uf.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  2) Locate the index.html of your project
&lt;/h2&gt;

&lt;p&gt;Yes index with lowercase, not UPPERCASE or something like that, this thing is case sensitive..., in my case my index.html is right here:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--zGaHro6Q--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/hw7t50kxaztp6mp9uyvl.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--zGaHro6Q--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/hw7t50kxaztp6mp9uyvl.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;you can see the route by writing pwd and then press enter&lt;/p&gt;

&lt;h2&gt;
  
  
  3) Copy the route
&lt;/h2&gt;

&lt;p&gt;Just copy the route you obtained with pwd&lt;/p&gt;

&lt;h2&gt;
  
  
  4) Go to sites-available
&lt;/h2&gt;

&lt;p&gt;cd&lt;br&gt;
cd ..&lt;br&gt;
cd etc/nginx/sites-available&lt;/p&gt;

&lt;p&gt;right here for default you have a file named default&lt;/p&gt;

&lt;h2&gt;
  
  
  5) Modify default
&lt;/h2&gt;

&lt;p&gt;you got to modify the file named default, so write this:&lt;br&gt;
vim default&lt;br&gt;
(i use vim, i don't like nano, i'm kind of rebel, don't judge me)&lt;/p&gt;

&lt;h2&gt;
  
  
  6) Add server block:
&lt;/h2&gt;

&lt;p&gt;right here you're gonna see something like this:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--kaDpfexG--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/7uesqs5317btxemx4e63.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--kaDpfexG--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/7uesqs5317btxemx4e63.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;so, after the first&lt;br&gt;
server{&lt;/p&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;write something like this:&lt;/p&gt;

&lt;p&gt;server{&lt;br&gt;
listen 80;&lt;br&gt;
listen [::] 80;&lt;/p&gt;

&lt;p&gt;example example.com (example is just an example, right here you need to write your domain)&lt;/p&gt;

&lt;p&gt;root /var/www/example.com (another example, here you need to add the route you just copied with pwd in the 3rd part of this thing)&lt;/p&gt;

&lt;p&gt;index index.html (yes, i told you, don't use Index.html, or something like that, that's gonna crash your site)&lt;/p&gt;

&lt;p&gt;location / {&lt;br&gt;
try_files $uri $uri =404;&lt;br&gt;
} (for prevent errors)&lt;br&gt;
}&lt;/p&gt;

&lt;h2&gt;
  
  
  7) Get out of vim
&lt;/h2&gt;

&lt;p&gt;it's not that hard, just press scape, then write :x!, to save the changes you just made&lt;/p&gt;

&lt;h2&gt;
  
  
  8) Test
&lt;/h2&gt;

&lt;p&gt;Try, that's the way of the jedi (or maybe the way of the sith, you just test it)&lt;/p&gt;

&lt;p&gt;sudo nginx -t&lt;/p&gt;

&lt;p&gt;you should see something like this in the case you don't have any mistake&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--TV6vMEPa--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/dqfhchnd4cogz4t8fmpz.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--TV6vMEPa--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/dqfhchnd4cogz4t8fmpz.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  9) Install CERTBOT
&lt;/h2&gt;

&lt;p&gt;In the case you don't have certbot you shall install it, this is a guide for install it:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.digitalocean.com/community/tutorials/how-to-secure-nginx-with-let-s-encrypt-on-ubuntu-16-04"&gt;https://www.digitalocean.com/community/tutorials/how-to-secure-nginx-with-let-s-encrypt-on-ubuntu-16-04&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  10) Add SSL to your webpage
&lt;/h2&gt;

&lt;p&gt;sudo certbot --nginx -d example.com -d &lt;a href="http://www.example.com"&gt;www.example.com&lt;/a&gt; (again, example is only an example, this is the name of your the name)&lt;br&gt;
this domain should be the same domain you wrote in the block you just wrote, then press 2 because you don't want people in your website not using HTTPS.&lt;/p&gt;

&lt;p&gt;And that's all!! Hope it can be usefull&lt;/p&gt;

</description>
      <category>programming</category>
      <category>host</category>
      <category>devops</category>
      <category>python</category>
    </item>
    <item>
      <title>How to add featured image to a new wordpress theme</title>
      <dc:creator>Francisco Paul Sotelo Rocha</dc:creator>
      <pubDate>Fri, 04 Sep 2020 00:48:06 +0000</pubDate>
      <link>https://dev.to/ravehunter05/how-to-add-featured-image-to-a-new-wordpress-theme-4dp7</link>
      <guid>https://dev.to/ravehunter05/how-to-add-featured-image-to-a-new-wordpress-theme-4dp7</guid>
      <description>&lt;h2&gt;
  
  
  &lt;strong&gt;1) Add featured image setting on functions.php&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;function theme_post_thumbnails() {&lt;br&gt;
    add_theme_support( 'post-thumbnails' );&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;add_action( 'after_setup_theme', 'theme_post_thumbnails' );&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;2) Add the feature image to your post&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Scu68Zoe--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/fvaj647g3bdeag531ian.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Scu68Zoe--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/fvaj647g3bdeag531ian.png" alt="Featured image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;3) Add the image to your single posts&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Here you have to go to single.php, or create that file in the case that you don't have it, and here write something like this:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--oWtHW218--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/pi2clqmkma6mxsxqh8sx.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--oWtHW218--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/pi2clqmkma6mxsxqh8sx.png" alt="Code post"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;4) Now go to your post, and... thats all!&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--DR54C4LW--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/ar0pkqzlsoj75s46ra0c.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--DR54C4LW--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/ar0pkqzlsoj75s46ra0c.png" alt="Post result"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Sayonara&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
