Your ROOT_URL in app.ini is https://git.ondrovo.com/ but you are visiting http://159.69.29.240:49153/espterm/espterm-front-end/commit/e34ded0b8ceaaa6418df0ff884772dedab7e9861?style=unified&whitespace=ignore-all
You should set ROOT_URL correctly, otherwise the web may not work correctly.
4 changed files with
9 additions and
4 deletions
_build_common.sh
_build_css.sh
pages/_head.php
webpack.config.js
@ -1,3 +1,7 @@
#!/bin/bash
export FRONT_END_HASH = $( git rev-parse --short HEAD)
if [ -z " $ESP_LANG " ] ; then
export ESP_LANG = en
fi
@ -10,4 +10,4 @@ else
fi
mkdir -p out/css
npm run sass -- --output-style ${ stylearg } sass/app.scss " out/css/app. $FRONT_END_HASH .css "
npm run sass -- --output-style ${ stylearg } sass/app.scss " out/css/app. $FRONT_END_HASH - $ESP_LANG .css"
@ -5,8 +5,8 @@
< meta http-equiv = "X-UA-Compatible" content = "IE=edge" >
< meta name = "viewport" content = "width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1" >
< title > <? = $_GET [ 'PAGE_TITLE' ] ?> </ title >
< link href = "/css/app. <? = GIT_HASH ?> .css" rel = "stylesheet" >
< script src = "/js/app. <? = GIT_HASH ?> .js" ></ script >
< link href = "/css/app. <? = GIT_HASH . '-' . LOCALE ?> .css" rel = "stylesheet" >
< script src = "/js/app. <? = GIT_HASH . '-' . LOCALE ?> .js" ></ script >
< script >
var _root = <? = JS_WEB_ROOT ?> ;
var _demo = <? = ( int ) ESP_DEMO ?> ;
@ -3,6 +3,7 @@ const { execSync } = require('child_process')
const path = require ( 'path' )
let hash = execSync ( 'git rev-parse --short HEAD' ) . toString ( ) . trim ( )
let lang = process . env . ESP _LANG || 'en'
let plugins = [ ]
let devtool = 'source-map'
@ -23,7 +24,7 @@ module.exports = {
entry : './js' ,
output : {
path : path . resolve ( _ _dirname , 'out' , 'js' ) ,
filename : ` app. ${ hash } .js `
filename : ` app. ${ hash } - ${ lang } .js `
} ,
module : {
rules : [