Skip to content

Commit

Permalink
feat: environment (#461)
Browse files Browse the repository at this point in the history
  • Loading branch information
CristhianF7 authored Feb 20, 2024
1 parent 8dd1db7 commit b07ce86
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion redux/thunks/applications.thunk.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export const installGitOpsApp = createAsyncThunk<
>('applications/installGitOpsApp', async ({ values, user }, { dispatch, getState }) => {
const {
applications: { selectedCatalogApp, filter },
api: { managementCluster },
api: { managementCluster, clusterMap },
} = getState();

if (!selectedCatalogApp) {
Expand All @@ -43,12 +43,15 @@ export const installGitOpsApp = createAsyncThunk<
const secret_keys = getMapValues(selectedCatalogApp.secret_keys);
const config_keys = getMapValues(selectedCatalogApp.config_keys);

const cluster = clusterMap[filter.cluster as string];

const params = {
config_keys,
secret_keys,
user,
is_template: filter.target === Target.TEMPLATE,
workload_cluster_name: filter.cluster,
environment: cluster?.environment?.name,
};

// Removing workload_cluster_name for management cluster installations
Expand Down

0 comments on commit b07ce86

Please sign in to comment.