teleren/devto huggingface dataset:
🚀 Dive into the Future of Container Orchestration with Kubernetes! 📚🌟
Tags: kubernetes, devops, containerorchestration, softwareengineering
Published: 2023-08-01 06:06:07


My overview of the Edith Puclla's video [3-Minute Kubernetes Architecture 😊](https://www.youtube.com/watch?v=CLD0ltIfvW0)

Are you ready to unlock the true potential of containerized applications and take your development to the next level? Look no further! 🌟 In just 3 minutes, we have an exciting and concise YouTube video that will introduce you to the amazing world of Kubernetes architecture! 📺

**What's all the hype about Kubernetes architecture?** Find out as we break down the essential components that power this cutting-edge technology:

🖥️ **User Interface:** Discover how the user interface empowers you to visually interact with and effortlessly manage your Kubernetes cluster. Say goodbye to complexities and hello to a seamless experience! 💻

⌨️ **Qctl - Your Command-Line Ally:** Unravel the power of Qctl, the official command-line tool for Kubernetes cluster management. Take control with simple yet effective commands! 💪

☁️ **Control Plane:** Meet the brains behind the magic! Learn how the control plane skillfully manages and maintains the desired system state, ensuring everything runs like clockwork. ⏰

🗄️ **Etcd - Your Cluster's Memory:** Get acquainted with Etcd, the distributed key-value store that securely manages your cluster's configuration data. It's like having a reliable memory bank at your fingertips! 💾

📜 **Scheduler - The Pod Placer:** Explore the fascinating role of the scheduler, which intelligently places pods on cluster nodes based on resource requirements and rules. Efficiency at its finest! 🌐

🤖 **Qlet - Your Trusty Agent:** Meet Qlet, the clever agent residing on your worker nodes. Witness how it expertly manages containers and communicates with the control plane, ensuring everything runs smoothly. 🛠️

🐳 **Container Runtime - The Enabler:** Unleash the power of container runtime! Discover how it orchestrates containers, making sure your applications run flawlessly, all the time. 🚀

🔄 **Qproxy - Your Traffic Wizard:** Allow Qproxy, the network proxy on worker nodes, to take center stage. Experience how it deftly forwards traffic, making service definitions a breeze. 🌐

📦 **Ports - Your Building Blocks:** Lastly, explore the heartbeat of Kubernetes architecture! Ports are the smallest, yet mightiest, deployable units representing your applications on worker nodes. Witness the magic of seamless deployments! 🔧

Ready to embark on this thrilling journey of container orchestration? 🌈 Then waste no time and watch our exciting YouTube video now! 📺 Get a basic understanding of Kubernetes' core elements and set yourself up for a world of innovation and efficiency.

🎯 Don't miss out on this opportunity to elevate your development game! Click the link below to watch the video and experience Kubernetes like never before! ⬇️

🚀 Embrace the future of containerization with Kubernetes - The possibilities are limitless! 🚀
Build React SSR Page in Seconds Powered by Deno and TypeScript
Tags: fastro, ssr, deno, react
Published: 2023-08-01 06:00:52

