美文网首页
Elasticsearch:Failed at the phan

Elasticsearch:Failed at the phan

作者: 心淡然如水 | 来源:发表于2021-01-23 09:42 被阅读0次

    问题一:

    npm ERR! code ELIFECYCLE
    npm ERR! errno 1
    npm ERR! phantomjs-prebuilt@2.1.16 install: `node install.js`
    npm ERR! Exit status 1
    npm ERR! 
    npm ERR! Failed at the phantomjs-prebuilt@2.1.16 install script.
    npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
    
    npm ERR! A complete log of this run can be found in:
    
    

    执行npm install phantomjs-prebuilt@2.1.16 --ignore-scripts命令用来安装phantomjs-prebuilt@2.1.16,–ignore-scripts参数用于npm install在安装phantomjs-prebuilt@2.1.16时忽略package.json中设置的脚本,意思就是避免package.json中的脚本影响包的正常安装。

    问题二:

    解决网站访问跨域问题

            # ---------------------------------- Network -----------------------------------
            #
            # Set the bind address to a specific IP (IPv4 or IPv6):
            #
            network.host: 0.0.0.0
            #
            # Set a custom port for HTTP:
            #
            http.port: 9200
            #
            # For more information, consult the network module documentation.
            #
            #添加跨域请求
            http.cors.enabled: true
            http.cors.allow-origin: "*"
    

    相关文章

      网友评论

          本文标题:Elasticsearch:Failed at the phan

          本文链接:https://www.haomeiwen.com/subject/ckvyzktx.html