Angular 5, Apache2

0

Witam,

Mam aplikację SPA (angular 5), mam do tego aplikację która wystawia restowe API w Javie.
Nie potrafię tego skomunikować na serwerze - posiadam Apache2(tutaj jest aplikacja w angularze ) + Tomcat8 (backend po localhost)

<VirtualHost *:80>
    ServerAdmin root@localhost
    ServerName app.servname.com
    ServerAlias www.app.servname.com
    DefaultType text/html

    ServerAdmin webmaster@localhost
    DocumentRoot /var/www/pb

        <Directory /var/www/pb>
        RewriteEngine on

        # Don't rewrite files or directories
        RewriteCond %{REQUEST_FILENAME} -f [OR]
        RewriteCond %{REQUEST_FILENAME} -d
        RewriteRule ^ - [L]

        # Rewrite everything else to index.html
        # to allow html5 state links
        RewriteRule ^ index.html [L]
    </Directory>

</VirtualHost>

Próbowałem dodać

ProxyPass "/api" "localhost:8080/"
ProxyPassReverse "/api" "localhost:8080/"

ale wtedy nawet server nie chce wystartować wg

0

Odblokowałeś stronę w Apache?
sudo a2ensite nazwa_aplikacji

Przeładowywałeś Apache?
service apache2 reload

Katalog z aplikacją frontową ma odpowiednie uprawnienia?
sudo chmod -R 755 /var/www/nazwa_aplikacji

1 użytkowników online, w tym zalogowanych: 0, gości: 1