Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app/assets/javascripts/clusters')
-rw-r--r--app/assets/javascripts/clusters/clusters_bundle.js40
-rw-r--r--app/assets/javascripts/clusters/components/applications.vue65
-rw-r--r--app/assets/javascripts/clusters/components/fluentd_output_settings.vue238
-rw-r--r--app/assets/javascripts/clusters/components/ingress_modsecurity_settings.vue266
-rw-r--r--app/assets/javascripts/clusters/components/remove_cluster_confirmation.vue14
-rw-r--r--app/assets/javascripts/clusters/constants.js2
-rw-r--r--app/assets/javascripts/clusters/forms/components/integration_form.vue17
-rw-r--r--app/assets/javascripts/clusters/forms/stores/state.js1
-rw-r--r--app/assets/javascripts/clusters/services/clusters_service.js1
-rw-r--r--app/assets/javascripts/clusters/stores/clusters_store.js29
10 files changed, 4 insertions, 669 deletions
diff --git a/app/assets/javascripts/clusters/clusters_bundle.js b/app/assets/javascripts/clusters/clusters_bundle.js
index 5cb3d913210..762b37a8216 100644
--- a/app/assets/javascripts/clusters/clusters_bundle.js
+++ b/app/assets/javascripts/clusters/clusters_bundle.js
@@ -11,7 +11,7 @@ import PersistentUserCallout from '../persistent_user_callout';
import initSettingsPanels from '../settings_panels';
import Applications from './components/applications.vue';
import RemoveClusterConfirmation from './components/remove_cluster_confirmation.vue';
-import { APPLICATION_STATUS, CROSSPLANE, KNATIVE, FLUENTD } from './constants';
+import { APPLICATION_STATUS, CROSSPLANE, KNATIVE } from './constants';
import eventHub from './event_hub';
import ClustersService from './services/clusters_service';
import ClustersStore from './stores/clusters_store';
@@ -42,7 +42,6 @@ export default class Clusters {
installElasticStackPath,
installCrossplanePath,
installPrometheusPath,
- installFluentdPath,
managePrometheusPath,
clusterEnvironmentsPath,
hasRbac,
@@ -55,7 +54,6 @@ export default class Clusters {
helmHelpPath,
ingressHelpPath,
ingressDnsHelpPath,
- ingressModSecurityHelpPath,
environmentsHelpPath,
clustersHelpPath,
deployBoardsHelpPath,
@@ -74,7 +72,6 @@ export default class Clusters {
helmHelpPath,
ingressHelpPath,
ingressDnsHelpPath,
- ingressModSecurityHelpPath,
environmentsHelpPath,
clustersHelpPath,
deployBoardsHelpPath,
@@ -100,7 +97,6 @@ export default class Clusters {
updateKnativeEndpoint: updateKnativePath,
installElasticStackEndpoint: installElasticStackPath,
clusterEnvironmentsEndpoint: clusterEnvironmentsPath,
- installFluentdEndpoint: installFluentdPath,
});
this.installApplication = this.installApplication.bind(this);
@@ -168,7 +164,6 @@ export default class Clusters {
ingressHelpPath: this.state.ingressHelpPath,
managePrometheusPath: this.state.managePrometheusPath,
ingressDnsHelpPath: this.state.ingressDnsHelpPath,
- ingressModSecurityHelpPath: this.state.ingressModSecurityHelpPath,
cloudRunHelpPath: this.state.cloudRunHelpPath,
providerType: this.state.providerType,
preInstalledKnative: this.state.preInstalledKnative,
@@ -253,10 +248,6 @@ export default class Clusters {
eventHub.$on('setKnativeDomain', (data) => this.setKnativeDomain(data));
eventHub.$on('uninstallApplication', (data) => this.uninstallApplication(data));
eventHub.$on('setCrossplaneProviderStack', (data) => this.setCrossplaneProviderStack(data));
- eventHub.$on('setIngressModSecurityEnabled', (data) => this.setIngressModSecurityEnabled(data));
- eventHub.$on('setIngressModSecurityMode', (data) => this.setIngressModSecurityMode(data));
- eventHub.$on('resetIngressModSecurityChanges', (id) => this.resetIngressModSecurityChanges(id));
- eventHub.$on('setFluentdSettings', (data) => this.setFluentdSettings(data));
// Add event listener to all the banner close buttons
this.addBannerCloseHandler(this.unreachableContainer, 'unreachable');
this.addBannerCloseHandler(this.authenticationFailureContainer, 'authentication_failure');
@@ -273,14 +264,6 @@ export default class Clusters {
eventHub.$off('setCrossplaneProviderStack');
// eslint-disable-next-line @gitlab/no-global-event-off
eventHub.$off('uninstallApplication');
- // eslint-disable-next-line @gitlab/no-global-event-off
- eventHub.$off('setIngressModSecurityEnabled');
- // eslint-disable-next-line @gitlab/no-global-event-off
- eventHub.$off('setIngressModSecurityMode');
- // eslint-disable-next-line @gitlab/no-global-event-off
- eventHub.$off('resetIngressModSecurityChanges');
- // eslint-disable-next-line @gitlab/no-global-event-off
- eventHub.$off('setFluentdSettings');
}
initPolling(method, successCallback, errorCallback) {
@@ -492,12 +475,6 @@ export default class Clusters {
});
}
- setFluentdSettings(settings = {}) {
- Object.entries(settings).forEach(([key, value]) => {
- this.store.updateAppProperty(FLUENTD, key, value);
- });
- }
-
saveKnativeDomain(data) {
const appId = data.id;
this.store.updateApplication(appId);
@@ -519,21 +496,6 @@ export default class Clusters {
this.store.updateAppProperty(appId, 'validationError', null);
}
- setIngressModSecurityEnabled({ id, modSecurityEnabled }) {
- this.store.updateAppProperty(id, 'isEditingModSecurityEnabled', true);
- this.store.updateAppProperty(id, 'modsecurity_enabled', modSecurityEnabled);
- }
-
- setIngressModSecurityMode({ id, modSecurityMode }) {
- this.store.updateAppProperty(id, 'isEditingModSecurityMode', true);
- this.store.updateAppProperty(id, 'modsecurity_mode', modSecurityMode);
- }
-
- resetIngressModSecurityChanges(id) {
- this.store.updateAppProperty(id, 'isEditingModSecurityEnabled', false);
- this.store.updateAppProperty(id, 'isEditingModSecurityMode', false);
- }
-
destroy() {
this.destroyed = true;
diff --git a/app/assets/javascripts/clusters/components/applications.vue b/app/assets/javascripts/clusters/components/applications.vue
index 8ef3169dc65..ddee1711975 100644
--- a/app/assets/javascripts/clusters/components/applications.vue
+++ b/app/assets/javascripts/clusters/components/applications.vue
@@ -3,7 +3,6 @@ import { GlLoadingIcon, GlSprintf, GlLink, GlAlert } from '@gitlab/ui';
import certManagerLogo from 'images/cluster_app_logos/cert_manager.png';
import crossplaneLogo from 'images/cluster_app_logos/crossplane.png';
import elasticStackLogo from 'images/cluster_app_logos/elastic_stack.png';
-import fluentdLogo from 'images/cluster_app_logos/fluentd.png';
import gitlabLogo from 'images/cluster_app_logos/gitlab.png';
import helmLogo from 'images/cluster_app_logos/helm.png';
import jupyterhubLogo from 'images/cluster_app_logos/jupyterhub.png';
@@ -15,8 +14,6 @@ import clipboardButton from '../../vue_shared/components/clipboard_button.vue';
import { CLUSTER_TYPE, PROVIDER_TYPE, APPLICATION_STATUS, INGRESS } from '../constants';
import applicationRow from './application_row.vue';
import CrossplaneProviderStack from './crossplane_provider_stack.vue';
-import FluentdOutputSettings from './fluentd_output_settings.vue';
-import IngressModsecuritySettings from './ingress_modsecurity_settings.vue';
import KnativeDomainEditor from './knative_domain_editor.vue';
export default {
@@ -28,8 +25,6 @@ export default {
GlLink,
KnativeDomainEditor,
CrossplaneProviderStack,
- IngressModsecuritySettings,
- FluentdOutputSettings,
GlAlert,
},
props: {
@@ -63,11 +58,7 @@ export default {
required: false,
default: '',
},
- ingressModSecurityHelpPath: {
- type: String,
- required: false,
- default: '',
- },
+
cloudRunHelpPath: {
type: String,
required: false,
@@ -165,7 +156,6 @@ export default {
knativeLogo,
prometheusLogo,
elasticStackLogo,
- fluentdLogo,
},
};
</script>
@@ -219,10 +209,6 @@ export default {
:request-reason="applications.ingress.requestReason"
:installed="applications.ingress.installed"
:install-failed="applications.ingress.installFailed"
- :install-application-request-params="{
- modsecurity_enabled: applications.ingress.modsecurity_enabled,
- modsecurity_mode: applications.ingress.modsecurity_mode,
- }"
:uninstallable="applications.ingress.uninstallable"
:uninstall-successful="applications.ingress.uninstallSuccessful"
:uninstall-failed="applications.ingress.uninstallFailed"
@@ -238,11 +224,6 @@ export default {
}}
</p>
- <ingress-modsecurity-settings
- :ingress="ingress"
- :ingress-mod-security-help-path="ingressModSecurityHelpPath"
- />
-
<template v-if="ingressInstalled">
<div class="form-group">
<label for="ingress-endpoint">{{ s__('ClusterIntegration|Ingress Endpoint') }}</label>
@@ -644,50 +625,6 @@ export default {
</template>
</application-row>
- <application-row
- id="fluentd"
- :logo-url="$options.logos.fluentdLogo"
- :title="applications.fluentd.title"
- :status="applications.fluentd.status"
- :status-reason="applications.fluentd.statusReason"
- :request-status="applications.fluentd.requestStatus"
- :request-reason="applications.fluentd.requestReason"
- :installed="applications.fluentd.installed"
- :install-failed="applications.fluentd.installFailed"
- :install-application-request-params="{
- host: applications.fluentd.host,
- port: applications.fluentd.port,
- protocol: applications.fluentd.protocol,
- waf_log_enabled: applications.fluentd.wafLogEnabled,
- cilium_log_enabled: applications.fluentd.ciliumLogEnabled,
- }"
- :uninstallable="applications.fluentd.uninstallable"
- :uninstall-successful="applications.fluentd.uninstallSuccessful"
- :uninstall-failed="applications.fluentd.uninstallFailed"
- :updateable="false"
- title-link="https://github.com/helm/charts/tree/master/stable/fluentd"
- >
- <template #description>
- <p>
- {{
- s__(
- `ClusterIntegration|Fluentd is an open source data collector, which lets you unify the data collection and consumption for a better use and understanding of data. It requires at least one of the following logs to be successfully installed.`,
- )
- }}
- </p>
-
- <fluentd-output-settings
- :port="applications.fluentd.port"
- :protocol="applications.fluentd.protocol"
- :host="applications.fluentd.host"
- :waf-log-enabled="applications.fluentd.wafLogEnabled"
- :cilium-log-enabled="applications.fluentd.ciliumLogEnabled"
- :status="applications.fluentd.status"
- :update-failed="applications.fluentd.updateFailed"
- />
- </template>
- </application-row>
-
<div class="gl-mt-7 gl-border-1 gl-border-t-solid gl-border-gray-100">
<!-- This empty div serves as a separator. The applications below can be externally installed using a cluster-management project. -->
</div>
diff --git a/app/assets/javascripts/clusters/components/fluentd_output_settings.vue b/app/assets/javascripts/clusters/components/fluentd_output_settings.vue
deleted file mode 100644
index aaad0009ef3..00000000000
--- a/app/assets/javascripts/clusters/components/fluentd_output_settings.vue
+++ /dev/null
@@ -1,238 +0,0 @@
-<script>
-import { GlAlert, GlButton, GlDropdown, GlDropdownItem, GlFormCheckbox } from '@gitlab/ui';
-import { mapValues } from 'lodash';
-import { APPLICATION_STATUS, FLUENTD } from '~/clusters/constants';
-import eventHub from '~/clusters/event_hub';
-import { __ } from '~/locale';
-
-const { UPDATING, UNINSTALLING, INSTALLING, INSTALLED, UPDATED } = APPLICATION_STATUS;
-
-export default {
- components: {
- GlAlert,
- GlButton,
- GlDropdown,
- GlDropdownItem,
- GlFormCheckbox,
- },
- props: {
- protocols: {
- type: Array,
- required: false,
- default: () => ['TCP', 'UDP'],
- },
- status: {
- type: String,
- required: false,
- default: '',
- },
- updateFailed: {
- type: Boolean,
- required: false,
- },
- protocol: {
- type: String,
- required: false,
- default: () => __('Protocol'),
- },
- port: {
- type: Number,
- required: false,
- default: 514,
- },
- host: {
- type: String,
- required: false,
- default: '',
- },
- wafLogEnabled: {
- type: Boolean,
- required: false,
- },
- ciliumLogEnabled: {
- type: Boolean,
- required: false,
- },
- },
- data() {
- return {
- currentServerSideSettings: {
- host: null,
- port: null,
- protocol: null,
- wafLogEnabled: null,
- ciliumLogEnabled: null,
- },
- };
- },
- computed: {
- isSaving() {
- return [UPDATING].includes(this.status);
- },
- saveButtonDisabled() {
- return [UNINSTALLING, UPDATING, INSTALLING].includes(this.status);
- },
- saveButtonLabel() {
- return this.isSaving ? __('Saving') : __('Save changes');
- },
- /**
- * Returns true either when:
- * - The application is getting updated.
- * - The user has changed some of the settings for an application which is
- * neither getting installed nor updated.
- */
- showButtons() {
- return this.isSaving || (this.changedByUser && [INSTALLED, UPDATED].includes(this.status));
- },
- protocolName() {
- if (this.protocol) {
- return this.protocol.toUpperCase();
- }
- return __('Protocol');
- },
- changedByUser() {
- return Object.entries(this.currentServerSideSettings).some(([key, value]) => {
- return value !== null && value !== this[key];
- });
- },
- },
- watch: {
- status() {
- this.resetCurrentServerSideSettings();
- },
- },
- methods: {
- updateApplication() {
- eventHub.$emit('updateApplication', {
- id: FLUENTD,
- params: {
- port: this.port,
- protocol: this.protocol,
- host: this.host,
- waf_log_enabled: this.wafLogEnabled,
- cilium_log_enabled: this.ciliumLogEnabled,
- },
- });
- },
- resetCurrentServerSideSettings() {
- this.currentServerSideSettings = mapValues(this.currentServerSideSettings, () => {
- return null;
- });
- },
- resetStatus() {
- const newSettings = mapValues(this.currentServerSideSettings, (value, key) => {
- return value === null ? this[key] : value;
- });
- eventHub.$emit('setFluentdSettings', {
- ...newSettings,
- isEditingSettings: false,
- });
- },
- updateCurrentServerSideSettings(settings) {
- Object.keys(settings).forEach((key) => {
- if (this.currentServerSideSettings[key] === null) {
- this.currentServerSideSettings[key] = this[key];
- }
- });
- },
- setFluentdSettings(settings) {
- this.updateCurrentServerSideSettings(settings);
- eventHub.$emit('setFluentdSettings', {
- ...settings,
- isEditingSettings: true,
- });
- },
- selectProtocol(protocol) {
- this.setFluentdSettings({ protocol });
- },
- hostChanged(host) {
- this.setFluentdSettings({ host });
- },
- portChanged(port) {
- this.setFluentdSettings({ port: Number(port) });
- },
- wafLogChanged(wafLogEnabled) {
- this.setFluentdSettings({ wafLogEnabled });
- },
- ciliumLogChanged(ciliumLogEnabled) {
- this.setFluentdSettings({ ciliumLogEnabled });
- },
- },
-};
-</script>
-
-<template>
- <div>
- <gl-alert v-if="updateFailed" class="mb-3" variant="danger" :dismissible="false">
- {{
- s__(
- 'ClusterIntegration|Something went wrong while trying to save your settings. Please try again.',
- )
- }}
- </gl-alert>
- <div class="form-horizontal">
- <div class="form-group">
- <label for="fluentd-host">
- <strong>{{ s__('ClusterIntegration|SIEM Hostname') }}</strong>
- </label>
- <input
- id="fluentd-host"
- :value="host"
- type="text"
- class="form-control"
- @input="hostChanged($event.target.value)"
- />
- </div>
- <div class="form-group">
- <label for="fluentd-port">
- <strong>{{ s__('ClusterIntegration|SIEM Port') }}</strong>
- </label>
- <input
- id="fluentd-port"
- :value="port"
- type="number"
- class="form-control"
- @input="portChanged($event.target.value)"
- />
- </div>
- <div class="form-group">
- <label for="fluentd-protocol">
- <strong>{{ s__('ClusterIntegration|SIEM Protocol') }}</strong>
- </label>
- <gl-dropdown :text="protocolName" class="w-100">
- <gl-dropdown-item
- v-for="(value, index) in protocols"
- :key="index"
- @click="selectProtocol(value.toLowerCase())"
- >
- {{ value }}
- </gl-dropdown-item>
- </gl-dropdown>
- </div>
- <div class="form-group flex flex-wrap">
- <gl-form-checkbox :checked="wafLogEnabled" @input="wafLogChanged">
- <strong>{{ s__('ClusterIntegration|Send Web Application Firewall Logs') }}</strong>
- </gl-form-checkbox>
- <gl-form-checkbox :checked="ciliumLogEnabled" @input="ciliumLogChanged">
- <strong>{{ s__('ClusterIntegration|Send Container Network Policies Logs') }}</strong>
- </gl-form-checkbox>
- </div>
- <div v-if="showButtons" class="gl-mt-5 gl-display-flex">
- <gl-button
- ref="saveBtn"
- class="gl-mr-3"
- variant="success"
- category="primary"
- :loading="isSaving"
- :disabled="saveButtonDisabled"
- @click="updateApplication"
- >
- {{ saveButtonLabel }}
- </gl-button>
- <gl-button ref="cancelBtn" :disabled="saveButtonDisabled" @click="resetStatus">
- {{ __('Cancel') }}
- </gl-button>
- </div>
- </div>
- </div>
-</template>
diff --git a/app/assets/javascripts/clusters/components/ingress_modsecurity_settings.vue b/app/assets/javascripts/clusters/components/ingress_modsecurity_settings.vue
deleted file mode 100644
index 1ba28660e5c..00000000000
--- a/app/assets/javascripts/clusters/components/ingress_modsecurity_settings.vue
+++ /dev/null
@@ -1,266 +0,0 @@
-<script>
-import {
- GlAlert,
- GlSprintf,
- GlLink,
- GlToggle,
- GlButton,
- GlDropdown,
- GlDropdownItem,
- GlIcon,
-} from '@gitlab/ui';
-import { escape } from 'lodash';
-import modSecurityLogo from 'images/cluster_app_logos/gitlab.png';
-import { APPLICATION_STATUS, INGRESS, LOGGING_MODE, BLOCKING_MODE } from '~/clusters/constants';
-import eventHub from '~/clusters/event_hub';
-import { s__, __ } from '../../locale';
-
-const { UPDATING, UNINSTALLING, INSTALLING, INSTALLED, UPDATED } = APPLICATION_STATUS;
-
-export default {
- i18n: {
- modSecurityEnabled: s__('ClusterIntegration|ModSecurity enabled'),
- },
- title: __('Web Application Firewall'),
- modsecurityUrl: 'https://modsecurity.org/about.html',
- components: {
- GlAlert,
- GlSprintf,
- GlLink,
- GlToggle,
- GlButton,
- GlDropdown,
- GlDropdownItem,
- GlIcon,
- },
- props: {
- ingress: {
- type: Object,
- required: true,
- },
- ingressModSecurityHelpPath: {
- type: String,
- required: false,
- default: '',
- },
- modes: {
- type: Object,
- required: false,
- default: () => ({
- [LOGGING_MODE]: {
- name: s__('ClusterIntegration|Logging mode'),
- },
- [BLOCKING_MODE]: {
- name: s__('ClusterIntegration|Blocking mode'),
- },
- }),
- },
- },
- data() {
- return {
- modSecurityLogo,
- initialValue: null,
- initialMode: null,
- };
- },
- computed: {
- modSecurityEnabled: {
- get() {
- return this.ingress.modsecurity_enabled;
- },
- set(isEnabled) {
- if (this.initialValue === null) {
- this.initialValue = this.ingress.modsecurity_enabled;
- }
- eventHub.$emit('setIngressModSecurityEnabled', {
- id: INGRESS,
- modSecurityEnabled: isEnabled,
- });
- },
- },
- hasValueChanged() {
- return this.modSecurityEnabledChanged || this.modSecurityModeChanged;
- },
- modSecurityEnabledChanged() {
- return this.initialValue !== null && this.initialValue !== this.ingress.modsecurity_enabled;
- },
- modSecurityModeChanged() {
- return (
- this.ingress.modsecurity_enabled &&
- this.initialMode !== null &&
- this.initialMode !== this.ingress.modsecurity_mode
- );
- },
- ingressModSecurityDescription() {
- return escape(this.ingressModSecurityHelpPath);
- },
- saving() {
- return [UPDATING].includes(this.ingress.status);
- },
- saveButtonDisabled() {
- return (
- [UNINSTALLING, UPDATING, INSTALLING].includes(this.ingress.status) ||
- this.ingress.updateAvailable
- );
- },
- saveButtonLabel() {
- return this.saving ? __('Saving') : __('Save changes');
- },
- /**
- * Returns true either when:
- * - The application is getting updated.
- * - The user has changed some of the settings for an application which is
- * neither getting installed nor updated.
- */
- showButtons() {
- return this.saving || this.valuesChangedByUser;
- },
- modSecurityModeName() {
- return this.modes[this.ingress.modsecurity_mode].name;
- },
- valuesChangedByUser() {
- return this.hasValueChanged && [INSTALLED, UPDATED].includes(this.ingress.status);
- },
- },
- methods: {
- updateApplication() {
- eventHub.$emit('updateApplication', {
- id: INGRESS,
- params: {
- modsecurity_enabled: this.ingress.modsecurity_enabled,
- modsecurity_mode: this.ingress.modsecurity_mode,
- },
- });
- this.resetStatus();
- },
- resetStatus() {
- if (this.initialMode !== null) {
- // eslint-disable-next-line vue/no-mutating-props
- this.ingress.modsecurity_mode = this.initialMode;
- }
- if (this.initialValue !== null) {
- // eslint-disable-next-line vue/no-mutating-props
- this.ingress.modsecurity_enabled = this.initialValue;
- }
- this.initialValue = null;
- this.initialMode = null;
- eventHub.$emit('resetIngressModSecurityChanges', INGRESS);
- },
- selectMode(modeKey) {
- if (this.initialMode === null) {
- this.initialMode = this.ingress.modsecurity_mode;
- }
- eventHub.$emit('setIngressModSecurityMode', {
- id: INGRESS,
- modSecurityMode: modeKey,
- });
- },
- },
-};
-</script>
-
-<template>
- <div>
- <gl-alert
- v-if="ingress.updateFailed"
- class="mb-3"
- variant="danger"
- :dismissible="false"
- @dismiss="alert = null"
- >
- {{
- s__(
- 'ClusterIntegration|Something went wrong while trying to save your settings. Please try again.',
- )
- }}
- </gl-alert>
- <div class="gl-responsive-table-row-layout" role="row">
- <div class="table-section gl-mr-3 section-align-top" role="gridcell">
- <img
- :src="modSecurityLogo"
- :alt="`${$options.title} logo`"
- class="cluster-application-logo avatar s40"
- />
- </div>
- <div class="table-section section-wrap" role="gridcell">
- <strong>
- <gl-link :href="$options.modsecurityUrl" target="_blank">{{ $options.title }} </gl-link>
- </strong>
- <div class="form-group">
- <p class="form-text text-muted">
- <strong>
- <gl-sprintf
- :message="
- s__(
- 'ClusterIntegration|Real-time web application monitoring, logging and access control. %{linkStart}More information%{linkEnd}',
- )
- "
- >
- <template #link="{ content }">
- <gl-link :href="ingressModSecurityDescription" target="_blank"
- >{{ content }}
- </gl-link>
- </template>
- </gl-sprintf>
- </strong>
- </p>
- <div class="form-check form-check-inline mt-3">
- <gl-toggle
- v-model="modSecurityEnabled"
- :disabled="saveButtonDisabled"
- :label="$options.i18n.modSecurityEnabled"
- label-position="hidden"
- />
- </div>
- <div
- v-if="ingress.modsecurity_enabled"
- class="gl-responsive-table-row-layout mt-3"
- role="row"
- >
- <div class="table-section section-wrap" role="gridcell">
- <strong>
- {{ s__('ClusterIntegration|Global default') }}
- <gl-icon name="earth" class="align-text-bottom" />
- </strong>
- <div class="form-group">
- <p class="form-text text-muted">
- <strong>
- {{
- s__(
- 'ClusterIntegration|Set the global mode for the WAF in this cluster. This can be overridden at the environmental level.',
- )
- }}
- </strong>
- </p>
- </div>
- <gl-dropdown :text="modSecurityModeName" :disabled="saveButtonDisabled">
- <gl-dropdown-item v-for="(mode, key) in modes" :key="key" @click="selectMode(key)">
- {{ mode.name }}
- </gl-dropdown-item>
- </gl-dropdown>
- </div>
- </div>
- <div v-if="showButtons" class="gl-mt-5 gl-display-flex">
- <gl-button
- variant="success"
- category="primary"
- data-qa-selector="save_ingress_modsecurity_settings"
- :loading="saving"
- :disabled="saveButtonDisabled"
- @click="updateApplication"
- >
- {{ saveButtonLabel }}
- </gl-button>
- <gl-button
- data-qa-selector="cancel_ingress_modsecurity_settings"
- :disabled="saveButtonDisabled"
- @click="resetStatus"
- >
- {{ __('Cancel') }}
- </gl-button>
- </div>
- </div>
- </div>
- </div>
- </div>
-</template>
diff --git a/app/assets/javascripts/clusters/components/remove_cluster_confirmation.vue b/app/assets/javascripts/clusters/components/remove_cluster_confirmation.vue
index 5cd9baf2c2b..b9c55409330 100644
--- a/app/assets/javascripts/clusters/components/remove_cluster_confirmation.vue
+++ b/app/assets/javascripts/clusters/components/remove_cluster_confirmation.vue
@@ -1,6 +1,6 @@
<script>
/* eslint-disable vue/no-v-html */
-import { GlModal, GlButton, GlFormInput, GlSprintf } from '@gitlab/ui';
+import { GlModal, GlButton, GlFormInput } from '@gitlab/ui';
import { escape } from 'lodash';
import csrf from '~/lib/utils/csrf';
import { s__, sprintf } from '~/locale';
@@ -30,7 +30,6 @@ export default {
GlModal,
GlButton,
GlFormInput,
- GlSprintf,
},
props: {
clusterPath: {
@@ -135,17 +134,6 @@ export default {
<div v-if="confirmCleanup">
{{ s__('ClusterIntegration|This will permanently delete the following resources:') }}
<ul>
- <li>
- {{ s__('ClusterIntegration|All installed applications and related resources') }}
- </li>
- <li>
- <gl-sprintf :message="s__('ClusterIntegration|The %{gitlabNamespace} namespace')">
- <template #gitlabNamespace>
- <!-- eslint-disable-next-line @gitlab/vue-require-i18n-strings -->
- <code>{{ 'gitlab-managed-apps' }}</code>
- </template>
- </gl-sprintf>
- </li>
<li>{{ s__('ClusterIntegration|Any project namespaces') }}</li>
<!-- eslint-disable @gitlab/vue-require-i18n-strings -->
<li><code>clusterroles</code></li>
diff --git a/app/assets/javascripts/clusters/constants.js b/app/assets/javascripts/clusters/constants.js
index 90ec3f2377c..846e5950b8b 100644
--- a/app/assets/javascripts/clusters/constants.js
+++ b/app/assets/javascripts/clusters/constants.js
@@ -55,7 +55,6 @@ export const CERT_MANAGER = 'cert_manager';
export const CROSSPLANE = 'crossplane';
export const PROMETHEUS = 'prometheus';
export const ELASTIC_STACK = 'elastic_stack';
-export const FLUENTD = 'fluentd';
export const APPLICATIONS = [
HELM,
@@ -66,7 +65,6 @@ export const APPLICATIONS = [
CERT_MANAGER,
PROMETHEUS,
ELASTIC_STACK,
- FLUENTD,
];
export const INGRESS_DOMAIN_SUFFIX = '.nip.io';
diff --git a/app/assets/javascripts/clusters/forms/components/integration_form.vue b/app/assets/javascripts/clusters/forms/components/integration_form.vue
index a344f9578fd..3f61a1b18a7 100644
--- a/app/assets/javascripts/clusters/forms/components/integration_form.vue
+++ b/app/assets/javascripts/clusters/forms/components/integration_form.vue
@@ -41,17 +41,10 @@ export default {
toggleEnabled: true,
envScope: '*',
baseDomainField: '',
- externalIp: '',
};
},
computed: {
- ...mapState([
- 'enabled',
- 'editable',
- 'environmentScope',
- 'baseDomain',
- 'applicationIngressExternalIp',
- ]),
+ ...mapState(['enabled', 'editable', 'environmentScope', 'baseDomain']),
canSubmit() {
return (
this.enabled !== this.toggleEnabled ||
@@ -64,7 +57,6 @@ export default {
this.toggleEnabled = this.enabled;
this.envScope = this.environmentScope;
this.baseDomainField = this.baseDomain;
- this.externalIp = this.applicationIngressExternalIp;
},
};
</script>
@@ -135,13 +127,6 @@ export default {
<gl-link :href="autoDevopsHelpPath" target="_blank">{{ content }}</gl-link>
</template>
</gl-sprintf>
- <div v-if="applicationIngressExternalIp" class="js-ingress-domain-help-text inline">
- {{ s__('ClusterIntegration|Alternatively, ') }}
- <gl-sprintf :message="s__('ClusterIntegration|%{externalIp}.nip.io')">
- <template #externalIp>{{ externalIp }}</template>
- </gl-sprintf>
- {{ s__('ClusterIntegration|can be used instead of a custom domain. ') }}
- </div>
<gl-sprintf
class="inline"
:message="s__('ClusterIntegration|%{linkStart}More information%{linkEnd}')"
diff --git a/app/assets/javascripts/clusters/forms/stores/state.js b/app/assets/javascripts/clusters/forms/stores/state.js
index 2a96590b5e7..74a00b97603 100644
--- a/app/assets/javascripts/clusters/forms/stores/state.js
+++ b/app/assets/javascripts/clusters/forms/stores/state.js
@@ -6,7 +6,6 @@ export default (initialState = {}) => {
editable: parseBoolean(initialState.editable),
environmentScope: initialState.environmentScope,
baseDomain: initialState.baseDomain,
- applicationIngressExternalIp: initialState.applicationIngressExternalIp,
autoDevopsHelpPath: initialState.autoDevopsHelpPath,
externalEndpointHelpPath: initialState.externalEndpointHelpPath,
};
diff --git a/app/assets/javascripts/clusters/services/clusters_service.js b/app/assets/javascripts/clusters/services/clusters_service.js
index 2a6c6965dab..333fb293a15 100644
--- a/app/assets/javascripts/clusters/services/clusters_service.js
+++ b/app/assets/javascripts/clusters/services/clusters_service.js
@@ -13,7 +13,6 @@ export default class ClusterService {
jupyter: this.options.installJupyterEndpoint,
knative: this.options.installKnativeEndpoint,
elastic_stack: this.options.installElasticStackEndpoint,
- fluentd: this.options.installFluentdEndpoint,
};
this.appUpdateEndpointMap = {
knative: this.options.updateKnativeEndpoint,
diff --git a/app/assets/javascripts/clusters/stores/clusters_store.js b/app/assets/javascripts/clusters/stores/clusters_store.js
index d45696c98c2..50689a6142f 100644
--- a/app/assets/javascripts/clusters/stores/clusters_store.js
+++ b/app/assets/javascripts/clusters/stores/clusters_store.js
@@ -13,7 +13,6 @@ import {
UPDATE_EVENT,
UNINSTALL_EVENT,
ELASTIC_STACK,
- FLUENTD,
} from '../constants';
import transitionApplicationState from '../services/application_state_machine';
@@ -55,12 +54,8 @@ export default class ClusterStore {
ingress: {
...applicationInitialState,
title: s__('ClusterIntegration|Ingress'),
- modsecurity_enabled: false,
- modsecurity_mode: null,
externalIp: null,
externalHostname: null,
- isEditingModSecurityEnabled: false,
- isEditingModSecurityMode: false,
updateFailed: false,
updateAvailable: false,
},
@@ -106,16 +101,6 @@ export default class ClusterStore {
...applicationInitialState,
title: s__('ClusterIntegration|Elastic Stack'),
},
- fluentd: {
- ...applicationInitialState,
- title: s__('ClusterIntegration|Fluentd'),
- host: null,
- port: null,
- protocol: null,
- wafLogEnabled: null,
- ciliumLogEnabled: null,
- isEditingSettings: false,
- },
cilium: {
...applicationInitialState,
title: s__('ClusterIntegration|GitLab Container Network Policies'),
@@ -219,12 +204,6 @@ export default class ClusterStore {
this.state.applications.ingress.externalIp = serverAppEntry.external_ip;
this.state.applications.ingress.externalHostname = serverAppEntry.external_hostname;
this.state.applications.ingress.updateAvailable = updateAvailable;
- if (!this.state.applications.ingress.isEditingModSecurityEnabled) {
- this.state.applications.ingress.modsecurity_enabled = serverAppEntry.modsecurity_enabled;
- }
- if (!this.state.applications.ingress.isEditingModSecurityMode) {
- this.state.applications.ingress.modsecurity_mode = serverAppEntry.modsecurity_mode;
- }
} else if (appId === CERT_MANAGER) {
this.state.applications.cert_manager.email =
this.state.applications.cert_manager.email || serverAppEntry.email;
@@ -257,14 +236,6 @@ export default class ClusterStore {
} else if (appId === ELASTIC_STACK) {
this.state.applications.elastic_stack.version = version;
this.state.applications.elastic_stack.updateAvailable = updateAvailable;
- } else if (appId === FLUENTD) {
- if (!this.state.applications.fluentd.isEditingSettings) {
- this.state.applications.fluentd.port = serverAppEntry.port;
- this.state.applications.fluentd.host = serverAppEntry.host;
- this.state.applications.fluentd.protocol = serverAppEntry.protocol;
- this.state.applications.fluentd.wafLogEnabled = serverAppEntry.waf_log_enabled;
- this.state.applications.fluentd.ciliumLogEnabled = serverAppEntry.cilium_log_enabled;
- }
}
});
}