Outils pour utilisateurs

Outils du site


tech:awx_-_build_to_run

Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Les deux révisions précédentesRévision précédente
Prochaine révision
Révision précédente
tech:awx_-_build_to_run [2025/11/12 15:46] Jean-Baptistetech:awx_-_build_to_run [2026/01/20 10:43] (Version actuelle) Jean-Baptiste
Ligne 16: Ligne 16:
 | RAM           16 GB                                              | | RAM           16 GB                                              |
 | CPUs        |    4                                                 | | CPUs        |    4                                                 |
-| Local disk  |   40 GB min & min 20GB available under /var/lib/awx  |+| Local disk  |   40 GB min (20GB min available under /var/lib/awx |
 | Local disk  | 1500 IOPS                                            | | Local disk  | 1500 IOPS                                            |
  
Ligne 54: Ligne 54:
 * Réactiver SELinux * Réactiver SELinux
 * Après avoir redéfini ''ipv6_disabled'', si OK désactiver l'IPv6 sur le hôte et tester * Après avoir redéfini ''ipv6_disabled'', si OK désactiver l'IPv6 sur le hôte et tester
 +
 +Changer dans Job settings - Container Run Options
 +~~~python
 +[
 +  "--network",
 +  "slirp4netns:enable_ipv6=true"
 +]
 +~~~
 +
 +Désactiver le SWAP. Totalement ou `memory.swap.max=0` ?
 +Voir 
 +~~~bash
 +cat /sys/fs/cgroup/memory.swap.max
 +~~~
  
  
Ligne 61: Ligne 75:
  
 ~~~bash ~~~bash
-podman update --restart-policy=always kind-control-plane+podman update --restart=always kind-control-plane
 ~~~ ~~~
  
 A la place de ''~/.config/systemd/user/container-kind-control-plane.service'' A la place de ''~/.config/systemd/user/container-kind-control-plane.service''
 +
 +
 +
 +## Réseau 
 +
 +Voir :
 +* https://www.sfeir.dev/cloud/un-cluster-kubernetes-local-en-quelques-secondes-avec-kind/
 +* https://www.metal3d.org/blog/2021/kind-avec-podman/
  
  
Ligne 81: Ligne 103:
 * ipv6_disabled * ipv6_disabled
  
-FIXME+ 
 + 
 +## Sauvegarde 
 + 
 +De tous les objets AWX : 
 +~~~bash 
 +awx -f yaml export > all.yaml 
 +~~~~ 
 + 
 +FIXME: prévoir l'export / import de la base 
 + 
 + 
 + 
 +## PoC Stockage 
 + 
 +Voir : 
 +* https://www.redhat.com/en/blog/when-localhost-isnt-what-it-seems-in-red-hat-ansible-automation-platform-2?sc_cid=7015Y000003t7aWQAQ 
 +* https://github.com/ansible/awx/issues/10461 
 +* https://github.com/ansible/awx-operator/pull/412 
 +* https://stackoverflow.com/questions/67747550/how-can-i-expose-local-data-path-to-the-temporary-job-container-awx-job-xxxxx 
 +* https://github.com/ansible/awx/issues/15012 
 +* https://goteleport.com/docs/machine-workload-identity/access-guides/ansible-awx/ 
 +* https://forum.ansible.com/t/the-default-execution-environment-cannot-mount-the-local-nfs-storage-volume/3472 
 +* https://docs.redhat.com/en/documentation/red_hat_ansible_automation_platform/2.3/html-single/red_hat_ansible_automation_platform_performance_considerations_for_operator_based_installations/index 
 + 
 + 
 + 
 +''cluster-config.yml'' 
 +~~~yaml 
 +kind: Cluster 
 +apiVersion: kind.x-k8s.io/v1alpha4 
 +nodes: 
 +- role: control-plane 
 +  extraPortMappings: 
 +    - containerPort: 30000 
 +      hostPort: 30000 
 +      protocol: TCP 
 +  extraMounts: 
 +    - containerPath: /data/files 
 +      hostPath: /data/files 
 +~~~    
 + 
 +''ansible-files-pv.yml'' 
 +~~~yaml 
 +--- 
 +apiVersion: v1 
 +kind: PersistentVolume 
 +metadata: 
 +  name: awx-ansible-files-volume 
 +spec: 
 +  accessModes: 
 +    - ReadWriteOnce 
 +  persistentVolumeReclaimPolicy: Retain 
 +  capacity: 
 +    storage: 2Gi 
 +  storageClassName: local-path 
 +  hostPath: 
 +    path: /data/ansible-files 
 +~~~ 
 + 
 + 
 + 
 +''ansible-files-pvc.yml'' 
 +~~~yaml 
 +--- 
 +apiVersion: v1 
 +kind: PersistentVolumeClaim 
 +metadata: 
 +  name: awx-ansible-files-claim 
 +spec: 
 +  accessModes: 
 +    - ReadWriteOnce 
 +  volumeMode: Filesystem 
 +  resources: 
 +    requests: 
 +      storage: 2Gi 
 +  storageClassName: local-path 
 + 
 +~~~ 
 + 
 +~~~bash 
 +kubectl create secret generic awx-custom-certs --from-file=bundle-ca.crt=/etc/ssl/certs/ca-bundle.crt 
 +~~~ 
 + 
 + 
 +''cluster-config.yml'' 
 +~~~yaml 
 +--- 
 + 
 +kind: Cluster 
 +apiVersion: kind.x-k8s.io/v1alpha4 
 +nodes: 
 +  - role: control-plane 
 +    extraPortMappings: 
 +      - containerPort: 30000 
 +        hostPort: 30000 
 +        protocol: TCP 
 +    extraMounts: 
 +      - containerPath: /data/ansible-files 
 +        hostPath: /data/ansible-files 
 +      - containerPath: /data/projects 
 +        hostPath: /data/projects 
 +      - containerPath: /data/postgres-13 
 +        hostPath: /data/postgres-13 
 +~~~ 
 + 
 + 
 + 
 + 
 +Fixer la version avec l'option `--image` 
 +~~~bash 
 +kind create cluster --image kindest/node:v1.34.2 
 +~~~ 
 +Available tags can be found at https://hub.docker.com/r/kindest/node/tags 
 + 
 +~~~bash 
 +kind create cluster --config=cluster-config.yml --name=kind2 
 + 
 +# kubectl create deployment nginx --image=nginx --port=80 
 +# kubectl create service nodeport nginx --tcp=80:80 --node-port=30000 
 + 
 +kubectl create service nodeport awx-service --tcp=80:80 --node-port=30000 
 +~~~ 
 + 
 + 
 + 
 +Dans jobs settings changer : 
 + 
 +Paths to expose to isolated jobs 
 +~~~python 
 +
 +  "/etc/pki/ca-trust:/etc/pki/ca-trust:O", 
 +  "/usr/share/pki:/usr/share/pki:O" 
 +
 +~~~
  
  
tech/awx_-_build_to_run.1762958785.txt.gz · Dernière modification : de Jean-Baptiste

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki