teleren/devto huggingface dataset:
Commands to check your technical debt in Laravel
Tags: beginners, php, laravel
Published: 2021-04-26 17:52:17

The core command here is:

```
grep -nr -e '@urgent' -e '@todo' -e '@fixme'  resources app
 
    -e Designates a pattern to find
    -n Shows the line number
    -r Recursively through directories

    List as many directories in sequence to iterate through
```

I've added it to composer as a script called "debt":

```
"debt": [
    "grep -nr -e '@urgent' -e '@todo' -e '@fixme'  resources app"
],
```

Then you can run something like:

``` 
composer debt


app/Utility/Film.php:39:     * @todo Swap out with a regex
app/Utility/Media.php:161:     * @todo we have to make sure we kill the webp as well
app/Utility/Media.php:189:     * @todo move this to a utility class like we did for Utility/Media
app/Utility/Media.php:592:        // @flag @urgent the `getCommonColors` function is slow
```


You could also use it in `package.json` like:

```
"scripts": {
    "debt": "grep -nr -e '@urgent' -e '@todo' -e '@fixme'  resources app"
}

...

    npm run debt
```
From DevOps to NoOps using EngineYard Kontainers
Tags: devops, noops, containers, kubernetes
Published: 2021-04-26 17:44:49

---
title: From DevOps to NoOps using EngineYard Kontainers
published: true
description: Adopting DevOps, Containers, and Kubernetes can create a void of a sizable learning curve and an investment of time and resources for organizations.
tags: DevOps, NoOps, Containers, Kubernetes
//cover_image: https://direct_url_to_image.jpg
---
{% youtube kigeLpect5E %}

NoOps is the next paradigm after DevOps. Adopting DevOps, Containers, and Kubernetes can create a void of a sizable learning curve and an investment of time and resources for organizations. This video helps you understand how the emerging NoOps paradigm seeks to fill this void by creating an ideal model for best-in-class operations that frees developers from managing complex infrastructure and reduces the overall operational burden.

Also, check out how NoOps comes to life using the EngineYard Kontainers platform.
 
Here’s an informative blog on how NoOps, using EngineYard Kontainers, can eliminate operation burden. 

https://blog.engineyard.com/engine-yard-kontainers-and-noops

For more educational videos, subscribe to our YouTube channel!: https://www.youtube.com/channel/UCqHOhcKo3_6ZrwLSaGSNB3Q

To learn more about Engine Yard, visit us at: https://www.engineyard.com/

Start a FREE Trial: https://signup.ey.io/?_ga=2.121519880.1492935871.1618809944-1889314230.1617702708
The Emerging Case For Containers
Tags: aws, paas, noops, devops
Published: 2021-04-26 17:41:43

---
title: The Emerging Case For Containers
published: true
description: we will look into virtual machines and containers' journey, starting from the first commercially successful form of virtualization to virtual box to AWS cloud to the emergence of containers.
tags: AWS, PaaS, NoOps, DevOps
//cover_image: https://direct_url_to_image.jpg
---
{% youtube m6mw41y0BXk %}

In this video, we will look into virtual machines and containers' journey, starting from the first commercially successful form of virtualization to virtual box to AWS cloud to the emergence of containers.

Containers have hugely risen in popularity, and they are a compelling virtualization technology for many use cases, and rightfully so, there's a really good reason why we need containers. Learn all about containers, their scalability, flexibility, and why containers should be a part of your overall technology solutions in this current age.

EngineYard Kontainers provides a container-based Platform-as-a-Service (PaaS) that easily allows you to manage and deploy applications on AWS.

To learn more about Engine Yard Kontainers and NoOps, check out our detailed blog: https://blog.engineyard.com/engine-yard-kontainers-and-noops

For more educational videos, subscribe to our YouTube channel!: https://www.youtube.com/channel/UCqHOhcKo3_6ZrwLSaGSNB3Q

Visit us at: https://www.engineyard.com/