_Supercharge your SSR workflow: Harness the power of [Fastro](https://fastro.deno.dev), [Deno](https://deno.com), and [TypeScript](https://www.typescriptlang.org/) to build React SSR pages in mere seconds._

First, make sure you have Deno installed. See [the deno manual](https://deno.land/manual/getting_started/installation) for details.

Then, create a folder for your project and enter to it.

```zsh
mkdir my-project && cd my-project
```

Generate default project from command line.

```zsh
deno run -A -r https://fastro.deno.dev
```

The above command will generate default folders and files that you can use for the initial project.

Now let's run the application

```zsh
deno task start
```

If there is no problem, you will see this message on the terminal

```zsh
Listening on http://localhost:8000
```

Open that link on [your browser](http://localhost:8000) or hit them via `curl`

```zsh
curl http://localhost:8000
```

You can find more detailed instructions in [the fastro manual page](https://fastro.dev/manual).
7 writing tips for DEV.TO success
Tags: webdev, beginners, productivity, career
Published: 2023-08-01 06:00:00

## 7 Ways to Write Quality Tech Content with Adlous AI

**Understand Your Audience:**
Before you start writing, identify your target audience and their preferences. [Adlous AI](https://www.aiforme.wiki/ai/tools/adlous%20ai)'s data export feature allows you to analyze user behavior, enabling you to create content that resonates with your audience.

**Use Customized Content Templates:**
[Adlous AI](https://www.aiforme.wiki/ai/tools/adlous%20ai) offers 50+ customizable templates for various formats, saving you time and effort. Tailor your content to suit your specific requirements, whether it's a technical article or a captivating Twitter thread.

**Leverage GPT-4 Integration:**
With GPT-4 integration, Adlous AI delivers more accurate and context-aware content. Benefit from cutting-edge language models that understand and cater to complex tech topics with precision.

**Overcome Writer's Block:**
Adlous AI is a solopreneur's best friend, a social media manager's ally, and a content creator's secret weapon. It eradicates writer's block by offering AI-generated prompts and suggestions that inspire creative ideas.

**Stay On-Brand:**
Maintain brand consistency by training Adlous AI with your brand guidelines and past content. Ensure that the generated content aligns with your brand's voice and tone for a cohesive online presence.

**Optimize Content for Search Engines:**
Use Adlous AI to generate relevant keywords for your tech content. Enhance your SEO efforts by incorporating these keywords strategically, boosting your content's visibility and reach.

**Rewrite and Summarize Content:**
Adlous AI allows you to rewrite and summarize existing content efficiently. Revamp outdated articles or condense lengthy texts without compromising on quality, saving valuable time in the content creation process.

**Conclusion:**
With [Adlous AI](https://www.aiforme.wiki/ai/tools/adlous%20ai), writing quality tech content becomes a breeze. Its advanced capabilities, including GPT-4 integration, customized templates, and data-driven insights, empower content creators, marketers, and businesses to elevate their content game and achieve remarkable results in the competitive digital landscape. 

Say goodbye to content creation struggles and embrace the future of AI-powered content with Adlous.
Enforcing password policies on Ubuntu
Tags: devops, linux, security
Published: 2023-08-01 05:30:34

Hi, in this blog, we are going to set up password policy enforcement to enhance overall security on Ubuntu.

Let's start with configure password complexity. First, install the `libpam-pwquality`.

```
sudo apt install libpam-pwquality
```

Then, edit `/etc/security/pwquality.conf` with following configuration.

```bash
minlen = 14  # password must be at least 14 characters
minclass = 4 # minimum number of required classes of characters for the new password (digits, uppercase, lowercase, others)
```

After that, edit `/etc/login.defs` with following configuration

```bash
PASS_MAX_DAYS 90 # password expiration days
PASS_MIN_DAYS 1  # days between password changes 
PASS_WARN_AGE 7  # warnings before expiration
```

That's all. Now we have a more robust Ubuntu system.
Thank you for reading and have a nice day.
My Time in the Ruby Gym
Tags: beginners, ruby
Published: 2023-08-01 05:30:29

I completed the ruby gym over the weekend and wanted to document my thoughts on the challenges. Some were easy, others were hard, but fun. So, let us begin...


**Think fast**

At first glance I thought it was going to be easy, but I did run into a lot of syntax errors. Once they were resolved the rest fell into place. Overall it was a fun challenge.

**Twofer**

This was the easiest of all the challenges. Once I went with _.length_ to determine if the array gave a name or an empty string the rest was standard.

**Dice Roll**

Another straight forward challenge, but when trying to pass the test an error kept coming up. I had to switch the placement of my guess and roll variables. Once I did that, the last test passed.

**Leap Year**

This was the hardest of all the challenges. I took a simple approach, but once I accepted that a more complex approach was needed I finally started to make some progress. I needed to do some more research on how leap years are calculated. Google was a big help in solving this challenge.

**Secret Encoder & Secret Decoder**

These two challenges are pretty much the same. Looking back I could have made things a lot easier using _.each_ to loop through the array created by using _.split("")_ Through trial and error I was able to solve this challenge. 

**Sum Odd Integers**

This was a fun challenge that required a game plan to solve. Similar to the encoder and decoder challenges I should have used _.each_ to loop through the array to make things easier. 

**Raindrops**

This challenge required a lot of thinking before actually writing any code. My biggest time waster was trying to solve this challenge using one if statement. Once I abandoned that idea and went with 3 separate if statements I was able to solve it quickly. 

**Character Types**

For this challenge I needed to read more about regexp and how to use it. Scanning the string if 0-9 is present to differentiate between a word character and a number character. 

**Count "the"**

Similar to the last challenge, my success depended on my knowledge of regexp. Once I was able to use the right notation to scan for all the "the"s without triggering "the" inside of words like "them" or "they" I was able to solve it. Regexp is a powerful tool so, I was happy to read up on it and expand my knowledge. 

**Final Thoughts**

It felt good to solve coding challenges again. I look forward to solving more ruby challenges to expand my ruby knowledge in the future. If I make the final cut into the DPI program I hope to do one ruby challenge a day during the 3 month training. Become a lean mean problem solving machine!
AntDB Installation and Deployment Documentation - P5
Tags: database
Published: 2023-08-01 02:04:00

## Centralized database copyright management
This chapter describes the use of database copyright management.

**_Centralized database without license file_**

If there is no official license file, a trial license file will be created when the database is installed (initdb): adb_license_trail, the data in the file is encrypted expiration date, the expiration date is the current time + 30 days. The trial license file will be copied to the backup library during the pg_basebackup.

If you execute the initdb command, the trial license file adb_license_trail will be generated in the data directory of the database.

**Activate adb_license_trail**

After the database is started, activate the trial version of adb_license_trail file directly. After activation, it is valid for 30 days.

**_Centralized database with license file_**

Users need to go to the company's GTM platform to apply for the database license, get the license file, place the license file in the data directory of the main library, and then connect to the main library to execute the license activation command (activate antdb_license) or restart the main library (pg_ctl start/ restart), which is used to activate the license on the master.

Place the license in the data directory of the standby library, then connect to the standby library and execute the license activation command (activate antdb_license) or restart the standby library (pg_ctl start/restart) to activate the license of the standby library.

If there are multiple backups, each backup needs to be activated.

**Activate antdb_license**

```
activate antdb_license; #Activate the license file in the data directory 
```

**_View the license information_**

The show antdb_license command allows you to view the license information of the trial and full version.

```
show antdb_license;  #View license information 
```

**_License Expiration_**

After the license expires, re-link the database, a warning message will be given, but it will not affect the database related operations. Replace the new license file and use it directly after activation.
👉Traditional PBX IS LESS EFFECTIVE. WHERE IS THE SOLUTION FOR BUSINESS? 🤔
Tags: diginext, digisip, virtualpbx
Published: 2023-08-01 04:58:16

More than 95% of Vietnamese businesses using traditional switchboards or listening/calling with personal mobile numbers to take care of customers are having problems:
❓ Expensive to invest in switchboard equipment, expensive calling charges
❓ Difficulty in finding and storing customer data
❓ No reporting-monitoring system to manage Sales/Customer's performance
❓ Manual, discrete management of customer information
With the PBX 𝗗𝗶𝗴𝗶𝗡𝗲𝘅𝘁 integrated with CRM, businesses will not have to deal with the problem of telemarketing anymore.
✔ Use online on website/mobile app, no need to invest in hardware
✔ Integrated call center / call center right on the application
✔ Divide calls for each employee, unlimited number of calls at the same time
✔ Call recording & long-term storage
✔ Report statistics, effectively monitor each call
🤔 You want to grow your business, why still use a cumbersome traditional switchboard or listen/call with a personal mobile number?
👍 Let #diginext help you improve customer experience, optimize telesales efficiency and create a competitive advantage for your business.
Sign up for solution demo and free trial right here: bit.ly/3PSXhsD
-----------------------
📌 DIGINEXT – The leading CRM combination smart switchboard solution in Vietnam
🛍️ Address: A24/D7 Cau Giay, Dich Vong Ward, Cau Giay District, Hanoi City
☎ Hotline: 1900 5055 - 024 888 55555
📩 Email: Kinhdoanh@diginext.com.vn
🔗 Website: diginext.com.vn
Ruby Code Academy
Published: 2023-08-01 03:48:51

I've been learning Ruby through Code Academy. Ruby shares a lot of similarities with other programming languages as far as I can tell. I noticed that semicolons are rare, which has led to some mistakes for me. I am learning some new concepts that I didn't know from other langauges. I do not recall using hashes in Python or Java. Overall, the experience has been enlightening for me.
Why Would I Use Tashi Monitor Nodes?
Tags: gamedev, unity3d, serverless
Published: 2023-08-01 03:39:01



For those that haven’t read our previous article, Tashi’s unique architecture allows for the benefits of dedicated game servers, such as low latency and secure communication, while maintaining the cost-effectiveness of peer-to-peer game servers.

This approach not only provides better performance and security, but also allows for easy scalability. And because the network is decentralized, there is no single point of failure.

But what about accessing game data for analytics or interacting with game sessions from your game backend? Tashi has you covered. The platform includes robust monitor nodes that allows for easy integration with any game backend, providing access to all necessary game event data.

The monitor nodes extract all game event data and can be easily dropped onto a Kafka stream. This allows for seamless interaction with microservices and other applications that consume data from the stream. With this functionality, Tashi’s monitor nodes can help game developers streamline their entire backend infrastructure, from data collection to processing and analysis. By leveraging the power of Kafka, developers can build scalable and resilient architectures that can handle large amounts of game event data. This also enables real-time analysis and decision making, which can be critical for ensuring a successful game launch and long-term user engagement.

While Tashi monitor nodes can also be utilized to emit game events that only the developer can trigger. For example, Tashi monitor nodes can be used to implement features such as truly random loot boxes or kicking a user out from a game.

So what are you waiting for? Sign up for our open beta at tashi.gg
Master Git Submodules With This Comprehensive Guide!
Tags: git, github, tutorial, beginners
Published: 2023-08-01 03:36:45


---
title: Master Git Submodules With This Comprehensive Guide!
published: true
description: Learn how to effectively use Git's powerful feature, Submodules.
tags: git, github, tutorial, beginners
---

## Introduction

Git is an essential tool for software developers as a version control system. Especially when dealing with multiple projects or libraries, the Git submodule feature is incredibly handy. Today, I will introduce the basic usage of Git submodules.

## Table of Contents
1. [What is a Submodule?](#what-is-a-submodule)
2. [Adding a Submodule](#adding-a-submodule)
3. [Initializing and Updating a Submodule](#initializing-and-updating-a-submodule)
4. [Incorporating Changes in a Submodule](#incorporating-changes-in-a-submodule)
5. [Conclusion](#conclusion)

## What is a Submodule?

A Git submodule is a feature that allows you to nest another repository in a repository. This allows you to manage independent projects in one parent repository.

## Adding a Submodule

Let's start by adding a submodule.

First, run the following command in your terminal.

```bash
git submodule add <repository>
```

Here `<repository>` is the URL of the repository you want to add as a submodule.

For example, if you want to add a repository as a submodule named `my-submodule`, you would do as follows.

```bash
git submodule add https://github.com/user/repo.git my-submodule
```

With this, the submodule is added and the contents of the repository are cloned under the `my-submodule` directory.

## Initializing and Updating a Submodule

Next, initialize and update the submodule.

For this, execute the following commands in the terminal.

```bash
git submodule init
git submodule update
```

These commands allow you to initialize the submodule and check out the latest commit of the submodule.

## Incorporating Changes in a Submodule

It's crucial to incorporate changes in the submodule's repository when there are any.

Run the following command in your terminal.

```bash
git submodule update --remote
```

This will incorporate the latest commit of the submodule into the parent repository.

## Conclusion

That's all for the basic usage of Git submodules. Although submodules are an advanced feature of Git and require careful handling, mastering them can greatly improve the efficiency of software development.

In the next post, I will introduce techniques to further utilize submodules, so stay tuned!

Happy coding :)
The security concern of Software-defined Everything
Published: 2023-08-01 03:31:23

Application is not only the main character of IT, but also the driving force of current life. Nonetheless, cyber security issues consistently beset applications and their running environment. Are you aware that there are inherent loopholes for hackers to take advantage of in your application’s code?

Demo site:
https://zeroday.co.uk/#/demo

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/nhs0bxxoc1qptzjt1f6m.jpg)
XSS baseado em DOM
Published: 2023-08-01 02:57:38

O XSS baseado em DOM geralmente ocorre quando o JavaScript obtém dados de uma fonte controlada pelo invasor, como a URL, e os passa para um coletor que executa código dinâmico, como `eval()` e `innerHtml()`.

Normalmente a URL é acessada com `window.location` objeto. Um invasor pode construir um link para enviar uma vítima a uma página vulnerável com uma carga útil na string de consulta e partes fragmentadas da URL.

Ilustração de ataque XSS baseado em DOM

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/gwldyhv8l9hjtjrdg9mf.png)

Referências:
https://portswigger.net/web-security/cross-site-scripting/dom-based
C++ - Basic Tree Traversal(Recursive vs Stack)
Tags: binary, tree, traversal, stack
Published: 2023-08-01 02:05:30

Definition for a binary tree node

```cpp
struct TreeNode {
      int val;
      TreeNode *left;
      TreeNode *right;
      TreeNode() : val(0), left(nullptr), right(nullptr) {}
      TreeNode(int x) : val(x), left(nullptr), right(nullptr) {}
      TreeNode(int x, TreeNode *left, TreeNode *right) : val(x), left(left), right(right) {}
  };
```
Main types of binary tree traversal:
+ Inorder (Traversal):  left - root - right
+ Preorder(Traversal):  root - left - right
+ Postorder(Traversal): left - right - root

leetcode question :
**94. Binary Tree Inorder Traversal**
Given the root of a binary tree, return the inorder traversal of its nodes' values.
+ Recursive Solution

```cpp
class Recursive_Solution {
public:
    void travel(vector<int>& tree, TreeNode* root) {
        if (!root) return;
        travel(tree, root->left);
        tree.push_back(root->val);
        travel(tree, root->right);

    }
    vector<int> inorderTraversal(TreeNode* root) {
        vector<int> ret;
        travel(ret, root);
        return ret;
    }
};
```
+ Non Recursive (using stack)

```cpp
class Solution {
public:
    vector<int> inorderTraversal(TreeNode* root) {
        stack<TreeNode*> mst;
        vector<int> ret;
        TreeNode* tn = root;
        while (tn || !mst.empty()) {
            while (tn) {
                mst.push(tn);
                tn = tn->left;
            }
            tn = mst.top();
            ret.push_back(tn->val);
            mst.pop();
            tn = tn->right;
        }
        return ret;
    }
};
```
Leetcode question:
**98. Validate Binary Search Tree**
Given the root of a binary tree, determine if it is a valid binary search tree (BST).
A valid BST is defined as follows:
The left subtree of a node contains only nodes with keys less than the node's key.
The right subtree of a node contains only nodes with keys greater than the node's key.
Both the left and right subtrees must also be binary search trees.

Non Recursive (using Stack)

```cpp
class Solution_stack {
public: 
    bool isValidBST(TreeNode* root) {       
        stack<TreeNode*> st;
        TreeNode* tn = root;
        TreeNode* prv = nullptr;
        while(tn || !st.empty()){            
            while(tn){
                st.push(tn);
                tn = tn->left;
            }
            tn = st.top();
            st.pop();
            if(prv){
                if(prv->val >= tn->val) return false;
            }
            prv = tn;
            tn = tn->right;
        }   
        return true;     
    }
};
```

Recursive solution

```cpp
class Solution_recursive {
public:    
    bool g_ret = true;
    TreeNode* prv = nullptr;
    void check(TreeNode* root){
        if(!root) return;
        if(root->left) check(root->left);
        if(prv){
            if(prv->val >= root->val) {g_ret = false; return;}
        }
        prv = root;
        check(root->right);
    }    
    bool isValidBST(TreeNode* root) {       
        check(root);
        return g_ret;
    }
};
```