Skip to content

Commit

Permalink
fix(apps/qbtools): flux cannot decrypt files in generator
Browse files Browse the repository at this point in the history
Instead of using configMapGenerator approach, the `configmap` resource with
encrypted fields has to be imported through `resources` approach.
  • Loading branch information
qlonik committed Dec 23, 2024
1 parent 870ad4f commit f2e063f
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 108 deletions.
26 changes: 26 additions & 0 deletions kubernetes/main/apps/default/qbittorrent/tools/configmap.sops.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: qbtools-configmap
data:
config.yaml: ENC[AES256_GCM,data:o8us1FbVU8EIJE3giU2N6i7+G29+VWd0eNGuFzINuif7+QMD3ICB4b/mt0qKQ523VnSC5OZ1pKTfTuTfRqcweGvWXOnSDtKknscTWKVTvQxqNyK53fByxwgZmbCh2APhFA1zYgo2pdhODcZAWfrqhrFcaTCkhG8HwN/nz0jmUTiGcCm5M7v3UVNplv/qIPh229ukjHo/XfL4QZtV8lfV6IhNFExZBVjtCnso1MqlHbvVfl7t6Ibh+xOfGzv9I/+4gxDCysjdVMytSwTZOsi29sHwpnvHFUNR/o/KxgSVYffPawzJdwnLOvSUC/Rvlno1StFsZRtp5Ib1ax6vExDvLsHAj3/5BWr+TLWHRwvsVArekS5YGHUdzUSnqcdPYHLc7Hai1Eo4kQK3+838CP8MGAcpqdf4ERfhksXAJtzt/XAqCtCj9xOqHuv9Kgp+vcpvjaxQb6anN3dj4C111541ze0hDxQPBaiAaRkvpviBzFI9/nOGM/4+Jz3ImfCgwnjaAVgQ8P2TCodwmsPplWrAJA1raXjQTBZfyNOwLCtAaq2jYWqckJrC/U2DOAb3ANxtlMR7yLKkpYGAGkcyRIZZ9kO6XEKx8VMfQziKZqnuGEdWFwYH0kn17wi4737oDowygwqeOB+4F37lOz00A2Zfe1SXQtAuctb4rWG02x8wtMZdoOnZzGrTq827Z6oc5eruEC03B/L4k8qI6p8ogkxO1KEJHjj/TCTdmvedyovFyWL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aWFvUuWOhos/z3L7pHnN4MdU0sL1EUKmSMGvLHGsYQKvxvHf8FbhDAXOR57d0C4MMeNYE9ohqpoE9ItxO7C33gTRR90qaQ8jOBEfqoOnjGCAbMJEYGer2nr5EgttjeheQ0BOZG8hxjryIollvh8bC/Net/BdfULQTGKfIOlT+eqWIrBMdw7H7d4TQVbUrtjbBQwGLlzumvUKQSiNaAl/0kgO+tJvui8PLJesLBoJGiAGM10Rz8U2Blg7q5CU6dK/EujwbO68b+5ZcCZfcWxAh2cP/WDQx4yHt0Motb+kv3l6Jg4ohTRFhHsD+9z9cAeJUWpJRI8ZCMeKBA67BjRrwSdqdVgDoNG4d/I7LrA2ZD2/2et31rRNplssTKrHwYpLRtK0wG82/vtVzndYLtRiJoMoRqsGw=,iv:fcdvSTUONac3qGkb+pl73/0RxeWwVcKpzVjdIv+hhoA=,tag:MeAg9DYDQ5DfPY4BMh8tGg==,type:str]
sops:
kms: []
gcp_kms: []
azure_kv: []
hc_vault: []
age:
- recipient: age1w68rvrv30t2xfm42ctr02vurav5222065pl03ys6ps5aklraq42s4jeyjl
enc: |
-----BEGIN AGE ENCRYPTED FILE-----
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBIT3g1WWFBOGhZb0hQNy81
OEd2WVl3VCsxSjZBcDVycUJ3LzFaUjQ1OGhFCk5WamFYVU4xVUFnVEZQRXducTlO
Nm9HSlNQQ0lTRThlSzVMM1NJNXBVaGsKLS0tIDZqd1AwM3M0QmRLcFkrLzJ4YUUy
TExTTzRtSjJ1aWV5eWlEdHFMU1E4cUUKEDiuKMXSPUGtW6/4VATZXDl4K0N/f3Wu
iPYEFdBZBMubz438ADHMFgoGQuPQu8Btn1n+S65ZlZFWWDKKPATL8Q==
-----END AGE ENCRYPTED FILE-----
lastmodified: "2024-12-23T04:19:11Z"
mac: ENC[AES256_GCM,data:G5ng6CBUHhuQ0TL7wnFgu7lp606Vse5xP3sJipD5p8SL2iIt/9hgF3Ki042byEPTCfrWGI+WrQb48hCaPMhJWzDz7WtW1VyWH7niCGlstCbM3nEycX/CwHIWim/ZsyRpSr2V41bdLTTRtmQLcnddlLGPGr7HtE0GcvmAflTpTOo=,iv:06T8TwUncYQrtASfaSGsmdVruOsJsBwNE6ShgglU3gQ=,tag:5dKRJM8MFN0UjAeKn4V9KQ==,type:str]
pgp: []
encrypted_regex: ^(data|stringData)$
version: 3.9.1
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,4 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ./helmrelease.yaml

configMapGenerator:
- name: qbtools-configmap
files:
- config.yaml=./resources/config.sops.yaml
generatorOptions:
disableNameSuffixHash: true
annotations:
kustomize.toolkit.fluxcd.io/substitute: disabled
- ./configmap.sops.yaml

This file was deleted.

0 comments on commit f2e063f

Please sign in to comment.