Start a FREE Trial: https://signup.ey.io/?_ga=2.121519880.1492935871.1618809944-1889314230.1617702708
Video: Migrating Applications From Engine Yard Cloud to Kontainers
Tags: ruby, php, node, devops
Published: 2021-04-26 17:37:39

---
title: Video: Migrating Applications From Engine Yard Cloud to Kontainers
published: true
description: In this episode, we’ll see how to migrate your applications from Engine Yard Cloud (EYC) to Engine Yard Kontainers
tags: Ruby, PHP, NodeJS, DevOps
//cover_image: https://direct_url_to_image.jpg
---
{% youtube KHeZCJ1bw7s %}

In this episode, we’ll see how to migrate your applications from Engine Yard Cloud (EYC) to Engine Yard Kontainers (EYK).

This is not a typical upgrade; instead, it is a paradigm shift because we move from virtual machines as the underlying compute capacity to containers, which is a real game-changer. We show you how you can gain better scalability and resource utilization using Engine Yard Kontainers (EYK).

Engine Yard Kontainers (EYK) is the second-generation Platform-as-a-Service (PaaS) for hosting Ruby-on-Rails, PHP, and NodeJS applications.

Check out our blog on Migrating from Engine Yard Cloud to Kontainers:
https://support.cloud.engineyard.com/hc/en-us/articles/1260801336010-Migrating-from-Engine-Yard-Cloud-to-Kontainers

Visit us at: https://www.engineyard.com/

Learn more insightful updates on various topics at our blog section: https://www.devgraph.com/blog/ 

For more educational videos, subscribe to our YouTube channel!: https://www.youtube.com/channel/UCqHOhcKo3_6ZrwLSaGSNB3Q

Start a FREE Trial: https://signup.ey.io/?_ga=2.121519880.1492935871.1618809944-1889314230.1617702708
Video: Your First Container Application using AWS ECS and Fargate
Tags: aws, ecs, fargate, ruby
Published: 2021-04-26 17:35:09

---
title: Video: Your First Container Application using AWS ECS and Fargate
published: true
description: In this video segment, we’ll show you how to deploy your very first container on AWS in just five minutes.
tags: AWS, ECS, Fargate, Ruby
//cover_image: https://direct_url_to_image.jpg
---
{% youtube sF-AP-_K4yQ %}

In this video segment, we’ll show you how to deploy your very first container on AWS in just five minutes.

In this step-by-step process video, you will learn:
• How to deploy your first application container on AWS Elastic Container Service (ECS) and Fargate
• How to deploy a Ruby-on-Rails application in GitHub using containers on the cloud
• How a Platform-as-a-Service (PaaS) such as Engine Yard Kontainers (EYK) dramatically simplifies this process
• How Engine Yard Kontainer (EYK) empowers lean, agile development teams to leverage container technology while remaining focused on their application rather than undifferentiated heavy lifting 

Learn more insightful updates on various topics at our blog section: https://www.devgraph.com/blog/ 

For more educational videos, subscribe to our YouTube channel!: https://www.youtube.com/channel/UCqHOhcKo3_6ZrwLSaGSNB3Q

Visit us at: https://www.engineyard.com/

Start a FREE Trial: https://signup.ey.io/?_ga=2.121519880.1492935871.1618809944-1889314230.1617702708
Custom domain for Pay-As-You-Go Azure App Service
Tags: azure, appservice, payasyougo
Published: 2021-04-26 17:13:03

Having your application deployed to AppService in Azure with cheapest AppService Plan you are not allowed to customize your domain. Here I will show you how you can quickly overcome it with your own server.
![image](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/d5bacgpvuhnk3yb2su5j.png)

