Skip to content

Commit

Permalink
[v2.7] resolve conflicts
Browse files Browse the repository at this point in the history
Signed-off-by: Chanwit Kaewkasi <chanwit@gmail.com>
  • Loading branch information
chanwit committed Jun 20, 2023
1 parent 82ef5e4 commit 07ce8cf
Show file tree
Hide file tree
Showing 10 changed files with 50 additions and 23 deletions.
16 changes: 16 additions & 0 deletions fix-patch.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/bin/bash

INDEX=$(printf "%02d" $1)
# index is like 01, 02, 03

# lookup patch from index for example: ../patches-argo-cd/05-a-b-c-d.patch
PATCH="../patches-argo-cd/${INDEX}-*.patch"

COMMIT_MESSAGE=$(cat $PATCH | head -1)

# do commit and convert into stg patch
git commit -s -am "${COMMIT_MESSAGE}"
stg repair

# double check
stg series
8 changes: 4 additions & 4 deletions patches-argo-cd-v2.7/01-build-with-local-gitops-engine.patch
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ index 869bb876f..e05fdda3e 100644
+
+gitops-engine/
diff --git a/Dockerfile b/Dockerfile
index 1e6393773..e19d11e4b 100644
index e6b4e4da3..90468266a 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -105,7 +105,9 @@ FROM --platform=$BUILDPLATFORM docker.io/library/golang:1.19.6@sha256:7ce31d15a3
@@ -105,7 +105,9 @@ FROM --platform=$BUILDPLATFORM docker.io/library/golang:1.19.10@sha256:83f9f8400

WORKDIR /go/src/github.com/argoproj/argo-cd

