Skip to content
Snippets Groups Projects
Commit a21a0936 authored by Pierre Kunzli's avatar Pierre Kunzli
Browse files

working on ansible deployment

parent 4f115a34
No related branches found
No related tags found
No related merge requests found
- name: Git checkout bootiful project
become: false
become: true
become_user: bootiful
ansible.builtin.git:
repo: "{{ git_repo }}"
dest: "{{ git_clone_dest }}"
dest: "/home/bootiful/{{ git_clone_dest }}"
version: "{{ git_branch }}"
register: git_checkout_result
#- name: Build bootiful
# become: false
# community.general.make:
# chdir: "{{ git_clone_dest }}"
......@@ -11,8 +11,47 @@
ansible.builtin.apt:
pkg:
- python3-pip
- python-is-python3
- pkg-config
- bison
- flex
- git
- build-essential
- docker.io
- docker-compose
- automake
- autoconf
- autogen
- libtool
- shtool
- htop
- nfs-common
- nfs-kernel-server
- rpcbind
- acl
- autopoint
state: latest
#- docker.io
#- docker-compose
- name: Start service nfs, if not started
become: true
ansible.builtin.service:
name: nfs-utils.service
state: started
enabled: true
- name: Create a user 'bootiful' with a home directory
become: true
ansible.builtin.user:
name: bootiful
create_home: yes
shell: /bin/bash
groups: docker
append: yes
- name: Copying shh key to remote host
become: true
authorized_key:
user: bootiful
state: present
key: "{{ lookup('file', lookup('env','HOME') + '/.ssh/id_rsa.pub')}}"
[bootiful_server]
bootiful_server_1 ansible_port=22 ansible_user=pierre ansible_host=bootiful-server
bootiful_server_1 ansible_port=22 ansible_host=bootiful-server
git_repo: "https://gitedu.hesge.ch/pierre.kunzli/bootiful.git"
git_branch: master
git_branch: ansible
git_clone_dest: bootiful
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment