Cov txheej txheem:

Wordpress hauv hnab tshos: 6 Kauj ruam
Wordpress hauv hnab tshos: 6 Kauj ruam

Video: Wordpress hauv hnab tshos: 6 Kauj ruam

Video: Wordpress hauv hnab tshos: 6 Kauj ruam
Video: Lis Yaj Pov : Hauv Sab Ntsuj Plig 2024, Kaum ib hlis
Anonim
Wordpress hauv hnab tshos
Wordpress hauv hnab tshos

Raspberry Pi Zero yog lub khoos phis tawj me tshaj plaws hauv tsev neeg Raspberry Pi.

Yooj yim plam hauv koj lub hnab ris, Pi Zero tuaj yeem siv ua Wordpress Server.

Kuv xaiv Wordpress vim nws yog qhov kev daws sai rau tsim lub vev xaib muaj zog yooj yim.

Kauj Ruam 1: Yam Yuav Tsum Tau

Yam Uas Xav Tau
Yam Uas Xav Tau
Yam Uas Xav Tau
Yam Uas Xav Tau
Yam Uas Xav Tau
Yam Uas Xav Tau

1 Raspberry Pi Zero lossis Zero W txuas nrog Internet. Nco ntsoov tias koj tab tom khiav Debian-based operating system xws li Raspbian lossis DietPi. Ubuntu tsis txhawb nqa ntawm Pi Zero, vim Ubuntu tsuas tuaj yeem ua haujlwm ntawm ARMv7 lossis siab dua architecture. Ntawm no kuv tau teeb tsa Pi Zero ntawm USB Ethernet. Koj tseem tuaj yeem ua qhov no ntawm Wi-nkaus.

Nco ntsoov tias SSH tau qhib.

2 Lub khoos phis tawj desktop nrog Internet txuas.

3 Putty davhlau ya nyob twg software (yog siv Windows). Txuas:-

Yog tias koj siv Mac lossis Linux computer, tom qab ntawd qhib lub davhlau ya nyob twg thiab siv "ssh" hais kom ua.

Kauj ruam 2: Tau Txuas

Kev Sib Txuas
Kev Sib Txuas
Kev Sib Txuas
Kev Sib Txuas
Kev Sib Txuas
Kev Sib Txuas

Fais fab Zero thiab txuas nws rau Is Taws Nem siv Wifi lossis USB Ethernet.

Tshawb nrhiav tus IP chaw nyob ntawm koj Pi Zero los ntawm kev nkag mus rau koj lub router. Feem ntau https://192.168.1.1 lossis

Tus router nplooj ntawv kho qhov chaw nyob yog txawv rau routers sib txawv. Koj tuaj yeem pom tus IP teev nyob rau ntawm daim ntawv nplaum nyob tom qab ntawm koj lub router. Lossis nrhiav koj tus qauv router tus IP ntawm Google.

Koj kuj tseem tuaj yeem siv Apple's Bonjour Service uas txhawb nqa Multicast DNS (lossis lub npe host xws li raspberrypi.local)

Koj tuaj yeem rub tawm Bonjour ntawm no:-

Qhov no ua tej yam yooj yim. Koj tuaj yeem siv koj lub npe hostname rau nkag mus rau koj Pi Zero ntawm SSH es tsis txhob nrhiav nws tus IP thiab tom qab ntawv ntaus nws.

Koj kuj tseem tuaj yeem siv cov cuab yeej xws li Advanced IP Scanner. Rub tawm nws ntawm no:-

lossis siv Angry IP Scanner. Rub tawm nws ntawm no:-

Tam sim no nkag mus rau IP chaw nyob rau hauv Putty teeb tsa tus ID nkag mus thiab nkag mus rau koj Pi Zero raws li tus neeg siv pi.

Tam sim no koj tuaj yeem nkag mus rau Pi cov lus txib tam sim ntawd. Thaum koj nkag mus, koj yuav tsum pom:-

pi@raspberrypi ~ $:

Yog tias koj tseem tsis paub yuav ua li cas thiaj pab tau ssh, tom qab ntawv txuas tus ntsuas keyboard thiab nas rau koj Pi Zero.

Qhib lub davhlau ya nyob twg thiab ntaus:

sudo raspi-teeb tsa

Qhov no qhib qhov cuab yeej teeb tsa.

Yog tias koj siv Raspbian Stretch:-

