Compare commits
2 Commits
a7dbf76500
...
66523af257
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
66523af257 | ||
|
|
f988312323 |
16
Dockerfile
Normal file
16
Dockerfile
Normal file
@@ -0,0 +1,16 @@
|
||||
FROM nginx:alpine
|
||||
|
||||
# 删除 nginx 默认配置
|
||||
RUN rm /etc/nginx/conf.d/default.conf
|
||||
|
||||
# 创建配置文件
|
||||
COPY nginx.conf /etc/nginx/conf.d/default.conf
|
||||
|
||||
# 将构建好的文件复制到 nginx
|
||||
COPY web /usr/share/nginx/html
|
||||
|
||||
# 暴露端口
|
||||
EXPOSE 80
|
||||
|
||||
# 启动 nginx
|
||||
CMD ["nginx", "-g", "daemon off;"]
|
||||
@@ -1,7 +1,7 @@
|
||||
//开发环境
|
||||
module.exports = {
|
||||
NODE_ENV: '"development"',
|
||||
BASE_API: '"http://127.0.0.1"',
|
||||
DOMAIN: '"http://localhost:8081"',
|
||||
SOCKET_URL:'"ws://127.0.0.1:8326/"'
|
||||
BASE_API: '"http://124.222.155.209"',
|
||||
DOMAIN: '"http://124.222.155.209"',
|
||||
SOCKET_URL:'"ws://124.222.155.209:8326/"'
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
//测试环境
|
||||
//生产环境
|
||||
module.exports = {
|
||||
NODE_ENV: '"production"',
|
||||
BASE_API:'"http://47.75.125.96"',
|
||||
DOMAIN: '"http://47.75.125.96"',
|
||||
SOCKET_URL:'"ws://47.75.47.120:8326"'
|
||||
BASE_API:'"http://124.222.155.209"',
|
||||
DOMAIN: '"http://124.222.155.209"',
|
||||
SOCKET_URL:'"ws://124.222.155.209:8326"'
|
||||
}
|
||||
|
||||
BIN
dist/coin-portal-dist.tar.gz
vendored
Normal file
BIN
dist/coin-portal-dist.tar.gz
vendored
Normal file
Binary file not shown.
34
nginx.conf
Normal file
34
nginx.conf
Normal file
@@ -0,0 +1,34 @@
|
||||
server {
|
||||
listen 80;
|
||||
server_name _;
|
||||
|
||||
root /usr/share/nginx/html;
|
||||
index index.html index.htm;
|
||||
|
||||
# 处理 Vue Router 的历史模式
|
||||
location / {
|
||||
try_files $uri $uri/ /index.html;
|
||||
}
|
||||
|
||||
# 后台管理系统代理 (如果需要)
|
||||
# location /admin/ {
|
||||
# proxy_pass http://coin-manager:80/;
|
||||
# }
|
||||
|
||||
# 静态资源缓存
|
||||
location ~* \.(js|css|png|jpg|jpeg|gif|ico|svg|woff|woff2|ttf|eot)$ {
|
||||
expires 30d;
|
||||
add_header Cache-Control "public, immutable";
|
||||
}
|
||||
|
||||
# 禁用缓存 index.html
|
||||
location = /index.html {
|
||||
expires -1;
|
||||
add_header Cache-Control "no-cache, no-store, must-revalidate";
|
||||
}
|
||||
|
||||
# Gzip 压缩
|
||||
gzip on;
|
||||
gzip_types text/plain text/css application/json application/javascript text/xml application/xml;
|
||||
gzip_min_length 1024;
|
||||
}
|
||||
@@ -1,9 +1,6 @@
|
||||
window.config={
|
||||
// 测试环境服务器地址
|
||||
socketServer:'ws://127.0.0.1:8326/',
|
||||
ajaxServer: 'http://127.0.0.1',
|
||||
// 生产环境服务器地址
|
||||
//socketServer:'ws://103.71.178.73:8326/',
|
||||
//ajaxServer: 'http://103.71.178.73/v2/s'
|
||||
socketServer:'ws://124.222.155.209:8326/',
|
||||
ajaxServer: 'http://124.222.155.209',
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user