# Prerequisites:
* Having server accessible via SSH constantly running.
* SSL certificates generated. 

    > (NOTE: You can easily generate your SSL certificates with [Let’s Encrypt]( https://letsencrypt.org/))

* DNS entry poinit `secrets.your.domain` to IP of your server:
  `secrets.your.domain.  59         IN          A           104.245.210.170`

# Setting up custom domain 
If you have all above configured you are able to follow below steps:
*     Log in to your server.
*     Install NGINX on your OS. E.g CentOS:
       `sudo yum install nginx`
*     Nginx does not start on its own. To get Nginx running, type:
       `sudo systemctl start nginx`
![image](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/o99whtwn6osals4kb1uw.png) 
* Enable HTTP/HTTPS communication in your firewall. E.g. CentOS:
```
sudo firewall-cmd --permanent --zone=public --add-service=http
sudo firewall-cmd --permanent --zone=public --add-service=https
sudo firewall-cmd –reload
```
*     Create location for your SSL certificates close to NGINX config and put them there:
```
mkdir /etc/nginx/ssl
mv fullchain.pem /etc/nginx/ssl/your.domain.crt
mv privatekey.pem /etc/nginx/ssl/your.domain.key
```
*     Create new config file:
       `vim /etc/nginx/conf.d/secerts.your.domain.conf`
*     This part will redirect HTTP to HTTPS:
```
server {
  listen 80;
   listen [::]:80;
   server_name secrets.your.domain;
   return 301 https://$host$request_uri;
}
```

* This part will execute proxy pass to the target URL:
```
 server {
       listen      443 ssl http2 default_server;
       listen      [::]:443 ssl http2 default_server;
       server_name secrets.your.domain;
       root        /usr/share/nginx/html;
       ssl_certificate "/etc/nginx/ssl/your.domain.crt";
       ssl_certificate_key "/etc/nginx/ssl/your.domain.key";
       ssl_session_cache shared:SSL:1m;
       ssl_session_timeout 10m;
       ssl_ciphers HIGH:!aNULL:!MD5;
       ssl_prefer_server_ciphers on;
       location / {
           proxy_pass https://some-service-secrets.azurewebsites.net;
       }
       error_page 404 /404.html;
       location = /404.html {
       }
       error_page 500 502 503 504 /50x.html;
       location = /50x.html {
       }
   }
```
*     Reload NGINX:
        `nginx -s reload`
        or
        `systemctl restart nginx`
![image](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/dqvpi8eg75r4lq5kp7hq.png)
Convert Word (DocX) to PDF without any OS dependencies
Tags: go, bash, linux, cloudnative
Published: 2021-04-26 17:32:06

In the [previous post](https://dev.to/rthomascloud/word2pdf-cli-on-openbsd-and-linux-2750) I wrote about a tool I wrote in a very simplistic manner to manipulate word documents on the command line so I could grep for various text in there.

Today I have created another tool on [GitHub (https://github.com/rthomascloud/word2pdf) which carries out the tedious task of converting an MS Word (DocX) file to a PDF without having MS word installed on a server. This tool is still a work in progress as the underlying library just started supporting this feature, I will be filing bug requests for them, but I have already started using this for my customers. I have also created off the shelf docker images based on Alpine that can now convert Word documents to PDF and still being only a few megabytes of size. 

Feel free to try the tool and leave me feedback on GitHub issues, I love making useful and cross platform CLI tools to make life easier.
Video: Deploying Containers On AWS EKS and Engine Yard
Tags: aws, conatiner, kubernetes, app
Published: 2021-04-26 17:31:09

---
title: Video: Deploying Containers On AWS EKS and Engine Yard
published: true
description: This video shows you how to deploy your first Container on AWS Elastic Kubernetes Services (EKS).
tags: AWS, conatiner, Kubernetes, App
//cover_image: https://direct_url_to_image.jpg
---
{% youtube ZgoZdGZw_Xc %}

This video shows you how to deploy your first Container on AWS Elastic Kubernetes Services (EKS). We will also make a head-to-head comparison with Engine Yard Kontainers (EYK) to help you gain a better understanding between both and made it a little bit easier.

We will walk you through a step-by-step process of how you can deploy your containerized application natively on the Elastic Kubernetes Service and then also on Engine Yard.
Engine Yard Kontainers is a powerful way to deploy your applications on a fully managed platform, with best-in-class 24x7 support.

Check out our array of insightful information in our blog section: https://www.devgraph.com/blog/

For more educational videos, subscribe to our YouTube channel!: https://www.youtube.com/channel/UCqHOhcKo3_6ZrwLSaGSNB3Q

Check us out at: https://www.engineyard.com/

Start a FREE Trial: https://signup.ey.io/?_ga=2.121519880.1492935871.1618809944-1889314230.1617702708
Video: Signing up for Engine Yard Kontainers
Tags: devops, ruby, php, node
Published: 2021-04-26 17:26:25

---
title: Video: Signing up for Engine Yard Kontainers
published: true
description: Building on 10 years of experience hosting Ruby-on-Rails, PHP, and NodeJS applications, EYK is your NoOps platform of choice.
tags: DevOps, ruby, PHP, NodeJS
//cover_image: https://direct_url_to_image.jpg
---
{% youtube SjYCGUS9c5E %}

Leverage the power of second-generation Platform-as-a-Service (PaaS) – Engine Yard Kontainers (EYK). Building on 10 years of experience hosting Ruby-on-Rails, PHP, and NodeJS applications, EYK is your NoOps platform of choice.

In this video, we will walk you through on how to set up your Engine Yard Kontainers account.

What you will learn:
• Create an Engine Yard Kontainer(EYK) account
• Download and install EYK CLI tool
• Quickly and easily get started with EYK in minutes
 
Check out other valuable insights on Engine Yard Kontainers, Ruby on Rails, AWS and more at: https://www.devgraph.com/blog/ 

For more educational videos, subscribe to our YouTube channel!: https://www.youtube.com/channel/UCqHOhcKo3_6ZrwLSaGSNB3Q

Visit us at: https://www.engineyard.com/

Start a FREE Trial: https://signup.ey.io/?_ga=2.121519880.1492935871.1618809944-1889314230.1617702708
Video: Getting Started With Engine Yard Kontainers
Tags: container, noops, docker, paas
Published: 2021-04-26 17:21:30

---
title: Video: Getting Started With Engine Yard Kontainers
published: true
description: In this episode of the DevGraph Tech Talk Series, we’ll help you get started with deploying applications to the Engine Yard Kontainers
tags: container, NoOps, docker, PaaS
//cover_image: https://direct_url_to_image.jpg
---
{% youtube JmxGjHa_-SQ %}

In this episode of the DevGraph Tech Talk Series, we’ll help you get started with deploying applications to the Engine Yard Kontainers.

• Learn how to create a cluster within your account
• Download and install EYK CLI Tool for your OS
• Create a sample project
• Generate docker file, proc file, and sample templates
• Learn about using Dashboard, Config and Scaling features, and more…
  
Deploy your applications with one click from GitHub onto a fully-managed, secure application hosting platform with Engine Yard Kontainers (EYK). Get started in a matter of minutes using the second-generation Platform-as-a-Service (PaaS) EYK.

Check out our blog on getting started with Engine Yard Kontainers:
https://support.cloud.engineyard.com/hc/en-us/articles/360057076434-Getting-Started-with-Engine-Yard-Kontainers

For more educational videos, subscribe to our YouTube channel!: https://www.youtube.com/channel/UCqHOhcKo3_6ZrwLSaGSNB3Q

Learn more about Engine Yard at: https://www.engineyard.com/

Start a FREE Trial: https://signup.ey.io/?_ga=2.121519880.1492935871.1618809944-1889314230.1617702708

Check out other valuable insights on Engine Yard Kontainers, Ruby on Rails, AWS and more at:
https://www.devgraph.com/blog/
Video: Using phpMyAdmin to Manage Databases In EYK
Tags: mysql, database, ruby, php
Published: 2021-04-26 17:18:33

---
title: Video: Using phpMyAdmin to Manage Databases In EYK
published: true
description: In this engine Yard Tech Short video, we will show you how to use phpMyAdmin to manage your MySQL database.
tags: MySQL, Database, Ruby, PHP
//cover_image: https://direct_url_to_image.jpg
---
{% youtube 3sctNEWADR8 %}

In this engine Yard Tech Short video, we will show you how to use phpMyAdmin to manage your MySQL database. Learn how to deploy a container with phpMyAdmin and use it to connect and manage your database.

The project used for deployment can be found at:
https://github.com/engineyard/mysql-admin

For more educational videos, subscribe to our YouTube channel!: https://www.youtube.com/channel/UCqHOhcKo3_6ZrwLSaGSNB3Q

Check out our blog section for the latest updates: https://blog.engineyard.com/ 

Visit us at: https://www.engineyard.com/
Start a FREE Trial: https://signup.ey.io/?_ga=2.121519880.1492935871.1618809944-1889314230.1617702708
Video: Using MySQL in Engine Yard Kontainers
Tags: kontainers, ruby, mysql, devops
Published: 2021-04-26 17:15:24

---
title: Video: Using MySQL in Engine Yard Kontainers
published: true
description: In this short video, we at Engine Yard will quickly walk you through on how to add a database to your cluster in a short time.
tags: Kontainers, Ruby, MySQL, DevOps
//cover_image: https://direct_url_to_image.jpg
---
{% youtube W_29wAWD-AA %}
In this short video, we at Engine Yard will quickly walk you through on how to add a database to your cluster in a short time.

In just three minutes, you will learn to accomplish two things:
How to provision a MySQL Database
How to connect Ruby on Rails with MySQL database

The process of using Rails 5.2 encrypted credentials is also covered, so your application data remains secure.

The sample Ruby Quiz application used in the video can be found at: https://github.com/engineyard/ruby-quiz/tree/rdbms

For more educational videos, subscribe to our YouTube channel!: https://www.youtube.com/channel/UCqHOhcKo3_6ZrwLSaGSNB3Q

Check out our blog for the latest updates on Ruby on Rails:
https://blog.engineyard.com/

Visit us at:
https://www.engineyard.com/

Start a FREE Trial: https://signup.ey.io/?_ga=2.121519880.1492935871.1618809944-1889314230.1617702708
Learn Python In 7days Complete Guidelines Zero to Hero
Tags: python, devops, discuss, webdev
Published: 2021-04-26 17:08:47

**Hey developers,**
Today I’m giving you complete guidelines to become a junior of python.
Trust me, it’s super easy and very simple steps just follow my steps, and you become a junior developer of python. On the 7th day, we will build some awesome projects.
>First of all, I need confirmation that you can spend 5--6 hours daily for 7days, you will become a Junior Python Developer.
>If you are super lazy or do not have the patient to spend 5--6 hours daily, my suggestion to you, my friend, please ignore this.
Now let’s jump to day 1

#Day-1: 4 basic concepts (5 hours) 
**=>Python Print() Function
=>Variable
=>Input
=>Conditionals**

#Day-2: 5 basic concepts (5 hours) 
**=>List
=>For Loop
=>While Loop
=>Function
=>Import Modules**

#Day-3: Simple coding problems (6 hours) 
**=>Swap Two Variables
=>Convert miles to kilometers
=>Reverse a string (Check palindrome)
=>Calculate simple interest
=>Calculate GCD
=>Find the largest number in a list
=>Check a number is a prime number or not
=>Merge two sorted Array
=>Sum of all digits in a number
=>Calculate age
=>Build a simple calculator
=>Number guessing game**

#Day-4: Data Structures (6 hours)
**=>Stack (LIFO)
=>Queue (FIFO)
=>Dictionary
=>Tuples
=>Tree
=>Linked List**

#Day-5: Python OOP (6 hours)
**=>Object
=>Class
=>Method and constructor
=>OOP- Inheritance

IF you have more time to learn all about the oop of python then you can learn 

=>OOP- Encapsulation
=>OOP- Abstraction
=>OOP- Polymorphism**

#Day-6: Algorithm (... hours)
**=>Search (Linear and Binary search)
=>Sort (Bubble sort, Selection Sort)
=>Recursive function (factorial, Fibonacci series)
=>Time Complexity (Linear, Quadratic, and Constant)**

#Day-7: Project (6 hours)
**=>1.Build a web crawler
=>or a news aggregator
=>or a simple game using pygame**

>Remember one thing if your sincerity follows my steps, then on the 7th day, you become a Junior python developer.
Video: The Time To Deploy Is Now
Tags: devops, noops, ruby, webdev
Published: 2021-04-26 17:08:47

---
title: Video: The Time To Deploy Is Now
published: true
description: You business doesn't have time to wait. And neither do you. Deployment happens here. Engine Yard Kontainers.
tags:  DevOps, NoOps, Ruby, webdev
//cover_image: https://direct_url_to_image.jpg
---

{% youtube iKyK4tz7pwk %}

You business doesn't have time to wait. And neither do you.
Deployment happens here. Engine Yard Kontainers.
Visit us at https://login.engineyard.com/login
Beginners guide to async-await in Javascript
Tags: javascript, webdev, beginners, tutorial
Published: 2021-04-26 17:05:04

Async Await is syntactical sugar wrapped around to make the implementation of promises easier, If you don't understand how promises works make sure you check out [this post](https://dev.to/a_shokn/beginners-guide-to-promises-in-javascript-5efp)  

>The purpose of async / await is to simplify the syntax necessary to consume promise-based APIs.

Let's jump into an example that will help us understand Async Await in a better way.

```
function newRequest(place) {
	return new Promise((resolve,reject)=>{
  	if(place === 'home') {
    resolve('You have reached home');
    } else {
    resolve("You haven't reached home");
    }
  })
}

function makeRequest(response) {
	return new Promise((resolve,reject)=>{
  	console.log(response);
    resolve(`Current location:- ${response}`);
  })
}

newRequest('home').then(response =>{
return makeRequest(response);
}).then(makeResponse => console.log(makeResponse)).catch((err) => console.log(err));

//Output
//"You have reached home"
//"Current location:- You have reached home"
```

In the above example, the `newRequest` function returns a promise that takes a parameter place based on which promise is resolved. The `makeRequest` function returns a promise which is always resolved.   The two functions are executed in order the second promise waits for the first one.

The above code can be simplified by with the use of Async/Await

```
function newRequest(place) {
	return new Promise((resolve,reject)=>{
  	if(place === 'home') {
    resolve('You have reached home');
    } else {
    resolve("You haven't reached home");
    }
  })
}

function makeRequest(response) {
	return new Promise((resolve,reject)=>{
  	console.log(response);
    resolve(`Current location:- ${response}`);
  })
}

async function checkLocation() {
try {
const  response = await newRequest('home');
const  processed = await makeRequest(response);
console.log(processed);
} catch (err) {
console.log(err);
}
}

checkLocation();

//OUTPUT
// "You have reached home"
// "Current location:- You have reached home"

```

In this example, `checkLocation` is declared using the async keyword. The async keyword tells javascript that the following function is asynchronous. The `checkLocation` works exactly the same as the promises returning the same output. As you can see it looks a lot better and readable than the first example.
Error handling is done with the help of a try-catch block.


> Async Await is just like promises in a way makes it easier to write promises.


```
//A simple example
const delay = ms => new Promise(res => setTimeout(res, ms));

const yourFunction = async () => {
  await delay(5000);
  console.log("Waited 5s");

  await delay(5000);
  console.log("Waited an additional 5s");
};

yourFunction();
```


Thank for your time