Skip to content

Instantly share code, notes, and snippets.

View codedeep79's full-sized avatar

Nguyễn Trung Hậu codedeep79

View GitHub Profile
@codedeep79
codedeep79 / Check Apache Server Status.md
Created July 31, 2022 09:09
Check Apache Server Status on Ubuntu

Systemctl Utility

sudo systemctl status apache2

@codedeep79
codedeep79 / Cài đặt Joomla trên Ubuntu 22.04 với LAMP Stack.md
Last active July 31, 2022 10:26
Cài đặt Joomla trên Ubuntu 22.04 với LAMP Stack

Prerequisites

Step 1 — Creating a MySQL Database and User for Joomla

To get started, log into the MySQL root (administrative) account by issuing the following command: sudo mysql -u root -p To create a database, database user, and grant all privileges to the database user run the following commands:

mysql> CREATE DATABASE joomla DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;
mysql> CREATE USER 'joomlauser'@'%' IDENTIFIED WITH mysql_native_password BY 'your_password';
@codedeep79
codedeep79 / Cài đặt Drupal trên Ubuntu 22.04 với LAMP Stack.md
Last active August 1, 2022 02:24
Cài đặt Drupal trên Ubuntu 22.04 với LAMP Stack

Prerequisites

Step 1 — Creating a MySQL Database and User for Drupal

To get started, log into the MySQL root (administrative) account by issuing the following command: sudo mysql -u root -p To create a database, database user, and grant all privileges to the database user run the following commands:

mysql> CREATE DATABASE drupal DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;
mysql> CREATE USER 'drupaluser'@'%' IDENTIFIED WITH mysql_native_password BY 'your_password';
@codedeep79
codedeep79 / Cài đặt Memcached trên Ubuntu.md
Last active August 1, 2022 04:35
Cài đặt Memcached trên Ubuntu

Memcached is a free and open-source high-performance in-memory key-value data store. It is generally used to speed up applications by caching various objects from the results of API and database calls.

Installing Memcached

To install it, enter the following command as root or user with sudo privileges:

sudo apt update
sudo apt install memcached libmemcached-tools

The libmemcached-tools package provides command-line utilities that you can use to manage the memcached server.

@codedeep79
codedeep79 / Cài đặt và cấu hình Redis trên Ubuntu 22.04.md
Last active August 3, 2022 08:05
Cài đặt và cấu hình Redis trên Ubuntu 22.04

Redis is an open-source, freely-available data structure store that is utilized as a cache, message broker, and key-value database. It offers support for geospatial indexes, Strings, sets, bitmaps, hyper logs, hashes, streams, sorted sets with range queries, and lists.

Step 1: Update system packages

First of all, hit "CTRL+ALT+T" and update the system packages with the help of the following command: sudo apt update

Step 2: Add PPA repository

In the next step, we will add the "redislabs" PPA repository to our Ubuntu 22.04 system:

sudo add-apt-repository ppa:redislabs/redis

@codedeep79
codedeep79 / Cài đặt Next.js trên Ubuntu.md
Last active August 1, 2022 05:46
Cài đặt Next.js trên Ubuntu

Prerequisite:

Initialize the Next.js project development environment

Now, we’ll itialize the Next.js project development environment with the npx CLI build tool:

npx create-next-app project-name

Note: Replace the project-name with you desired project name.

@codedeep79
codedeep79 / Cài đặt Ionic Framework trên Ubuntu.md
Last active August 3, 2022 08:05
Cài đặt Ionic Framework trên Ubuntu

Prerequisites

Login to your Ubuntu system using sudo privileged user. Then update the system packages to latest:

sudo apt update && sudo apt upgrade

Step 2 – Install Cordova

After installing Node.js on your system run the following command to install Cordova: sudo npm install -g cordova

@codedeep79
codedeep79 / Cài đặt Python 3 và thiết lập môi trường lập trình trên Ubuntu.md
Last active August 2, 2022 02:22
Cài đặt Python 3 và thiết lập môi trường lập trình trên Ubuntu

Step 1 — Install Python 3

Step 2 — Install pip

To manage software packages for Python, install pip, a tool that will help you manage libraries or modules to use in your projects:

sudo apt install -y python3-pip

Python packages can be installed by typing:

pip3 install package_name
@codedeep79
codedeep79 / Cài đặt MongoDB 5 trên Ubuntu 22.04 | 20.04 | 18.04.md
Last active August 2, 2022 06:22
Cài đặt MongoDB 5 trên Ubuntu 22.04 | 20.04 | 18.04

Step 1: Import MongoDB GPG Key

Update APT package index and install basic utility packages required:

sudo apt update
sudo apt install wget curl gnupg2 software-properties-common apt-transport-https ca-certificates lsb-release

We first need to import MongoDB public GPG key as below:

curl -fsSL https://www.mongodb.org/static/pgp/server-5.0.asc|sudo gpg --dearmor -o /etc/apt/trusted.gpg.d/mongodb.gpg
@codedeep79
codedeep79 / Cài đặt và thiết lập Angular trên Ubuntu.md
Created August 2, 2022 22:58
Cài đặt và thiết lập Angular trên Ubuntu

Update NPM(Optional)

Node Package Manager(NPM) is needed to install Angular CLI. It will install with the Nodejs itself, but we can update it to the latest version using the below command:

sudo npm install npm@latest -g

Install Angular CLI

Angular CLI helps us to create projects, generate application and library code. It can simply install using NPM. So open Terminal and install the Angular CLI with the below command: