Hướng dẫn cài đặt server Ubuntu 20.4
Cài đặt Apache 2.4
- Chạy lệnh để update các repository
- Tiến hành cài đặt apache 2.4
- Truy cập test thử website bằng đường dẫn http://your_server_ip
Cài đặt mariadb (Mysql)
- Cài đặt mật khẩu cho tài khoản root
- Đối với lần đầu mật khẩu root mặc định là trống ở phần câu hỏi
Enter current password for root (enter for none):
bấm enter để xác nhận
Set root password? [Y/n]
: Chọn Y.
- Nhập 2 lần mật khẩu để khởi tạo mật khẩu root cho mysql
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
Cài đặt PHP và các extension cần thiết để chạy laravel
- Chạy lệnh để update các repository
Thao tác thêm
- Mở mod rewrite để htaccess hoạt động
- Sao khi mở mod của apache phải khởi động lại service
- Trường hợp code PHP không được thực thi (hiển thị ra toàn bộ thông tin code) : Chạy lệnh để mở mod PHP cho apache2
Nguồn tham khảo:
https://www.digitalocean.com/community/tutorials/how-to-install-linux-apache-mysql-php-lamp-stack-on-ubuntu-20-04
https://www.digitalocean.com/community/tutorials/how-to-install-mariadb-on-ubuntu-20-04