Expand Down Expand Up @@ -51,10 +51,10 @@ index 1e6393773..e19d11e4b 100644
ln -s /usr/local/bin/argocd /usr/local/bin/argocd-repo-server && \
ln -s /usr/local/bin/argocd /usr/local/bin/argocd-cmp-server && \
diff --git a/go.mod b/go.mod
index 7bc3dc688..c2c379a44 100644
index 04bed2b5a..adbb11ab4 100644
--- a/go.mod
+++ b/go.mod
@@ -297,4 +297,6 @@ replace (
@@ -298,4 +298,6 @@ replace (
k8s.io/mount-utils => k8s.io/mount-utils v0.24.2
k8s.io/pod-security-admission => k8s.io/pod-security-admission v0.24.2
k8s.io/sample-apiserver => k8s.io/sample-apiserver v0.24.2
Expand Down
4 changes: 2 additions & 2 deletions patches-argo-cd-v2.7/02-implement-loopback.patch
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ Signed-off-by: Chanwit Kaewkasi <chanwit@gmail.com>
create mode 100644 controller/state_fsa.go

diff --git a/controller/state.go b/controller/state.go
index 6323993e3..423bc039d 100644
index cac9b75af..169f697a2 100644
--- a/controller/state.go
+++ b/controller/state.go
@@ -411,11 +411,17 @@ func (m *appStateManager) CompareAppState(app *v1alpha1.Application, project *ap
@@ -418,11 +418,17 @@ func (m *appStateManager) CompareAppState(app *v1alpha1.Application, project *ap
}
}

Expand Down
6 changes: 3 additions & 3 deletions patches-argo-cd-v2.7/03-allow-flux-and-oci-schemes.patch
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ Signed-off-by: Chanwit Kaewkasi <chanwit@gmail.com>
3 files changed, 14 insertions(+)

diff --git a/reposerver/repository/repository.go b/reposerver/repository/repository.go
index 7bf36865d..2b0d277a5 100644
index 1ad311fe5..bed5f3b8c 100644
--- a/reposerver/repository/repository.go
+++ b/reposerver/repository/repository.go
@@ -2437,6 +2437,11 @@ func (s *Service) TestRepository(ctx context.Context, q *apiclient.TestRepositor
@@ -2438,6 +2438,11 @@ func (s *Service) TestRepository(ctx context.Context, q *apiclient.TestRepositor
}
check := checks[repo.Type]
apiResp := &apiclient.TestRepositoryResponse{VerifiedRepository: false}
Expand All @@ -26,7 +26,7 @@ index 7bf36865d..2b0d277a5 100644
if err != nil {
return apiResp, fmt.Errorf("error testing repository connectivity: %w", err)
diff --git a/server/application/application.go b/server/application/application.go
index 24758281a..184cfae19 100644
index cef7b36c6..b35d2f463 100644
--- a/server/application/application.go
+++ b/server/application/application.go
@@ -1929,6 +1929,10 @@ func (s *Server) resolveRevision(ctx context.Context, app *appv1.Application, sy
Expand Down
2 changes: 1 addition & 1 deletion patches-argo-cd-v2.7/04-ui-fix-find-leaf-pod-bug.patch
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ index 647750937..a440f3db1 100644

const settings = await services.authService.settings();
diff --git a/ui/src/app/applications/components/utils.tsx b/ui/src/app/applications/components/utils.tsx
index 7e4fed73c..c13f6eff4 100644
index b30ddc87f..62f5633b7 100644
--- a/ui/src/app/applications/components/utils.tsx
+++ b/ui/src/app/applications/components/utils.tsx
@@ -457,7 +457,8 @@ function getActionItems(
Expand Down
20 changes: 10 additions & 10 deletions patches-argo-cd-v2.7/05-ui-show-kstatus-in-ui.patch
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,18 @@ Signed-off-by: Chanwit Kaewkasi <chanwit@gmail.com>
1 file changed, 13 insertions(+)

diff --git a/ui/src/app/applications/components/application-node-info/application-node-info.tsx b/ui/src/app/applications/components/application-node-info/application-node-info.tsx
index ee0e2516c..abf4c6174 100644
index 8ac1a46d5..e63b023a7 100644
--- a/ui/src/app/applications/components/application-node-info/application-node-info.tsx
+++ b/ui/src/app/applications/components/application-node-info/application-node-info.tsx
@@ -11,6 +11,7 @@ import {ApplicationResourcesDiff} from '../application-resources-diff/applicatio
import {
ComparisonStatusIcon,
formatCreationTimestamp,
+ getKstatusCondition,
getPodReadinessGatesState,
getPodReadinessGatesState as _getPodReadinessGatesState,
getPodStateReason,
@@ -69,6 +70,18 @@ export const ApplicationNodeInfo = (props: {
@@ -9,6 +9,7 @@ import {services} from '../../../shared/services';
import {ResourceTreeNode} from '../application-resource-tree/application-resource-tree';
import {ApplicationResourcesDiff} from '../application-resources-diff/application-resources-diff';
import {ComparisonStatusIcon, formatCreationTimestamp, getPodReadinessGatesState, getPodStateReason, HealthStatusIcon} from '../utils';
+import {getKstatusCondition} from '../utils';
import './application-node-info.scss';
import {ReadinessGatesNotPassedWarning} from './readiness-gates-not-passed-warning';

@@ -61,6 +62,18 @@ export const ApplicationNodeInfo = (props: {
attributes.push({title: 'HOSTNAMES', value: hostNames});
} else if (props.node.kind === 'ReplicaSet') {
attributes.push({title: 'REPLICAS', value: `${props.live.spec?.replicas || 0}/${props.live.status?.readyReplicas || 0}/${props.live.status?.replicas || 0}`});
Expand Down
2 changes: 1 addition & 1 deletion patches-argo-cd-v2.7/12-add-open-in-weave-gitops.patch
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Signed-off-by: Chanwit Kaewkasi <chanwit@gmail.com>
1 file changed, 45 insertions(+)

diff --git a/ui/src/app/applications/components/utils.tsx b/ui/src/app/applications/components/utils.tsx
index c13f6eff4..3ff4b7841 100644
index 62f5633b7..c19533d8a 100644
--- a/ui/src/app/applications/components/utils.tsx
+++ b/ui/src/app/applications/components/utils.tsx
@@ -423,6 +423,28 @@ function getResourceActionsMenuItems(resource: ResourceTreeNode, metadata: model
Expand Down
2 changes: 1 addition & 1 deletion patches-argo-cd-v2.7/series
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# This series applies on GIT commit cbee7e6011407ed2d1066c482db74e97e0cc6bdb
# This series applies on GIT commit a2430af1c356b283e5e3fc5bde1f5e2b5199f258
01-build-with-local-gitops-engine.patch
02-implement-loopback.patch
03-allow-flux-and-oci-schemes.patch
Expand Down
2 changes: 1 addition & 1 deletion patches-gitops-engine-v2.0.0/series
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
# This series applies on GIT commit 917f5a0f16d57162a335e8134230e714de4faa05
# This series applies on GIT commit ad9a694fe4bcc833d7619faa391b77dd587f852d
01-fsa-add-flux-ks-and-hr.patch
11 changes: 11 additions & 0 deletions try-patch.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/bin/bash

INDEX=$(printf "%02d" $1)
# index is like 01, 02, 03

# lookup patch from index for example: ../patches-argo-cd/05-a-b-c-d.patch
PATCH="../patches-argo-cd/${INDEX}-*.patch"

git apply -3 $PATCH
git diff
git status

0 comments on commit 07ce8cf

Please sign in to comment.