Skip to content

Commit f023ad1

Browse files
authored
Change default config for non testing/localhost deployment (#178)
* Change default config for non testing/localhost deployment Disable most features (login, editing, etc.) and assume deployment in PlanQK mode by default when not running under localhost. * Remove debug output
1 parent 06216c7 commit f023ad1

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

src/app/core/directives/pattern-atlas-ui-repository-configuration.service.ts

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -44,16 +44,18 @@ interface EtcdNode {
4444
createdIndex: number;
4545
}
4646

47+
const IS_LOCALHOST = window.location?.hostname === 'localhost';
48+
4749
const initialValues: PatternAtlasUiConfiguration = {
4850
features: {
4951
designModel: false,
50-
patternCandidate: true,
52+
patternCandidate: IS_LOCALHOST ? true : false,
5153
patternViews: false,
52-
issue: true,
53-
showSettings: true,
54-
editing: true,
55-
authentication: true,
56-
planqkUi: false,
54+
issue: IS_LOCALHOST ? true : false,
55+
showSettings: IS_LOCALHOST ? true : false,
56+
editing: IS_LOCALHOST ? true : false,
57+
authentication: IS_LOCALHOST ? true : false,
58+
planqkUi: IS_LOCALHOST ? false : true,
5759
deploymentModelling: false,
5860
},
5961
};

0 commit comments

Comments
 (0)