teleren/devto huggingface dataset:
Liman Cihaz Yönetim ile Log Kayıtlarını İzleme ve Yönlendirme
Published: 2023-05-26 06:38:07

#1. Rsyslog Sunucusu Kurulumu

- Öncelikle ilgili sunucu, syslog log alabilecek şekilde yapılandırılmış olmalıdır. Bu log sunucusu ihtiyacı için açık kaynak kodlu rsyslog sunucusu kurulması için [buradan](https://dev.to/aciklab/rsyslog-servisi-ile-uzak-sunucuya-log-yazdirma-3i3n) yararlanılabilinir.

- Liman arayüzü açılır.
- Menüye girilir.
- Menüde sunucunun alt başlıklarında bulunan <u>Cihaz Yöneticisi</u> eklentisinin içine girilir.
- İlgili makineye tıklanır ve "Konfigürasyon" sekmesine girilir.

- "Görüntüleme" sekmesinde ilgili conf dosyaları görüntülenir.

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

- "Düzenleme" sekmesine girilir.

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

**Config Adı:** Gönderilmek istenen config dosyasının adı girilir.
**Dosya Yolu:** Log gönderilecek makinenin ilgili yolu girilir.
**Sunucu:** Log gönderilecek sunucunun IP ve port bilgisi girilir.  (Varsayılan Port: 514)
**Protokol:** İlgili protokol seçilir.

- "Kaydet" butonuna tıklanır.
- Gelen ekrandaki bilgiler log üretecek olan makinenin konfigürasyonunu içerir.

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

**:bangbang:** [Linkteki](https://dev.to/aciklab/rsyslog-servisi-ile-uzak-sunucuya-log-yazdirma-3i3n) 3. madde "Log Üreten Makinanın ayarları" kısmı yapılacaktır.

- Konfigürasyon log gönderecek makinede de yapıldıktan sonra, ilgili makinenin sağındaki mavi **shell** logosuna tıklanır ve şu komut girilir:

```
ls -l /var/log/remote
```
- Log gönderen makinenin hostname'i eşliğinde log'un geldiği görüntülenir.

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

- **Konfigürasyon** sekmesine girilir.
- **Dosya Okuma** sekmesine girilir ve arama kutucuğuna **/var/log/remote/ubuntu.log** yazılır ve ara logosuna tıklanır.


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

- Gelen log görüntülenir.
Performing is Always Fun
Tags: dance
Published: 2023-05-26 06:36:17

It must be not common to post things like this on here haha. But I will add some fun. This photo was taken during a performance by our dance group at a church in Plano, TX.

I will link my instagram here. There more dancing videos of me and my friends there!

[HenryZZ](https://instagram.com/bchenryzzz?igshid=MjEwN2IyYWYwYw==)
Mobile app developers in Pune
Tags: mobile, application, ios, android
Published: 2023-05-26 06:16:17

Appconsultio is the best mobile application development company in Pune and offers a wide range of services for custom mobile apps. Our top Android, iOS, and Hybrid developers in Pune build quality apps for your business.
https://www.appconsultio.com 
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/fxoa7i2zzd18as5fvced.png)
Custom Input Date Using HTML and CSS
Published: 2023-05-26 06:14:47

Hey Guys, In Today's Blog We are going to see How to create a Custom Input Date Using HTML and CSS. We Completely style **[Custom Input Date](https://www.codewithrandom.com/2022/10/14/custom-input-date-html-css/)** Using Css. For that, the respective source codes were given below along with the respective preview of the output section. So you can make use of that.

first, We create an Input Date in Html and then Give a Custom Style Using Css.

Now The Project is going to create and for that, we are first adding an HTML Code.

## HTML Code For Custom Input Date :
```
<h1>PURE CSS DATE PICKER</h1>
<label for="dateofbirth">Date Of Birth</label>
<input type="date" name="dateofbirth" id="dateofbirth">
```
First We Create a header using H1 class for the title and add a subheading that has a date of birth using the label class.  Then Lastly we are adding an input class for custom date picking with some Id for reference.

## CSS CODE:
```
[type="date"] {
  background:#fff url(https://cdn1.iconfinder.com/data/icons/cc_mono_icon_set/blacks/16x16/calendar_2.png)  97% 50% no-repeat ;
}
[type="date"]::-webkit-inner-spin-button {
  display: none;
}
[type="date"]::-webkit-calendar-picker-indicator {
  opacity: 0;
}

/* custom styles */
body {
  padding: 4em;
  background: #e5e5e5;
  font: 13px/1.4 Geneva, 'Lucida Sans', 'Lucida Grande', 'Lucida Sans Unicode', Verdana, sans-serif;
}
label {
  display: block;
}
input {
  border: 1px solid #c4c4c4;
  border-radius: 5px;
  background-color: #fff;
  padding: 3px 5px;
  box-shadow: inset 0 3px 6px rgba(0,0,0,0.1);
  width: 190px;
}
```
In First part of CSS , We are adding padding , background and font family inside of body section that contains entire HTML Content. Then The label class is set to block.

In Second Part , We are adding border and its radius , background-color, padding, box-shadow, width to the Input Field element that contains the Custom Date.

In Last Part, We are specifically calling the input type and adding background with URL for calendar to display in white background. Then The arrows for selecting future date and past date's opacity to zero.

Now That's of for CSS. And Hence We have Successfully completed our Custom Input Date Project by adding the required source codes. So we can now move for project preview in the below Output Section.

Now We have Successfully created our **[Custom Input Date](https://www.codewithrandom.com/2022/10/14/custom-input-date-html-css/)** Using CSS. You can use this project for your personnel needs and the respective lines of code are given with the code pen link mentioned below.

If you find out this Blog helpful, then make sure to search codewithrandom on google for Front End Projects with Source codes and make sure to Follow the Code with Random Instagram page.

REFER CODE- Mahesh Ambure

WRITTEN BY- Ragunathan
How to Move Magento 2 from Localhost to Server
Tags: magento, magento2, magento2tutorial
Published: 2023-05-26 05:55:51

If you're looking to make your online store accessible to the public, it's crucial to know the steps involved in transferring Magento 2 from localhost to a server. Whether you're in the initial stages of developing your store or migrating an existing one, moving Magento 2 can be a complex undertaking. However, by carefully following the instructions outlined below, you can ensure a smooth and successful transition from a local development environment to a live website.

Setting up a Magento 2 store can be a challenging process, and offering an incomplete setup to potential customers may lead to disappointment. To avoid this, it is recommended to first set up your Magento 2 store on localhost. Invest the necessary time and effort into building and configuring every feature to perfection before taking your store live.

Before diving into the migration steps, there are a few prerequisites to consider. Ensure that you have purchased a domain name and selected the best Magento hosting solution for your needs.

Now, let's proceed with **_How to Move Magento 2 from Localhost to Server_**, enabling your online store to reach a wider audience.

For more information , please visit this :- **_[https://webguru.dev/how-to-move-magento-2-from-localhost-to-server/](https://webguru.dev/how-to-move-magento-2-from-localhost-to-server/)_**
The only correct approach for UTF-8 strings in Perl
Tags: perl
Published: 2023-05-26 05:45:51

The only correct approach for UTF-8 strings in Perl.

A string is treated as byte sequences without any flags.

Separate functions that handle UTF-8 from functions that handle byte sequences. The following is an example of the `substr` function.

```
substr_bytes
substr_utf8
```

The `use utf8_func` pragma replaces `substr` with `substr_utf8`.

The `use bytes_func` pragma replaces `substr` with `substr_bytes`.

Feel free to comment.
How to Generate XML and HTML Sitemaps in Magento 2
Tags: webdev, magento, magento2tutorials
Published: 2023-05-26 04:09:59

Sitemaps are a vital part of any site as they act as an aide for web search tools to slither and record all pages of your website really.

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

An efficient sitemap gives significant data about the design and content of your site, working on the cycle for web crawlers to understand and rank your pages. XML sitemaps, explicitly, help web crawlers in quickly finding and ordering your pages in general, while HTML sitemaps present an easy to use outline of your site's design, improving on route for guests.

In Magento 2, creating XML and HTML sitemaps is a straightforward errand that can be achieved easily by means of the backend of the stage, after you set up Magento 2. This article will direct you through the bit by bit course of **_How to Generate XML and HTML sitemaps in Magento 2_**, as well as feature the benefits of doing as such.

For more info, visit **_https://webguru.dev/how-to-generate-xml-and-html-sitemaps-in-magento-2/_**
Simplifying JavaScript Code with Arrow Functions
Tags: javascript, arrowfunctions, beginners
Published: 2023-05-26 05:27:26

Introduction:
JavaScript arrow functions, have changed the landscape in the way developers are able to write functions. They provide a concise and expressive syntax, making code more readable and reducing extra jargon. I will explore the key features and benefits of arrow functions, along with a few examples.

Arrow Function Syntax:
The syntax of arrow functions is straightforward. Instead of the traditional function keyword, we use the arrow (=>) notation. Here’s a simple example:

// Traditional function
function multiply(a, b) {
  return a * b;
}

// Arrow function
const multiply = (a, b) => a * b;

Conciseness and Readability:
Arrow functions offer a shorter syntax, eliminating the need for curly braces and the return keyword in certain cases. For single-line functions, we can implicitly return the result. This enhances code readability and reduces unnecessary verbosity:

// Traditional function
function square(x) {
  return x * x;
}

// Arrow function
const square = x => x * x;

Lexical this Binding:
One significant advantage of arrow functions is their lexical binding of the “this” keyword. Unlike regular functions, arrow functions don’t have their own this value. Instead, they inherit this from the surrounding context. This simplifies the handling of this scoping issues:

const person = {
  name: 'John',
  greet: function() {
    setTimeout(() => {
      console.log(`Hello, ${this.name}!`);
    }, 1000);
  }
};

person.greet(); // Outputs: Hello, John!

Use Cases:
Arrow functions are particularly useful in scenarios such as array manipulation, event handlers, and callbacks. They provide a much cleaner way to format your code in these situations:

// Array manipulation
const numbers = [1, 2, 3, 4, 5];
const squaredNumbers = numbers.map(num => num * num);

// Event handler
button.addEventListener('click', () => {
  console.log('Button clicked!');
});

// Callback function
fetchData(url, data => {
  console.log('Data received:', data);
});

Conclusion:
JavaScript arrow functions simplify code and improve readability by offering a concise syntax and lexical this binding. With their streamlined structure, they are particularly useful in scenarios where brevity and clarity are desired. By leveraging the power of arrow functions, developers can write cleaner, more expressive JavaScript code.

While arrow functions bring many benefits, it’s important to note that they may not be suitable for every situation. Understanding their limitations and appropriate use cases will help developers make informed decisions when choosing between arrow functions and traditional function syntax.
1757. LeetCode's Recyclable and Low-Fat Products Solution - Simple & Logical SQL Command
Tags: sql, mysql, database, leetcode
Published: 2023-05-26 05:19:19

For a more in-depth explanation, pleas view my LeetCode solution: https://leetcode.com/problems/recyclable-and-low-fat-products/solutions/3563813/recyclable-and-low-fat-products-simple-logical-sql-command/

# Intuition
The problem is to find the product ids of products that are low in fats and recyclable from a table called `Products`. A possible way to solve this problem is to use a SQL query that filters the rows based on the `low_fats` and `recyclable` columns.

# Approach
1. Write a `SELECT` statement that specifies the `product_id` column as the output.
2. Write a `FROM` clause that specifies the `Products` table as the source.
3. Write a `WHERE` clause that specifies the conditions for `low_fats` and `recyclable` columns. Use the `AND` operator to combine the two conditions.
4. Run the query and return the result.

# Complexity
- Time complexity: `O(n)`
The SQL query iterates over all of the items in the `Product table to check if they match the clauses.

- Space complexity: `O(1)`
No additional storage is necessary for the SQL query.

# Code
```sql
SELECT product_id FROM Products WHERE low_fats='Y' AND recyclable='Y';
```

My LeetCode Solutions: https://leetcode.com/VerisimilitudeX/
118. LeetCode's Pascal's Triangle - Extremely Simple Logic Solution Beats 96% of Java Solutions in Memory & Runtime
Tags: java, interview, tutorial, leetcode
Published: 2023-05-26 04:59:59

# Intuition
The problem is to generate the first n rows of Pascal’s triangle, where each element is the sum of the two elements above it. One possible way to solve this problem is to use a list of lists (or in other words, a 2D array) to store the rows, and iterate from the first row to the nth row, adding new elements based on the previous row.

# Approach
- Initialize an empty list of lists to store the rows.
- Add the first row, which is a list containing only 1, to the list of rows.
- For each row from 1 to n-1, do the following:
    - Initialize an empty list to store the current row.
    - Add 1 to the beginning and end of the current row.
    - For each element from 1 to i-1, where i is the index of the  current row, do the following:
        - Get the previous row from the list of rows.
        - Add the element at index j-1 and j from the previous row, and append it to the current row.
    - Add the current row to the list of rows.
- Return the list of rows.

# Complexity
- Time complexity: `O(n^2)`

We need to iterate over n rows, and for each row i, we need to iterate over i elements. The total number of elements is `n(n+1) / 2​`, which is `O(n^2)` in asymptotic notation.

- Space complexity: `O(n^2)`

We need to store n rows, and each row i has i elements. The total space required is `n(n+1) / 2​`, which is `O(n^2)` in asymptotic notation.

# Code
```java
public class Solution {
    public static List<List<Integer>> generate(int numRows) {
        List<List<Integer>> allRows = new ArrayList<>(numRows);
        List<Integer> firstRow = new ArrayList<>();
        firstRow.add(1);
        allRows.add(firstRow);
        for (int i = 1; i < numRows; i++) {
            List<Integer> row = new ArrayList<>(i + 1);
            row.add(1);
            List<Integer> prevRow = allRows.get(i - 1);
            for (int j = 1; j < i; j++) {
                int sum = 0;
                if (j - 1 >= 0 && j - 1 < prevRow.size()) {
                    sum += prevRow.get(j - 1);
                }
                if (j >= 0 && j < prevRow.size()) {
                    sum += prevRow.get(j);
                }
                row.add(sum);
            }
            row.add(1);
            allRows.add(row);
        }
        return allRows;
    }
}

```

For a more in-depth explanation, please view my LeetCode post: https://leetcode.com/problems/pascals-triangle/solutions/3563758/pascal-s-triangle-extremely-simple-logic-solution-beats-96-of-java-solutions-in-memory-runtime/
How to Configure Magento 2 Customer Accounts
Tags: magento, magento2, magento2tutorial
Published: 2023-05-26 04:58:08

The significance of ensuring a flawless customer journey on your website cannot be overstated. When your online store offers a seamless interaction experience, it undoubtedly increases the likelihood of customers returning. A substantial portion of these interactions takes place through the customer account feature.

That's why it's imperative to utilize the Magento customer account configuration settings. By doing so, you not only enhance the ease of engaging with your store but also gain the ability to customize customer account options according to your specific requirements.

**_How to Configure Magento 2 Customer Accounts_**: Creating a seamless customer experience on your website is of utmost importance and should not be underestimated. To encourage repeat visits, it is essential to make your website user-friendly. A critical aspect of customer interactions on a website is through the customer account feature. Magento 2 offers a variety of configuration settings that can simplify engagement and enable efficient management of customer account options.

For more information , please visit this :- [**_https://webguru.dev/how-to-configure-magento-2-customer-accounts/_**](https://webguru.dev/how-to-configure-magento-2-customer-accounts/)
Ishga kirishdagi suhbat jarayoni
Published: 2023-05-26 04:53:58

Dasturchi sifatida ishga joylashish doim ham oson bo‘lmaydi. Ammo suhbat jarayoni, undagi qadamlar haqida bilsangiz, albatta foydali bo‘ladi va ko‘zlagan ishingizga kirish ehtimoli oshadi.

Jarayon umumiy quyidagicha bo‘ladi:

1. [Ma’lumotnoma tekshiruvi](https://t.me/bakhtiyor_sulaymonov/177) (_Resume screening_):

Ish beruvchi sizning ma’lumotlaringizni topshirayotgan ish o‘riniga qanchalik mos ekanini tekshiradi

2. [Telefon suhbati](https://t.me/bakhtiyor_sulaymonov/191) (_Phone screening_):

Ishga yollovchi (_recruiter_) yoki ishga qabul qilish bo‘yicha boshqaruvchi (_hiring manager_) bilan muloqot qobiliyatingiz, motivatsiyangiz va ish o‘rniga qanchalik mosligingizni baholashlari uchun qisqa suhbat

3. [Texnik suhbat](https://t.me/bakhtiyor_sulaymonov/197) (_Technical interview_):

Bir yoki bir nechta muhandislar sizning texnik, muammolarni hal qilish va hamkorlikda ishlash qobiliyatlaringizni tekshirishadi

4. [Xulq atvor bo‘yicha suhbat](https://t.me/bakhtiyor_sulaymonov/201) (_Behavioural interview_):

Boshqaruvchi (_manager_) yoki boshqaruvchilar jamoaviy ishlash, muloqot va yetakchilik kabi asosan yumshoq ko‘nikmalaringiz bo‘yicha suhbat qilishadi

5. [Taklif](https://t.me/bakhtiyor_sulaymonov/204) (_Offer_):

Yuqoridagi qadamlardan muvaffaqiyatli o‘tsangiz, sizga o’sha ish o‘rini uchun taklif yuborishadi

_PS. Bu jarayon kompaniyaga qarab biroz farqli bo’lishi mumkin, kattaroq kompaniyalarda, masalan FAANGda yana bir nechta qo’shimcha suhbatlar va tekshiruvlar bo‘ladi_

**manba**: https://t.me/bakhtiyor_sulaymonov/175
Deploying Angular apps to Azure Static Web apps
Tags: azure, staticwebapps, angular, webdev
Published: 2023-05-26 04:53:13

## Introduction

Azure Static Web Apps is a perfect hosting option for SPA frameworks like Angular or React.

The best thing is it's going to be free (or at least dirt cheap if you have a highly trafficked site) but not only that it contains a whole host of goodies out of the box. This includes the following

### Content Delivery Network 
Your files are served from edge servers so wherever your users are, there should be minimal latency.

### CI/CD Pipelines 
As development teams try to increase their velocity, one critical prerequisite is the ability to deploy quickly, automatically and consistently and to do that, you need to build CI/CD pipelines. This can sometimes be an afterthought, but with azure Static Web apps, this is the default. You have to specify your Github / DevOps repo as part of spinning one up and it automatically creates a Github Action / Pipeline for you.

### Multi deployment environments 
The "static" in Static Web Apps implies files (eg. HTML, JS or CSS or other asset files) that do not change - at least not without a deployment. This means it's really easy to create environments for different versions of them. This is built out of the box - you can easily spin up a new environment to test the changes of a PR or have dedicated test or UAT environments. It's all very flexible and very easy to implement.

## Demonstration
Rather than explaining how it works in detail, it's much easier for me to just show you in the attached video. In this video, I'll be showcasing the features of Azure Static Web App to deploy a sample Angular solution. Feel free to like or subscribe!

Finally, the codebase can be viewed [here](https://www.youtube.com/redirect?event=video_description&redir_token=QUFFLUhqbnM2ZmdrM3YzTDhBTFNxV05Wck9Yc2RuVmVTUXxBQ3Jtc0trSzVVaU5TWW5adFRfTmJrZVlRS3Z5UmtCalhBak5EQ0MwRktKMnhwd3A3OTZHSy1TZThkME82SzNwRTRTRUJlb21ONjRNLTBzdnVRM2EwUFhQR2YwYjJwTk4wdFJSWmprYXkzMGIxQ0dWNF9lQklnNA&q=https%3A%2F%2Fgithub.com%2Fwaiholiu%2FStaticWebAppDemo&v=8X-PVOKfkMw)

{% youtube 8X-PVOKfkMw %}
Best Tool for auditing your smart contract
Tags: smartcontract, blockchain, web3, audit
Published: 2023-05-26 04:44:33

In the world of blockchain and decentralized applications, smart contracts play a crucial role. However, ensuring the security and reliability of these contracts is of paramount importance. In this article, we will explore a tool called Buildbear that helps in auditing smart contracts and provides detailed vulnerability reports. By following a series of steps, developers can strengthen the security of their smart contracts and protect against potential bugs and security threats.

_FOLLOW ALL THIS STEPS TO AUDIT YOUR SMART CONTRACT_

**Step 1: Create and Write Your Smart Contract Using Hardhat:**
To begin the auditing process, you first need to create a Hardhat project and write your smart contract. Hardhat is a popular development environment for Ethereum that allows you to compile, test, and deploy smart contracts efficiently.

**Step 2: Set Up a Testnet Using Buildbear:**
Buildbear provides a user-friendly platform for creating testnets. These testnets allow you to deploy and interact with your smart contracts in a controlled environment before deploying them on the mainnet. Refer to the Buildbear documentation for detailed instructions on creating a testnet.

**Step 3: Add Buildbear to Your Network:**
To integrate Buildbear into your development workflow, you need to add it to your network configuration. By doing so, you enable Buildbear's auditing capabilities and ensure that your contracts undergo a thorough security assessment.

**Step 4: Deploy and Verify Your Smart Contract:**
Once your testnet is set up, deploy your smart contract onto the testnet using Buildbear. This process enables Buildbear to analyze the contract's code and identify potential vulnerabilities. After the deployment, you will receive a verification link in the terminal.

**Step 5: Access Detailed Vulnerability Reports:**
To gain more insights into the identified vulnerabilities, follow these steps:

> Click on the provided verification link to access the contract page.
> Sign up on SolidityScan, a platform that specializes in analyzing smart contract security.
> Navigate to the "Verified Contracts" section on SolidityScan.
Enter the contract address and select Buildbear as the auditing tool.
> Enter the Node Id associated with your Buildbear deployment.
> Click on "Scan" to initiate a comprehensive analysis of your smart contract.

**Conclusion:**
By following the above steps, you can ensure the security and reliability of your smart contracts. Buildbear, in conjunction with SolidityScan, empowers developers to identify and address vulnerabilities in their contracts effectively. By auditing and securing your smart contracts, you can protect users' funds and data, thereby fostering trust and confidence in your decentralized applications. Happy auditing!

_Note:_ It is important to stay updated with the latest best practices and security measures in the blockchain ecosystem. Always refer to the official documentation of Buildbear and SolidityScan for the most accurate and up-to-date instructions.