xaiv cov Interfaceing Options, ntaus nkag.

Nws yuav nug yog tias koj xav kom ssh server qhib.

Xaiv yog.

Tab sis yog tias koj siv Raspbian Jessie:-

xaiv qhov Advanced xaiv, ntaus nkag thiab ua tib yam li tau hais los saum no.

Tawm ntawm qhov cuab yeej raspi-teeb tsa

Tam sim no koj yuav tsum rov pib dua koj Pi los ntawm kev ntaus ntawv:-

sudo rov pib dua

Kev rov pib dua tom qab teeb tsa ua kom ntseeg tau tias cov haujlwm hloov pauv.

Tam sim no siv ssh davhlau ya nyob twg ntawm koj lub khoos phis tawj qub. Yog siv windows, Putty, yog siv Linux lossis Mac, ntaus 'ssh' hais kom ua hauv koj lub davhlau ya nyob twg.

Lub npe siv tsis raug yog pi

Thiab tus password tsis raug yog raspberry.

Txhua yam yog nyob hauv qis dua.

Koj tuaj yeem hloov koj tus password, yog koj xav tau, los ntawm kev ntaus:

sudo passwd lus

Kauj Ruam 3: Cov lus txib kom khiav hauv Terminal

Cov lus txib kom khiav hauv Terminal
Cov lus txib kom khiav hauv Terminal
Cov lus txib kom khiav hauv Terminal
Cov lus txib kom khiav hauv Terminal
Cov lus txib kom khiav hauv Terminal
Cov lus txib kom khiav hauv Terminal

Khiav (ntaus cov hauv qab no hauv koj lub davhlau ya nyob twg):-

sudo apt-tau hloov tshiab

sudo apt -tau hloov tshiab -y

Tom qab ntawd rov pib dua koj Pi Zero los ntawm kev ntaus ntawv:-

sudo rov pib dua

Kev rov pib dua yog qhov tsim nyog txhawm rau lub kernel tshiab cuam tshuam txog kev hloov pauv kom siv tau.

sudo apt-tau nruab -y apache2 php libapache2-mod-php mysql-server php-mysql

NCO TSEG:- TSEEM CEEB! THOV NYEEM Hloov pauv php rau php5 libapache2-mod-php5 php5-mysql Yog tias koj siv RASPBIAN JESSIE!

sudo kev pabcuam apache2 rov pib dua

los yog

sudo /etc/init.d/apache2 rov pib dua

Tam sim no hloov cov npe los ntawm kev ntaus ntawv:-

cd/var/www/html

Nov yog qhov pib Apache2 cov npe uas koj tuaj yeem sau cov haujlwm HTML lossis lwm cov haujlwm cuam tshuam nrog kev tsim web xws li.css,.php,.js

Khiav cov hauv qab no rau nruab wordpress thiab muab koj tus kheej ua tswv ntawm cov npe ntawd:-

sudo rm * cov

sudo wget

sudo tar xzf latest.tar.gz

