Witam serdecznie. Mam aplikacje w angularze 7 + spring. Chciałbym podpiąć do niej jenkinsa by automatycznie wrzucał ją na serwer. Cel wydawał się prosty jednak jest jeden problem. Gdy wrzucam do tomcata aplikacje spakowaną do wara jest ona pusta. Biała strona i wyskakują takie błędy.
GET http://localhost:8080/styles.8421fe1235bb3d72609e.css net::ERR_ABORTED 404
3localhost/:18 GET http://localhost:8080/polyfills.695b1e0ee8348a669d98.js net::ERR_ABORTED 404
localhost/:14 GET http://localhost:8080/styles.8421fe1235bb3d72609e.css net::ERR_ABORTED 404
3localhost/:18 GET http://localhost:8080/runtime.45489ea8ef544e7e057c.js net::ERR_ABORTED 404
Gdy wejdę sobie do folderu z angularem lokalnie i dam tam ng build --prod , nastepnie przejdę do /dist/webapp i odpale w przegladarce index.html jest to samo:
runtime.45489ea8ef544e7e057c.js:1 Failed to load resource: the server responded with a status of 404 (Not Found)
index.html:1 Refused to apply style from 'http://localhost:63342/library/styles.8421fe1235bb3d72609e.css' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled.
polyfills.695b1e0ee8348a669d98.js:1 Failed to load resource: the server responded with a status of 404 (Not Found)
main.77ab10e32b46369b7ac6.js:1 Failed to load resource: the server responded with a status of 404 (Not Found)
index.html:1 Refused to apply style from 'http://localhost:63342/library/styles.8421fe1235bb3d72609e.css' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled.
runtime.45489ea8ef544e7e057c.js:1 Failed to load resource: the server responded with a status of 404 (Not Found)
polyfills.695b1e0ee8348a669d98.js:1 Failed to load resource: the server responded with a status of 404 (Not Found)
main.77ab10e32b46369b7ac6.js:1 Failed to load resource: the server responded with a status of 404 (Not Found)
index.html:1 Refused to apply style from 'http://localhost:63342/library/styles.8421fe1235bb3d72609e.css' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled.
Jak rozwiązać ten problem ? Widac tutaj że nie może znaleźć plików css i js ale dlaczego ? Nawet lokalnie jest problem.. Próbowałem z internecie szukać rozwiązania ale żadne u mnie nie działa i już nie mam pomysłów. Jakby ktoś miał chwile i mógł zobaczyć :) Dziekuję !
Link do gita: https://github.com/tomaszReda/library