Skip to content

Commit 39b40e4

Browse files
committed
Merge remote-tracking branch 'origin/stage-hccm' into prod-hccm
2 parents ddc2fea + 0144941 commit 39b40e4

File tree

20 files changed

+42
-87
lines changed

20 files changed

+42
-87
lines changed
File renamed without changes.
File renamed without changes.

apps/koku-ui-hccm/fec.config.js

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
// Based on https://github.com/RedHatInsights/frontend-components/blob/master/packages/config/src/bin/dev.webpack.config.ts
22

33
const CopyWebpackPlugin = require('copy-webpack-plugin');
4+
const { GitRevisionPlugin } = require('git-revision-webpack-plugin');
45
const path = require('path');
56
const webpack = require('webpack');
6-
const { dependencies, insights } = require('./package.json');
7+
const { dependencies, insights, name } = require('./package.json');
78

89
const moduleName = insights.appname.replace(/-(\w)/g, (_, match) => match.toUpperCase());
910
const srcDir = path.resolve(__dirname, './src');
@@ -14,6 +15,7 @@ const stats = {
1415
colors: true,
1516
modules: false,
1617
};
18+
const gitRevisionPlugin = new GitRevisionPlugin();
1719

1820
// Show what files changed since last compilation
1921
class WatchRunPlugin {
@@ -85,6 +87,11 @@ module.exports = {
8587
},
8688
],
8789
}),
90+
gitRevisionPlugin,
91+
new webpack.DefinePlugin({
92+
'process.env.KOKU_UI_COMMITHASH': JSON.stringify(gitRevisionPlugin.commithash()),
93+
'process.env.KOKU_UI_PKGNAME': JSON.stringify(name),
94+
}),
8895
],
8996
resolve: {
9097
modules: [srcDir, path.resolve(__dirname, '../../node_modules')],

apps/koku-ui-hccm/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,7 @@
115115
"@types/react-redux": "^7.1.34",
116116
"@types/react-router-dom": "^5.3.3",
117117
"copy-webpack-plugin": "^13.0.1",
118+
"git-revision-webpack-plugin": "^5.0.0",
118119
"globals": "^16.5.0",
119120
"identity-obj-proxy": "^3.0.0",
120121
"ts-patch": "^3.3.0",

apps/koku-ui-hccm/src/app.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import './app.scss';
22

3+
import UiVersion from '@koku-ui/ui-lib/components/page/uiVersion';
34
import { useChrome } from '@redhat-cloud-services/frontend-components/useChrome';
45
import NotificationsProvider from '@redhat-cloud-services/frontend-components-notifications/NotificationsProvider';
56
import { createStore } from '@redhat-cloud-services/frontend-components-notifications/state';
@@ -37,6 +38,7 @@ const App = () => {
3738
<NotificationsProvider store={store}>
3839
<Routes />
3940
</NotificationsProvider>
41+
<UiVersion />
4042
</div>
4143
);
4244
};

apps/koku-ui-hccm/src/routes.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { userAccess } from 'components/userAccess';
33
import React, { lazy, Suspense } from 'react';
44
import { Route, Routes as RouterRoutes } from 'react-router-dom';
55

6-
const NotFound = lazy(() => import(/* webpackChunkName: "NotFound" */ '@koku-ui/ui-lib/components/NotFound/NotFound'));
6+
const NotFound = lazy(() => import(/* webpackChunkName: "NotFound" */ '@koku-ui/ui-lib/components/page/notFound'));
77
const AwsBreakdown = lazy(() => import(/* webpackChunkName: "awsBreakdown" */ 'routes/details/awsBreakdown'));
88
const AwsDetails = lazy(() => import(/* webpackChunkName: "awsDetails" */ 'routes/details/awsDetails'));
99
const AzureBreakdown = lazy(() => import(/* webpackChunkName: "azureBreakdown" */ 'routes/details/azureBreakdown'));

apps/koku-ui-onprem/src/components/App/App.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import NotFound from '@koku-ui/ui-lib/components/NotFound/NotFound';
1+
import NotFound from '@koku-ui/ui-lib/components/page/notFound';
22
import React from 'react';
33
import { createBrowserRouter, RouterProvider } from 'react-router-dom';
44

apps/koku-ui-ros/build_deploy.sh

Lines changed: 0 additions & 29 deletions
This file was deleted.

apps/koku-ui-ros/fec.config.js

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
// Based on https://github.com/RedHatInsights/frontend-components/blob/master/packages/config/src/bin/dev.webpack.config.ts
22

33
const CopyWebpackPlugin = require('copy-webpack-plugin');
4+
const { GitRevisionPlugin } = require('git-revision-webpack-plugin');
45
const path = require('path');
56
const webpack = require('webpack');
6-
const { dependencies, insights } = require('./package.json');
7+
const { dependencies, insights, name } = require('./package.json');
78

89
const moduleName = insights.appname.replace(/-(\w)/g, (_, match) => match.toUpperCase());
910
const srcDir = path.resolve(__dirname, './src');
@@ -14,6 +15,7 @@ const stats = {
1415
colors: true,
1516
modules: false,
1617
};
18+
const gitRevisionPlugin = new GitRevisionPlugin();
1719

1820
// Show what files changed since last compilation
1921
class WatchRunPlugin {
@@ -89,6 +91,11 @@ module.exports = {
8991
},
9092
],
9193
}),
94+
gitRevisionPlugin,
95+
new webpack.DefinePlugin({
96+
'process.env.KOKU_UI_COMMITHASH': JSON.stringify(gitRevisionPlugin.commithash()),
97+
'process.env.KOKU_UI_PKGNAME': JSON.stringify(name),
98+
}),
9299
],
93100
resolve: {
94101
modules: [srcDir, path.resolve(__dirname, '../../node_modules')],

apps/koku-ui-ros/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@
110110
"@types/react-router-dom": "^5.3.3",
111111
"copy-webpack-plugin": "^13.0.1",
112112
"globals": "^16.5.0",
113+
"git-revision-webpack-plugin": "^5.0.0",
113114
"identity-obj-proxy": "^3.0.0",
114115
"jws": "^4.0.0",
115116
"ts-patch": "^3.3.0",

0 commit comments

Comments
 (0)