sudo mv wordpress/*.

sudo rm -rf wordpress latest.tar.gz

sudo chown -R www -cov ntaub ntawv:.

Hauv daim duab kawg, Kuv tau rov pib ua haujlwm Apache2 tom qab ua cov khoom tsim nyog hauv/var/www/html phau ntawv teev npe (xws li kev teeb tsa wordpress)

Kauj Ruam 4: Teeb Koj Li Database rau Wordpress

Teeb Koj Li Database rau Wordpress
Teeb Koj Li Database rau Wordpress
Teeb Koj Li Database rau Wordpress
Teeb Koj Li Database rau Wordpress
Teeb Koj Li Database rau Wordpress
Teeb Koj Li Database rau Wordpress

Khiav cov lus txib no:-

sudo mysql_secure_installation

Koj yuav raug nug Sau tus password tam sim no rau hauv paus (nkag rau tsis muaj): - nias Enter.

Ntaus hauv Y thiab nias Enter txhawm rau teeb tsa tus lej password?.

Ntaus tus password ntawm tus password tshiab: sai, thiab nias Enter

NCO TSEG:- YUAV TSUM TSHUAJ! NCO NTSOOV NTAWV PASSWORD koj nkag mus tam sim no, raws li koj xav tau tom ntej.

Hom Y rau:-

Tshem tawm cov neeg siv tsis qhia npe, Txwv tsis pub nkag mus hauv paus nyob deb, Tshem tawm cov ntaub ntawv tshawb fawb thiab nkag mus rau nws, Rov ua dua lub rooj tshwj xeeb tam sim no.

Thaum ua tiav, koj yuav pom cov lus Tag nrho ua tiav! thiab Ua tsaug rau siv MariaDB !.

Tam sim no koj yuav tau txais tos nrog cov lus txib ib txwm ua:- pi@raspberrypi ~ $:

Ntaus hauv cov lus txib no:-

sudo mysql -uroot -p

Tom qab ntawd nkag mus tus password koj tau nkag ua ntej.

Tam sim no koj yuav tau txais tos nrog MariaDB sai (zoo li no>).

Nkag mus rau qhov lus txib no los tsim lub database namd wordpress.

tsim database wordpress;

Nco ntsoov, lub semicolon ntawm qhov kawg ntawm cov lus txib tseem ceeb hauv SQL sytax.

Tam sim no khiav cov lus txib no:-

YOOJ YIM YOOJ YIM YOOJ YIM RAU wordpress.* TO 'root'@'localhost' IDENTIFIED BY 'YOURPASSWORD';

Hloov koj tus password nrog lo lus zais uas koj tau nkag ua ntej.

Tom qab ntawd khiav:-

NTSEEG NTAWV QHOV TSEEB;

Tom qab ntawd nias ctrl + d kom tawm.

Kauj ruam 5: Yuav luag Muaj

Yuav luag Muaj
Yuav luag Muaj
Yuav luag Muaj
Yuav luag Muaj
Yuav luag Muaj
Yuav luag Muaj

Tam sim no qhib qhov browser thiab ntaus koj Pi Zero tus IP chaw nyob. Xaiv koj hom lus thiab nyem Txuas ntxiv. Koj yuav raug nthuav tawm nrog lub vijtsam WordPress. Tam sim no nyem Cia Mus Mus khawm ntawm nplooj ntawv. Nkag mus rau lub npe siv raws li lub hauv paus thiab tus lej cim raws li tus password koj tau nkag ua ntej. Khiav lub Install khawm. Muab koj lub vev xaib lub npe zoo thiab lub npe siv lub hauv paus. Txhua yam ua tiav!

Tam sim no tsuas yog ob peb qhov kawg kov:-

sudo a2enmod rov sau dua

sudo nano /etc/apache2/sites-available/000-default.conf

Ntxiv cov kab no rau cov ntawv tom qab kab 1:- AllowOverride Txhua

Xyuas kom nws nyob hauv.

Nws yuav tsum zoo ib yam li qhov no:-

AllowOverride Txhua

Cov duab qhia txog Kev Txhim Kho ntawm Wordpress ib qib zuj zus. Plaub qhov kawg qhia qhov kov kawg. Tom qab ntawd khiav:-

sudo kev pabcuam apache2 rov pib dua

Txhawm rau rov pib dua Apache2 kev pabcuam.

Kauj Ruam 6: Koj Tus Kheej Lub Vev Xaib

Koj Tus Kheej Tus Kheej
Koj Tus Kheej Tus Kheej
Koj Tus Kheej Tus Kheej
Koj Tus Kheej Tus Kheej
Koj Tus Kheej Tus Kheej
Koj Tus Kheej Tus Kheej

Hauv daim duab kawg yog kuv lub vev xaib sim, raws li kuv tau kho nws hauv nplooj ntawv Customizing uas tau qhia hauv daim duab dhau los. Koj tuaj yeem nkag mus (daim duab 1) thiab hloov kho koj nplooj ntawv, ntxiv cov ntsiab lus, fonts thiab txhua yam khoom ntawd rau koj lub vev xaib yooj yim (daim duab 2). Koj tseem tuaj yeem txhim kho cov ntsiab lus tshiab. NCO TSEG:- Kuv tsis tau xa kuv cov Raspberry Pi Zero, yog li, koj yuav tsis tuaj yeem pom kuv lub vev xaib tshwj tsis yog thiab txog thaum koj txuas nrog tib lub network kuv siv (piv txwv li kuv lub tsev router)

Kuv vam tias koj nyiam ua koj tus kheej Pocket-Sized Wordpress Server siv Raspberry Pi Zero lossis Zero W.

Bye thiab Zoo Siab Web Tsim!:):):):)

Pom zoo: