mirror of
https://github.com/Dannecron/parcel-example-neko.git
synced 2025-12-25 15:22:37 +03:00
[feature] add version route
This commit is contained in:
@@ -11,5 +11,7 @@ RUN npm run-script build
|
|||||||
|
|
||||||
FROM nginx:1.23.2 as runtume
|
FROM nginx:1.23.2 as runtume
|
||||||
|
|
||||||
|
ENV APP_VERSION=latest
|
||||||
|
|
||||||
COPY ./nginx/templates /etc/nginx/templates
|
COPY ./nginx/templates /etc/nginx/templates
|
||||||
COPY --from=build /opt/neko/dist /opt/neko/dist
|
COPY --from=build /opt/neko/dist /opt/neko/dist
|
||||||
|
|||||||
@@ -14,4 +14,9 @@ server {
|
|||||||
root /opt/neko/dist;
|
root /opt/neko/dist;
|
||||||
index index.html;
|
index index.html;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
location /version {
|
||||||
|
default_type application/json;
|
||||||
|
return 200 '{"version": "$APP_VERSION"}';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user