Compare commits

...

6 Commits

Author SHA1 Message Date
argo-bot
b65c1699fa Bump version to 2.3.1 2022-03-10 22:43:44 +00:00
argo-bot
4c1428a6be Bump version to 2.3.1 2022-03-10 22:43:24 +00:00
Keith Chong
bca190bd0c fix: Retry checkbox unchecked unexpectedly; Sync up with YAML (#8682) (#8720)
Signed-off-by: Keith Chong <kykchong@redhat.com>
2022-03-10 14:23:30 -08:00
Alexander Matyushentsev
88ca5aabf2 chore: Bump stable version of application set addon (#8744)
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
2022-03-10 13:19:44 -08:00
Alexander Matyushentsev
8297f827a8 fix: correct jsonnet paths resolution (#8721)
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
2022-03-08 15:59:03 -08:00
Yuan Tang
b85ef39e0d fix(ui): Applications page incorrectly resets to tiles view. Fixes #8702 (#8718)
Signed-off-by: Yuan Tang <terrytangyuan@gmail.com>
2022-03-08 11:24:02 -08:00
15 changed files with 70 additions and 49 deletions

View File

@@ -1 +1 @@
2.3.0
2.3.1

View File

@@ -1,4 +1,4 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- https://raw.githubusercontent.com/argoproj/applicationset/v0.4.0/manifests/install.yaml
- https://raw.githubusercontent.com/argoproj/applicationset/v0.4.1/manifests/install.yaml

View File

@@ -5,7 +5,7 @@ kind: Kustomization
images:
- name: quay.io/argoproj/argocd
newName: quay.io/argoproj/argocd
newTag: v2.3.0
newTag: v2.3.1
resources:
- ./application-controller
- ./dex

View File

@@ -9497,7 +9497,7 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.namespace
image: quay.io/argoproj/argocd-applicationset:v0.4.0
image: quay.io/argoproj/argocd-applicationset:v0.4.1
imagePullPolicy: Always
name: argocd-applicationset-controller
ports:
@@ -9692,7 +9692,7 @@ spec:
value: /helm-working-dir
- name: HELM_DATA_HOME
value: /helm-working-dir
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
failureThreshold: 3
@@ -9741,7 +9741,7 @@ spec:
- -n
- /usr/local/bin/argocd
- /var/run/argocd/argocd-cmp-server
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
name: copyutil
volumeMounts:
- mountPath: /var/run/argocd
@@ -9906,7 +9906,7 @@ spec:
key: controller.default.cache.expiration
name: argocd-cmd-params-cm
optional: true
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
httpGet:

View File

@@ -11,4 +11,4 @@ resources:
images:
- name: quay.io/argoproj/argocd
newName: quay.io/argoproj/argocd
newTag: v2.3.0
newTag: v2.3.1

View File

@@ -11,7 +11,7 @@ patchesStrategicMerge:
images:
- name: quay.io/argoproj/argocd
newName: quay.io/argoproj/argocd
newTag: v2.3.0
newTag: v2.3.1
resources:
- ../../base/application-controller
- ../../base/dex

View File

@@ -10435,7 +10435,7 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.namespace
image: quay.io/argoproj/argocd-applicationset:v0.4.0
image: quay.io/argoproj/argocd-applicationset:v0.4.1
imagePullPolicy: Always
name: argocd-applicationset-controller
ports:
@@ -10516,7 +10516,7 @@ spec:
- -n
- /usr/local/bin/argocd
- /shared/argocd-dex
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
name: copyutil
volumeMounts:
@@ -10549,7 +10549,7 @@ spec:
containers:
- command:
- argocd-notifications
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
tcpSocket:
@@ -10782,7 +10782,7 @@ spec:
value: /helm-working-dir
- name: HELM_DATA_HOME
value: /helm-working-dir
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
failureThreshold: 3
@@ -10831,7 +10831,7 @@ spec:
- -n
- /usr/local/bin/argocd
- /var/run/argocd/argocd-cmp-server
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
name: copyutil
volumeMounts:
- mountPath: /var/run/argocd
@@ -11058,7 +11058,7 @@ spec:
key: server.http.cookie.maxnumber
name: argocd-cmd-params-cm
optional: true
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
httpGet:
@@ -11254,7 +11254,7 @@ spec:
key: controller.default.cache.expiration
name: argocd-cmd-params-cm
optional: true
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
httpGet:

View File

@@ -7731,7 +7731,7 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.namespace
image: quay.io/argoproj/argocd-applicationset:v0.4.0
image: quay.io/argoproj/argocd-applicationset:v0.4.1
imagePullPolicy: Always
name: argocd-applicationset-controller
ports:
@@ -7812,7 +7812,7 @@ spec:
- -n
- /usr/local/bin/argocd
- /shared/argocd-dex
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
name: copyutil
volumeMounts:
@@ -7845,7 +7845,7 @@ spec:
containers:
- command:
- argocd-notifications
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
tcpSocket:
@@ -8078,7 +8078,7 @@ spec:
value: /helm-working-dir
- name: HELM_DATA_HOME
value: /helm-working-dir
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
failureThreshold: 3
@@ -8127,7 +8127,7 @@ spec:
- -n
- /usr/local/bin/argocd
- /var/run/argocd/argocd-cmp-server
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
name: copyutil
volumeMounts:
- mountPath: /var/run/argocd
@@ -8354,7 +8354,7 @@ spec:
key: server.http.cookie.maxnumber
name: argocd-cmd-params-cm
optional: true
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
httpGet:
@@ -8550,7 +8550,7 @@ spec:
key: controller.default.cache.expiration
name: argocd-cmd-params-cm
optional: true
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
httpGet:

View File

@@ -9805,7 +9805,7 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.namespace
image: quay.io/argoproj/argocd-applicationset:v0.4.0
image: quay.io/argoproj/argocd-applicationset:v0.4.1
imagePullPolicy: Always
name: argocd-applicationset-controller
ports:
@@ -9886,7 +9886,7 @@ spec:
- -n
- /usr/local/bin/argocd
- /shared/argocd-dex
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
name: copyutil
volumeMounts:
@@ -9919,7 +9919,7 @@ spec:
containers:
- command:
- argocd-notifications
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
tcpSocket:
@@ -10116,7 +10116,7 @@ spec:
value: /helm-working-dir
- name: HELM_DATA_HOME
value: /helm-working-dir
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
failureThreshold: 3
@@ -10165,7 +10165,7 @@ spec:
- -n
- /usr/local/bin/argocd
- /var/run/argocd/argocd-cmp-server
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
name: copyutil
volumeMounts:
- mountPath: /var/run/argocd
@@ -10388,7 +10388,7 @@ spec:
key: server.http.cookie.maxnumber
name: argocd-cmd-params-cm
optional: true
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
httpGet:
@@ -10578,7 +10578,7 @@ spec:
key: controller.default.cache.expiration
name: argocd-cmd-params-cm
optional: true
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
httpGet:

View File

@@ -7101,7 +7101,7 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.namespace
image: quay.io/argoproj/argocd-applicationset:v0.4.0
image: quay.io/argoproj/argocd-applicationset:v0.4.1
imagePullPolicy: Always
name: argocd-applicationset-controller
ports:
@@ -7182,7 +7182,7 @@ spec:
- -n
- /usr/local/bin/argocd
- /shared/argocd-dex
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
name: copyutil
volumeMounts:
@@ -7215,7 +7215,7 @@ spec:
containers:
- command:
- argocd-notifications
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
tcpSocket:
@@ -7412,7 +7412,7 @@ spec:
value: /helm-working-dir
- name: HELM_DATA_HOME
value: /helm-working-dir
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
failureThreshold: 3
@@ -7461,7 +7461,7 @@ spec:
- -n
- /usr/local/bin/argocd
- /var/run/argocd/argocd-cmp-server
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
name: copyutil
volumeMounts:
- mountPath: /var/run/argocd
@@ -7684,7 +7684,7 @@ spec:
key: server.http.cookie.maxnumber
name: argocd-cmd-params-cm
optional: true
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
httpGet:
@@ -7874,7 +7874,7 @@ spec:
key: controller.default.cache.expiration
name: argocd-cmd-params-cm
optional: true
image: quay.io/argoproj/argocd:v2.3.0
image: quay.io/argoproj/argocd:v2.3.1
imagePullPolicy: Always
livenessProbe:
httpGet:

View File

@@ -1136,7 +1136,8 @@ func makeJsonnetVm(appPath string, repoRoot string, sourceJsonnet v1alpha1.Appli
// Jsonnet Imports relative to the repository path
jpaths := []string{appPath}
for _, p := range sourceJsonnet.Libs {
jpath, _, err := pathutil.ResolveFilePath(appPath, repoRoot, p, nil)
// the jsonnet library path is relative to the repository root, not application path
jpath, _, err := pathutil.ResolveFilePath(repoRoot, repoRoot, p, nil)
if err != nil {
return nil, err
}

View File

@@ -254,7 +254,7 @@ func TestGenerateJsonnetManifestInDir(t *testing.T) {
Jsonnet: argoappv1.ApplicationSourceJsonnet{
ExtVars: []argoappv1.JsonnetVar{{Name: "extVarString", Value: "extVarString"}, {Name: "extVarCode", Value: "\"extVarCode\"", Code: true}},
TLAs: []argoappv1.JsonnetVar{{Name: "tlaString", Value: "tlaString"}, {Name: "tlaCode", Value: "\"tlaCode\"", Code: true}},
Libs: []string{"./vendor"},
Libs: []string{"testdata/jsonnet/vendor"},
},
},
},

View File

@@ -105,6 +105,7 @@ export const ApplicationCreatePanel = (props: {
const [yamlMode, setYamlMode] = React.useState(false);
const [explicitPathType, setExplicitPathType] = React.useState<{path: string; type: models.AppSourceType}>(null);
const [destFormat, setDestFormat] = React.useState('URL');
const [retry, setRetry] = React.useState(false);
function normalizeTypeFields(formApi: FormApi, type: models.AppSourceType) {
const app = formApi.getFormState().values;
@@ -222,7 +223,13 @@ export const ApplicationCreatePanel = (props: {
<div className='argo-form-row'>
<label>Sync Options</label>
<FormField formApi={api} field='spec.syncPolicy.syncOptions' component={ApplicationSyncOptionsField} />
<ApplicationRetryOptions formApi={api} field='spec.syncPolicy.retry' />
<ApplicationRetryOptions
formApi={api}
field='spec.syncPolicy.retry'
retry={retry || (api.getFormState().values.spec.syncPolicy && api.getFormState().values.spec.syncPolicy.retry)}
setRetry={setRetry}
initValues={api.getFormState().values.spec.syncPolicy ? api.getFormState().values.spec.syncPolicy.retry : null}
/>
</div>
</div>
);

View File

@@ -79,8 +79,20 @@ export const ApplicationRetryForm = ({initValues, field = 'retryStrategy'}: {ini
);
};
export const ApplicationRetryOptions = ({formApi, initValues, field = 'retryStrategy'}: {formApi: FormApi; field?: string; initValues?: models.RetryStrategy}) => {
const [retry, setRetry] = React.useState(!!initValues);
export const ApplicationRetryOptions = ({
formApi,
initValues,
field = 'retryStrategy',
retry,
setRetry
}: {
formApi: FormApi;
field?: string;
initValues?: models.RetryStrategy;
retry?: boolean;
setRetry?: (value: boolean) => any;
}) => {
const [retryInternal, setRetryInternal] = React.useState(!!initValues);
const toggleRetry = (value: boolean) => {
if (!value) {
@@ -97,15 +109,18 @@ export const ApplicationRetryOptions = ({formApi, initValues, field = 'retryStra
errors: newErrors
});
}
setRetry(value);
if (setRetry != null) {
setRetry(value);
} else {
setRetryInternal(value);
}
};
const isChecked = setRetry != null ? retry : retryInternal;
return (
<div className='application-retry-options'>
<Checkbox id='retry' checked={retry} onChange={val => toggleRetry(val)} />
<Checkbox id='retry' checked={isChecked} onChange={val => toggleRetry(val)} />
<label htmlFor='retry'>Retry</label>
{retry && <ApplicationRetryForm initValues={initValues} field={field} />}
{isChecked && <ApplicationRetryForm initValues={initValues} field={field} />}
</div>
);
};

View File

@@ -127,8 +127,6 @@ const ViewPref = ({children}: {children: (pref: AppsListPreferences & {page: num
}
if (params.get('view') != null) {
viewPref.view = params.get('view') as AppsListViewType;
} else {
viewPref.view = 'tiles' as AppsListViewType;
}
if (params.get('labels') != null) {
viewPref.labelsFilter = params