# Shopware 6 installation with shopware-installer.phar.php problem

**URL:** https://forum.shopware.com/t/shopware-6-installation-with-shopware-installer-phar-php-problem/100843
**Category:** Shopware 6 (English)
**Created:** [13. August 2023 um 08:11 UTC](https://forum.shopware.com/t/shopware-6-installation-with-shopware-installer-phar-php-problem/100843 "2023-08-13T08:11:34Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![webber92](https://avatars.discourse-cdn.com/v4/letter/w/59ef9b/32.png) [@webber92](https://forum.shopware.com/u/webber92)
#### Post date: [13. August 2023 um 08:11 UTC](https://forum.shopware.com/t/shopware-6-installation-with-shopware-installer-phar-php-problem/100843/1 "2023-08-13T08:11:34Z")

</div>

Hi there!

I’m pretty new to this CMS but I want to explore it from the admin side.

I’m trying to install the shopware 6 via this instruction: [Shopware 6 - First Steps - Installation](https://docs.shopware.com/en/shopware-6-en/first-steps/installing-shopware-6)

On server installed everything that is required by shopware:

php8.1 - with all the extensions it needs  
Nginx  
mariaDB  
NodeJS18

Nginx configuration:

```auto
server {
# listen 80;
    listen 40.118.124.129:80;
    index index.php index.html;
    server_name 40.118.124.129;

    client_max_body_size 32M;

    root /var/www/html/shopware;

    location /recovery/update/ {
        index index.php;
        try_files $uri /recovery/install/index.php$is_args$args;
    }

    location ~ ^/(recovery\/update\/index|index|shopware-installer\.phar)\.php(/|$) {
        fastcgi_split_path_info ^(.+\.php)(/.+)$;
        include fastcgi.conf;
        fastcgi_param HTTP_PROXY "";
        fastcgi_buffers 8 16k;
        fastcgi_buffer_size 32k;
        proxy_connect_timeout 300s;
        proxy_send_timeout 300s;
        proxy_read_timeout 300s;
        send_timeout 300s;
        client_body_buffer_size 128k;
        fastcgi_pass unix:/run/php/php8.1-fpm.sock;
    }

    location = /sitemap.xml {
            log_not_found off;
            access_log off;
            try_files $uri /;
    }

    location = /robots.txt {
            log_not_found off;
            access_log off;
            try_files $uri /;
    }

    location ~* ^.+\.(?:css|cur|js|jpe?g|gif|ico|png|svg|webp|avif|html|woff|woff2|xml)$ {
        expires 1y;
        add_header Cache-Control "public, must-revalidate, proxy-revalidate";

        access_log off;

        # The directive enables or disables messages in error_log about files not found on disk.
        log_not_found off;

        tcp_nodelay off;

        ## Set the OS file cache.
        open_file_cache max=3000 inactive=120s;
        open_file_cache_valid 45s;
        open_file_cache_min_uses 2;
        open_file_cache_errors off;

        location ~* ^.+\.svg$ {
            add_header Content-Security-Policy "script-src 'none'";
        }
    }

    location / {
        try_files $uri /index.php$is_args$args;
    }
}

```

But for some reason when I try accessing the [http://40.118.124.129/shopware/shopware-installer.phar.php](http://40.118.124.129/shopware/shopware-installer.phar.php)  
It doesn’t start the installation, it only download the file.

The only thing that I think is that in the instruction provided it’s setup with apache2 and .htaccess file. But I don’t see a reason why it wouldn’t work with nginx. But if that is the case please advise.

Or maybe I’m missing something?

Kindest regards and thank you in advanced!

Alex

---

<div class="post-metadata">

### Author: ![tim2](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/tim2/32/19833_2.png) [@tim2](https://forum.shopware.com/u/tim2)
#### Post date: [10. November 2023 um 08:39 UTC](https://forum.shopware.com/t/shopware-6-installation-with-shopware-installer-phar-php-problem/100843/2 "2023-11-10T08:39:50Z")

</div>

You could try this example code:

```auto
# Enable Shopware 6.5 installer
location /shopware-installer.phar.php {
    try_files $uri /shopware-installer.phar.php$is_args$args;
}

# Run static files generated by shopware-installer.phar.php through PHP
location ~ ^/shopware-installer\.phar\.php/.+\.(?:css|js|png|svg|woff)$ {
     try_files $uri /shopware-installer.phar.php$is_args$args;
}

location /recovery/install {
    index index.php;
    try_files $uri /recovery/install/index.php$is_args$args;
}

location /recovery/update/ {
    if (!-e $request_filename){
        rewrite . /recovery/update/index.php last;
    }
}

location ~* ^.+\.(?:css|cur|js|jpe?g|gif|ico|png|svg|webp|htm|woff|woff2|xml)$ {
   expires 1y;
   add_header Cache-Control "public, must-revalidate, proxy-revalidate";

   access_log off;

   # The directive enables or disables messages in error_log about files not found on disk.
   log_not_found off;

   tcp_nodelay off;

   ## Set the OS file cache.
   open_file_cache max=3000 inactive=120s;
   open_file_cache_valid 45s;
   open_file_cache_min_uses 2;
   open_file_cache_errors off;

}

 location ~* ^.+\.svg$ {
       add_header Content-Security-Policy "script-src 'none'";
   }

    # Forward any not found file to index.php. Also allows to have beautiful urls like /homemade-products/
    location / {
        try_files $uri /index.php$is_args$args;
    }

   # Let php-fpm handle .php files
        location ~ \.php$ {
        fastcgi_split_path_info ^(.+\.php)(/.+)$;
        include fastcgi.conf;
        fastcgi_param HTTP_PROXY "";
        fastcgi_buffers 8 16k;
        fastcgi_buffer_size 32k;
        fastcgi_read_timeout 300s;
        client_body_buffer_size 128k;
        fastcgi_pass unix:/run/php/php8.1-fpm.sock;
        http2_push_preload on;
    }

```

---

<div class="post-metadata">

### Author: ![Misengo](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/misengo/32/21446_2.png) [@Misengo](https://forum.shopware.com/u/Misengo)
#### Post date: [5. Februar 2024 um 13:58 UTC](https://forum.shopware.com/t/shopware-6-installation-with-shopware-installer-phar-php-problem/100843/3 "2024-02-05T13:58:50Z")

</div>

You will find the updated NGINX config in the developer docs.

> **[Nginx | Shopware Documentation](https://developer.shopware.com/docs/resources/references/config-reference/server/nginx.html)**
>
> Documentation for Shopware developers

We will also cover the NGINX config in the user docs soon 👋

---

<div class="post-metadata">

### Author: ![mohanjoy23](https://avatars.discourse-cdn.com/v4/letter/m/ed8c4c/32.png) [@mohanjoy23](https://forum.shopware.com/u/mohanjoy23)
#### Post date: [20. August 2024 um 12:39 UTC](https://forum.shopware.com/t/shopware-6-installation-with-shopware-installer-phar-php-problem/100843/4 "2024-08-20T12:39:03Z")

</div>

> [@tim2](#):
>
> ```auto
> # Enable Shopware 6.5 installer
> location /shopware-installer.phar.php {
> try_files $uri /shopware-installer.phar.php$is_args$args;
> }
> 
> ```

I have added the line below to my domain.conf file(Using Nginx and php-fpm), then the issue fixed now working fine

```auto
# Enable Shopware 6.5 installer
location /shopware-installer.phar.php {
    try_files $uri /shopware-installer.phar.php$is_args$args;
}
```
