initial version

This commit is contained in:
2024-06-20 13:22:58 +02:00
commit 61c4fd0131
3 changed files with 82 additions and 0 deletions

54
awx.yml Normal file
View File

@@ -0,0 +1,54 @@
---
- hosts: pilote1.formation.opendoor.fr
tasks:
- name: get install script 1
get_url:
url: https://get.k3s.io
dest: /tmp/k3S.sh
mode: 0700
- name: run script
command: /tmp/k3S.sh
args:
creates: /usr/local/bin/k3s
- name: get kustomize install script
ansible.builtin.get_url:
url: "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh"
dest: /tmp/
mode: 0700
- name: run kustomize install script
ansible.builtin.command: /tmp/install_kustomize.sh
args:
creates: /usr/local/bin/kustomize
- name: install kustomization file
ansible.builtin.copy:
src: k1.yml
dest: /tmp/kustomization.yaml
- name: kustomize 1
ansible.builtin.shell: "/usr/local/bin/kustomize build . | /usr/local/bin/kubectl apply -f -"
args:
chdir: /tmp
- name: awx-demo.yaml
ansible.builtin.copy:
src: awx-demo.yaml
dest: /tmp/awx-demo.yaml
- name: install kustomization file 2
ansible.builtin.copy:
src: k2.yml
dest: /tmp/kustomization.yaml
- name: set context
ansible.builtin.command: /usr/local/bin/kubectl config set-context --current --namespace=awx
- name: kustomize 2
ansible.builtin.shell: "/usr/local/bin/kustomize build . | /usr/local/bin/kubectl apply -f -"
args:
chdir: /tmp

13
k1.yml Normal file
View File

@@ -0,0 +1,13 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
# Find the latest tag here: https://github.com/ansible/awx-operator/releases
- github.com/ansible/awx-operator/config/default?ref=1.1.4
# Set the image tags to match the git version from above
images:
- name: quay.io/ansible/awx-operator
newTag: 1.1.4
# Specify a custom namespace in which to install AWX
namespace: awx

15
k2.yml Normal file
View File

@@ -0,0 +1,15 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
# Find the latest tag here: https://github.com/ansible/awx-operator/releases
- github.com/ansible/awx-operator/config/default?ref=1.1.4
- awx-demo.yaml
# Set the image tags to match the git version from above
images:
- name: quay.io/ansible/awx-operator
newTag: 1.1.4
# Specify a custom namespace in which to install AWX
namespace: awx