Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tk export -l not working #1336

Open
rezonick opened this issue Feb 3, 2025 · 0 comments
Open

tk export -l not working #1336

rezonick opened this issue Feb 3, 2025 · 0 comments

Comments

@rezonick
Copy link

rezonick commented Feb 3, 2025

% tk --version                                                                          
2025/02/03 14:39:21 tk version v0.29.0

I got the following resource:

% tk show environments/testenv/dev/main.jsonnet

apiVersion: iam.aws.upbound.io/v1beta1
kind: Role
metadata:
  annotations:
    argocd.argoproj.io/sync-wave: "-1"
  labels:
    managedby: crossplane
  name: role-dev
spec:
  forProvider:
    assumeRolePolicy: '{"Statement": [{"Action": ["sts:AssumeRole"], "Condition":
      {"StringEquals": {"sts:ExternalId": "abcabacabac"}},
      "Effect": "Allow", "Principal": {"AWS": ["arn:aws:iam::123412341234:root"]}}],
      "Version": "2012-10-17"}'
  managementPolicies:
  - '*'
  providerConfigRef:
    name: crossplane-provider-config
# Wasn't able to export :(
tk export export/ environments/test/dev/main.jsonnet --merge-strategy fail-on-conflicts --recursive --format {{env.metadata.name}}/resources/{{.kind}}.{{.metadata.name}} -t '!Application/.*' -l "managedby=crossplane"

# Exports
tk export export/ environments/test/dev/main.jsonnet --merge-strategy fail-on-conflicts --recursive --format {{env.metadata.name}}/resources/{{.kind}}.{{.metadata.name}} -t '!Application/.*' -l "managedby!=crossplane"

As you see I want to export all the resources managed by Crossplane which is not ArgoCD Application.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Triage
Development

No branches or pull requests

1 participant