Skip to content

Sådan installeres Joomla med Nginx på Rocky Linux

Cloud Infrastructure Expert
Sådan installeres Joomla med Nginx på Rocky Linux

 

Følg denne trin-for-trin guide for at installere Joomla på din server kørende Rocky Linux.

Trin 1: Opdater dit system

Før du installerer software, er det vigtigt at opdatere systempakkerne:

sudo dnf update -y

Trin 2: Installer nødvendige pakker

Installer de nødvendige pakker til at køre Joomla:

sudo dnf install -y epel-release
sudo dnf install -y nginx php php-fpm php-mysqlnd php-xml php-mbstring php-curl php-zip

Trin 3: Start og aktiver Nginx og PHP-FPM

Start Nginx- og PHP-FPM-tjenesterne og aktiver dem til at starte ved opstart:

sudo systemctl start nginx
sudo systemctl enable nginx
sudo systemctl start php-fpm
sudo systemctl enable php-fpm

Trin 4: Konfigurer Nginx til Joomla

Opret en ny konfigurationsfil til Joomla i Nginx-konfigurationsmappen:

sudo nano /etc/nginx/conf.d/joomla.conf

Tilføj følgende konfiguration:

server {
    listen 80;
    server_name your_domain.com;  # Erstat med dit domæne

    root /var/www/html/joomla;  # Erstat med din Joomla-mappe
    index index.php index.html index.htm;

    location / {
        try_files $uri $uri/ /index.php?$query_string;
    }

    location ~ \.php$ {
        include fastcgi_params;
        fastcgi_pass unix:/var/run/php-fpm/www.sock;
        fastcgi_index index.php;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
    }
}

Gem og afslut filen.

Trin 5: Download Joomla

Gå til webroot-mappen og download Joomla:

cd /var/www/html
wget https://downloads.joomla.org/latest-stable/joomla-4.x.x.zip  # Tjek for den nyeste version

Udpak den downloaded fil:

unzip joomla-4.x.x.zip
mv joomla/* joomla/.htaccess .

Trin 6: Indstil tilladelser

Indstil de passende tilladelser for Joomla-mappen:

sudo chown -R nginx:nginx /var/www/html/joomla
sudo chmod -R 755 /var/www/html/joomla

Trin 7: Test Nginx-konfigurationen

Før du genstarter Nginx, skal du teste konfigurationen for syntaksfejl:

sudo nginx -t

Trin 8: Genstart Nginx

Hvis testen var vellykket, skal du genstarte Nginx:

sudo systemctl restart nginx

Trin 9: Afslut Joomla-installationen

Åbn din webbrowser og gå til http://your_domain.com (erstat med dit faktiske domæne). Følg instruktionerne på skærmen for at afslutte Joomla-installationen.

Konklusion

Du har nu succesfuldt installeret Joomla på din server ved hjælp af Nginx på Rocky Linux. Du kan nu begynde at opbygge dit websted!

Windows VPS Deutschland

Windows VPS España

Windows VPS Nederland

Windows VPS Italia

Windows VPS Portugal

VPS Windows Italia

Windows VPS

Windows VPS

Windows VPS Sverige

Windows VPS Norge

Windows VPS

Windows VPS Türkiye

Windows RDS (Remote Desktop Services)

Windows VPS

Explore more

More on this topic

Netcloud24
Netcloud24
Cloud Infrastructure Expert · NetCloud24

Comments are closed.