mirror of
https://dev.azure.com/tstanciu94/PhantomMind/_git/Bitip
synced 2025-10-13 01:52:19 +03:00
feat: update version info structure to use buildDate and commitHash instead of createdAt and gitRevision
This commit is contained in:
parent
11bd4fbe18
commit
0c2bdb3d11
@ -256,8 +256,8 @@ router.get('/version', (_req: Request, res: Response): void => {
|
||||
try {
|
||||
res.json({
|
||||
version: process.env.APP_VERSION || '1.0.0',
|
||||
createdAt: process.env.CREATED_AT || 'unknown',
|
||||
gitRevision: process.env.GIT_REVISION || 'unknown',
|
||||
buildDate: process.env.CREATED_AT || 'unknown',
|
||||
commitHash: process.env.GIT_REVISION || 'unknown',
|
||||
service: 'Bitip GeoIP Service',
|
||||
});
|
||||
} catch (error) {
|
||||
|
@ -11,8 +11,8 @@ import { pathCombine } from '@flare/utiliyo';
|
||||
|
||||
interface VersionInfo {
|
||||
version: string;
|
||||
createdAt: string;
|
||||
gitRevision: string;
|
||||
buildDate: string;
|
||||
commitHash: string;
|
||||
service: string;
|
||||
}
|
||||
|
||||
@ -90,8 +90,8 @@ const App: React.FC = () => {
|
||||
{versionInfo && (
|
||||
<p className="version-info">
|
||||
Version {versionInfo.version}
|
||||
{versionInfo.createdAt !== 'unknown' &&
|
||||
` | Released ${new Date(versionInfo.createdAt).toLocaleString()}`}
|
||||
{versionInfo.buildDate !== 'unknown' &&
|
||||
` | Released ${new Date(versionInfo.buildDate).toLocaleString()}`}
|
||||
</p>
|
||||
)}
|
||||
</footer>
|
||||
|
@ -67,8 +67,8 @@ export interface IPResponse {
|
||||
|
||||
export interface VersionInfo {
|
||||
version: string;
|
||||
createdAt: string;
|
||||
gitRevision: string;
|
||||
buildDate: string;
|
||||
commitHash: string;
|
||||
service: string;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user