Comments (11)
Thanks for trying it out! Your approach is slightly off actually. The example provided in the readme is a sample values.yaml
data for deploying ArgoCD itself. Once it is deployed with the init containers etc then you can create an application with the correct definition and it should work. I’ll send a sample application yaml shortly.
from argo-cd-helmfile.
Sample application source
source:
path: monitoring
plugin:
env:
- name: KUBE_VERSION
value: "1.16"
- name: HELMFILE_GLOBAL_OPTIONS
value: --selector name!=kapacitor,name!=elasticsearch,name!=elasticsearch-curator
name: helmfile
repoURL: <git url>
targetRevision: HEAD
from argo-cd-helmfile.
Thanks for trying it out! Your approach is slightly off actually. The example provided in the readme is a sample
values.yaml
data for deploying ArgoCD itself. Once it is deployed with the init containers etc then you can create an application with the correct definition and it should work. I’ll send a sample application yaml shortly.
Thank you
from argo-cd-helmfile.
Yeah, try it out and make sure it works and then I'll close this down :)
from argo-cd-helmfile.
Can please send me your example application that uses helmfile
from argo-cd-helmfile.
Sure:
kubectl -n argocd get applications.argoproj.io monitoring -o yaml
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
creationTimestamp: "2020-01-09T20:42:22Z"
generation: 107586
name: monitoring
namespace: argocd
resourceVersion: "177714784"
selfLink: /apis/argoproj.io/v1alpha1/namespaces/argocd/applications/monitoring
uid: d0bf1e98-af73-464f-8da4-e6ab26d35b9d
spec:
destination:
namespace: monitoring
server: https://kubernetes.default.svc
project: default
source:
path: monitoring
plugin:
env:
- name: KUBE_VERSION
value: "1.16"
- name: HELMFILE_GLOBAL_OPTIONS
value: --selector name!=kapacitor,name!=elasticsearch,name!=elasticsearch-curator
name: helmfile
repoURL: <repo>
targetRevision: HEAD
status:
...
from argo-cd-helmfile.
Am using like this
---
apiVersion: "argoproj.io/v1alpha1"
kind: "Application"
metadata:
name: "hello-file"
spec:
project: default
source:
repoURL: '[email protected]:xxx/exx-demo.git'
path: "argocd-helm/xxx/test"
plugin:
env:
- name: KUBE_VERSION
value: "1.15"
name: helmfile
destination:
server: 'xxxxxxx'
namespace: default
Argocd-repo-server configured like this
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
annotations: ""
creationTimestamp: "2020-07-23T08:55:38Z"
generation: 4
labels:
app.kubernetes.io/component: repo-server
app.kubernetes.io/name: argocd-repo-server
app.kubernetes.io/part-of: argocd
name: argocd-repo-server
namespace: argocd
spec:
progressDeadlineSeconds: 600
replicas: 1
revisionHistoryLimit: 10
selector:
matchLabels:
app.kubernetes.io/name: argocd-repo-server
strategy:
rollingUpdate:
maxSurge: 25%
maxUnavailable: 25%
type: RollingUpdate
template:
metadata:
creationTimestamp: null
labels:
app.kubernetes.io/name: argocd-repo-server
spec:
automountServiceAccountToken: false
containers:
- command:
- uid_entrypoint.sh
- argocd-repo-server
- --redis
- argocd-redis:6379
image: argoproj/argocd:v1.6.1
imagePullPolicy: Always
livenessProbe:
failureThreshold: 3
initialDelaySeconds: 5
periodSeconds: 10
successThreshold: 1
tcpSocket:
port: 8081
timeoutSeconds: 1
name: argocd-repo-server
ports:
- containerPort: 8081
protocol: TCP
- containerPort: 8084
protocol: TCP
readinessProbe:
failureThreshold: 3
initialDelaySeconds: 5
periodSeconds: 10
successThreshold: 1
tcpSocket:
port: 8081
timeoutSeconds: 1
resources: {}
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
volumeMounts:
- mountPath: /app/config/ssh
name: ssh-known-hosts
- mountPath: /app/config/tls
name: tls-certs
- mountPath: /usr/local/bin/argo-cd-helmfile.sh
name: custom-tools
subPath: argo-cd-helmfile.sh
- mountPath: /usr/local/bin/helmfile
name: custom-tools
subPath: helmfile
dnsPolicy: ClusterFirst
initContainers:
- args:
- wget -qO /custom-tools/argo-cd-helmfile.sh https://raw.githubusercontent.com/travisghansen/argo-cd-helmfile/master/src/argo-cd-helmfile.sh
&& chmod +x /custom-tools/argo-cd-helmfile.sh && wget -qO /custom-tools/helmfile
https://github.com/roboll/helmfile/releases/download/v0.98.2/helmfile_linux_amd64
&& chmod +x /custom-tools/helmfile
command:
- sh
- -c
image: alpine:3.8
imagePullPolicy: IfNotPresent
name: download-tools
resources: {}
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
volumeMounts:
- mountPath: /custom-tools
name: custom-tools
restartPolicy: Always
schedulerName: default-scheduler
securityContext: {}
terminationGracePeriodSeconds: 30
volumes:
- emptyDir: {}
name: custom-tools
- configMap:
defaultMode: 420
name: argocd-ssh-known-hosts-cm
name: ssh-known-hosts
- configMap:
defaultMode: 420
name: argocd-tls-certs-cm
name: tls-certs
and my argocd-cm is
configManagementPlugins: |
- name: helmfile
init:
command: ["argo-cd-helmfile.sh"]
args: ["init"]
and in my repo am application error like this
from argo-cd-helmfile.
OK, I just looked at my configmap and have this:
configManagementPlugins: |
- name: helmfile
init: # Optional command to initialize application source directory
command: ["argo-cd-helmfile.sh"]
args: ["init"]
generate: # Command to generate manifests YAML
command: ["argo-cd-helmfile.sh"]
args: ["generate"]
Try that and then we'll look go from there..
from argo-cd-helmfile.
Oh yeah, I missed that. It works now thank you. Do you think is there any plan for the helm secrets
from argo-cd-helmfile.
I've never messed with helm secrets, nor using them with helmfile so I'd have to do a bit of research. Patches welcome to support it if something extra is required for sure. I'm not entirely sure how those work but don't see why it wouldn't 'just work' regardless.
I'm more inclined to go with something like vault but haven't even done that yet either.
Not sure if it's helpful in your situation, but since helmfile can use ENV vars as values in the various charts, you could just deploy your secret along with the app definition and then reference the ENV vars in your helmfile.
from argo-cd-helmfile.
Thanks for the help
from argo-cd-helmfile.
Related Issues (20)
- Argocd Helmfile plugin should detect changes when refresh or resync from the repository HOT 3
- Helm secrets support HOT 6
- helmfile diff - invalid ownership metadata HOT 5
- Cant read .Capabilities.APIVersions.Has HOT 7
- context deadline exceeded / unknown sync HOT 16
- application spec for testapp is invalid: InvalidSpecError: Unable to generate manifests HOT 6
- How to use helmfile apply option instead of helmfile sync HOT 1
- HOME var overide HOT 7
- set -x eats etcd space
- Support for ArgoCD v2.5.1 HOT 22
- kubectl rollout restart interrupted ? HOT 4
- Mask helm repository password in ArgoCD UI HOT 2
- Private OCI repositories HOT 2
- Helmfile is moved HOT 2
- Error: unknown flag: --skip-crds HOT 10
- Passing args to helm HOT 11
- Issues related to sidecar CMP mode HOT 13
- Autodiscover with apps in app HOT 10
- Helm repository not found HOT 13
- adding kustomize transformers: causes breakage HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from argo-cd-helmfile.