Outils pour utilisateurs

Outils du site


tech:ansible_docker_execution_environment

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:ansible_docker_execution_environment [2026/06/07 19:12] – modification externe 127.0.0.1tech:ansible_docker_execution_environment [2026/11/06 23:15] (Version actuelle) – Jean-Baptiste
Ligne 5: Ligne 5:
  
 Voir : Voir :
-FIXME2 
 * [[notes_ansible_ansible-navigator|ansible-navigator]] * [[notes_ansible_ansible-navigator|ansible-navigator]]
 * https://ansible.readthedocs.io/projects/creator/installing/#initialize-execution-environment-project * https://ansible.readthedocs.io/projects/creator/installing/#initialize-execution-environment-project
 * https://github.com/redhat-cop/ee_utilities/blob/devel/examples/ee_builder_base.yaml * https://github.com/redhat-cop/ee_utilities/blob/devel/examples/ee_builder_base.yaml
-* [[https://developers.redhat.com/articles/2023/05/08/how-create-execution-environments-using-ansible-builder|How to create execution environments using ansible-builder]]+* [|How to create execution environments using ansible-builder](https://developers.redhat.com/articles/2023/05/08/how-create-execution-environments-using-ansible-builder)
 * https://docs.ansible.com/automation-controller/latest/html/userguide/ee_reference.html * https://docs.ansible.com/automation-controller/latest/html/userguide/ee_reference.html
 * https://blog.stephane-robert.info/post/ansible-execution-environnement-runner-builder/ * https://blog.stephane-robert.info/post/ansible-execution-environnement-runner-builder/
Ligne 33: Ligne 32:
  
 ~~~bash ~~~bash
-pip install --user ansible-builder>=3.0.0+pip install --user 'ansible-builder>=3.0.0'
 ~~~ ~~~
  
Ligne 265: Ligne 264:
     name: ghcr.io/ansible-community/community-ee-base:2.19.1-1     name: ghcr.io/ansible-community/community-ee-base:2.19.1-1
  
-# additional_build_files: +additional_build_files: 
-#     - src: files/ansible.cfg +  - src: files/ca.crt 
-#       dest: configs+    dest: files/
  
 additional_build_steps: additional_build_steps:
Ligne 273: Ligne 272:
 #    - ADD _build/configs/ansible.cfg ~/.ansible.cfg #    - ADD _build/configs/ansible.cfg ~/.ansible.cfg
   prepend_base:   prepend_base:
-    # - RUN echo PLOP+    # - RUN echo "cacert=/runner/ca.crt" > .curlrc 
 +    - ADD _build/files/ca.crt /etc/pki/ca-trust/source/anchors/ 
 +    - RUN update-ca-trust
   append_final:   append_final:
     # - RUN groupadd --gid 1000 vscode     # - RUN groupadd --gid 1000 vscode
Ligne 359: Ligne 360:
 Exemple de fichier bindep.txt : Exemple de fichier bindep.txt :
 * https://github.com/openstack/openstack-ansible/blob/master/bindep.txt * https://github.com/openstack/openstack-ansible/blob/master/bindep.txt
 +
 +
 +-------
 +
 +
 +# Execution environment
 +
 +
 +## Usage
 +
 +Creation d'un EE
 +~~~bash
 +ansible-builder build -v 3 --tag ee-base:v0.0.2
 +~~~
 +
 +Disable SSL/TLS for registry
 +~~~bash
 +cat <<EOF > ~/.config/containers/registries.conf
 +[registries.insecure]
 +registries = ['localhost:5000']
 +EOF
 +~~~
 +
 +Push
 +~~~bash
 +kubectl port-forward svc/registry 5000:5000
 +
 +podman tag localhost/awx-ee-gts-it:2.19.3-2-1 localhost:5000/awx-ee-gts-it:2.19.3-2-1
 +podman push localhost:5000/awx-ee-gts-it:2.19.3-2-1
 +~~~
 +
 +
 +
 +## Lancer un playbook dans un EE avec ansible-runner ou ansible-navigator
 +
 +Voir :
 +* https://docs.ansible.com/_/downloads/runner/en/latest/pdf/
 +
 +
 +~~~bash
 +ansible-runner run --container-image localhost/ee-base:v0.0.2 --inventory=inv.yml ~/playbooks/ -p ~/playbooks/play-test.yml
 +# ou
 +ansible-navigator run --mode stdout -u ansible ~/tmp/play-test.yml --inventory=inv.yml --eei localhost/ee-base:v0.0.2 -u ansible
 +~~~
 +
 +## Autres
 +
 +Analyse d'un EE
 +~~~bash
 +ansible-navigator --eei localhost/ee-base:v0.0.2 images -d | tee ee-base_v0.0.2.yml
 +~~~
 +
 +
 +## Hack Error "server gave HTTP response to HTTPS client"
 +
 +~~~bash
 +podman exec -ti kind-control-plane /bin/bash
 +ctr -n k8s.io image pull --plain-http=true 10.96.158.74:5000/awx-ee-gts-it:2.19.3-2-1
 +~~~
 +
 +PS : 10.96.158.74 for registry.test.svc.cluster.local
  
  
  
  
tech/ansible_docker_execution_environment.1780852327.txt.gz · Dernière modification : de 127.0.0.1

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki