목록2023/08 (14)
삽더하기실수
nginx_install.yml - name: Install nginx on Ubuntu hosts: Ubuntu gather_facts: no become: yes tasks: - name: install nginx web server apt: pkg=nginx state=present update_cache=yes - name: Donwload default index.html for web server get_url: url=https://www.apache.com dest=/usr/share/nginx/html mode=0644 validate_certs=no bash 실행하기 ansible-playbook nginx_install.yml -k
ansible_mnt.yml --- - name: Setup for nfs server hosts: localhost gather_facts: no tasks: - name: make nfs_shared directory file: path: /home/vagrant/nfs_shared state: directory mode: 0777 - name: configure /etc/exports become: yes lineinfile: path: /etc/exports line: /home/vagrant/nfs_shared 192.168.1.0/24(rw,sync) - name : nfs service restart become: yes service : name : nfs state : restarted ..
nfs.yml --- 2 - name: Setup linux timezone 3 hosts: CentOS:Ubuntu 4 gather_facts: no 5 become: yes 6 7 tasks: 8 - name: set Timezone to Asia/Seoul 9 timezone: name=Asia/Seoul /etc/ansible/hosts [CentOS] node01 node02 [Ubuntu] node03 node04 이후 실행명령어 ansible-playbook nfs.yml -k
Ubuntu Vagarnt 파일 설정중 오류가 나온다면 오류화면 Vagrant assumes that this means the command failed! umount /mnt Stdout from the command: Stderr from the command: umount: /mnt: not mounted 해당 명령어를 추가해준다. cfg.vbguest.auto_update = false

1. 크롬에서 F12키를 눌러서 개발자 모드로 들어간다. 2. 해당 부분 클릭 간단하게 드래그가 되는 것을 확인할 수 있다.
nginx_install.yml --- - name: Install nginx on CentOS hosts: CentOS gather_facts: no become: yes # root 권한은 얻어 오는것 tasks: - name: install epel-release yum: name=epel-release state=latest - name: install nginx web server yum: name=nginx state=present - name: Upload default index.html for web server get_url: url=https://www.ginx.com dest=/usr/share/nginx/html mode=0644 - name: Start nginx web serv..

https://sapplusfloat.tistory.com/12 Vagrantfile(node1,2,server) 구성하기 Vagrantfile Vagrant_API_Version = "2" Vagrant.configure(Vagrant_API_Version) do |config| config.vm.define "ansible-node01" do |cfg| cfg.vm.box = "centos/7" cfg.vbguest.installer_hooks[:before_install] = ["yum install -y epel-release", "sleep 1"] cfg.vbgues sapplusfloat.tistory.com 해당 글 뒤로 이어집니다. bash_ssh_conf_4_CentOS.sh #! /us..
Vagrantfile Vagrant_API_Version = "2" Vagrant.configure(Vagrant_API_Version) do |config| config.vm.define "ansible-node01" do |cfg| cfg.vm.box = "centos/7" cfg.vbguest.installer_hooks[:before_install] = ["yum install -y epel-release", "sleep 1"] cfg.vbguest.installer_options = { allow_kernel_upgrade: false, enablerepo: true } cfg.vm.provider :virtualbox do |vb| vb.name = "Ansible-node01(Udemy-Bl..