show ci/cd build meta data in layout

This commit is contained in:
Nuwan 2021-10-27 16:05:51 +05:30
parent cf21f61985
commit 9fe595e523
3 changed files with 22 additions and 2 deletions

View File

@ -2,4 +2,6 @@ HOST=beta.jamkazam.local
PORT=4000
REACT_APP_ORIGIN=jamkazam.local
REACT_APP_LEGACY_BASE_URL=http://www.jamkazam.local:3000
REACT_APP_API_BASE_URL=http://www.jamkazam.local:3000/api
REACT_APP_API_BASE_URL=http://www.jamkazam.local:3000/api
REACT_APP_BITBUCKET_BUILD_NUMBER=dev
REACT_APP_BITBUCKET_COMMIT=dev

View File

@ -0,0 +1,17 @@
import React from 'react';
function JKBuildMeta() {
return (
<div
className="build-meta"
dangerouslySetInnerHTML={{
__html: `<!--
BITBUCKET_BUILD_NUMBER: ${process.env.REACT_APP_BITBUCKET_BUILD_NUMBER}
BITBUCKET_COMMIT: ${process.env.REACT_APP_BITBUCKET_COMMIT}
-->`
}}
/>
);
}
export default JKBuildMeta;

View File

@ -5,7 +5,7 @@ import { CloseButton, Fade } from '../components/common/Toast';
import DashboardLayout from './JKDashboardLayout';
import ErrorLayout from './ErrorLayout';
import BuildMeta from "./JKBuildMeta";
const Layout = () => {
return (
@ -15,6 +15,7 @@ const Layout = () => {
<Route component={DashboardLayout} />
</Switch>
<ToastContainer transition={Fade} closeButton={<CloseButton />} position={toast.POSITION.BOTTOM_RIGHT} />
<BuildMeta />
</Router>
);
};