Use this tag if a question is related to centos, the community version of RedHat
Questions tagged [centos]
23 questions
5
votes
3 answers
Validating certificates with get_url or yum on CentOS 7 using Ansible
I'm pretty new to Ansible, but it seemed a better tool than a bash script for installing programs from source on remote servers...
Starting from my working-but-fragile bash script, I made an Ansible script to git clone, configure and compile what I…
TheAtomicOption
- 151
- 1
- 4
3
votes
2 answers
using copy module with wildcards
I need to copy a database backup file from a primary server to a standby server. Since I can't use synchronize, I was following this method:
copy a file from primary to the local ansible server,
copy the file from local ansible server to…
BlackCrystal
- 197
- 2
- 3
- 12
3
votes
1 answer
Porting a docker container to a different Linux host OS
I'm new to Docker. I have looked at many tutorials, however, this is still not clear to me :
For example, If I create a docker image on a system which is using Ubuntu as the host OS. Can I then later port and use this same docker image on a…
Engineer999
- 131
- 2
2
votes
2 answers
How to use edited inventory file?
I have workflow with 2 templates. First I add new host to my hosts.ini file:
- name: Add to host file
blockinfile:
path: /var/lib/awx/projects/_52__glusterfs/hosts.ini
block: |
gluster1 ansible_user=…
Danylo Mysko
- 47
- 5
2
votes
1 answer
How to manage services inside the container?
Systemctl/service commands are not working on a container which is built by using centos:centos7 image.
Can anybody help me here?
deepu dileepkumar
- 21
- 2
2
votes
2 answers
reboot server during Ansible tasks
I have 3 scripts that must be run on server one by one. for example:
- name: find config
shell: /data/scripts/config1
become: yes
become_user: root
tags: find_config
- name: change config
shell: /data/scripts/config2
become: yes
…
BlackCrystal
- 197
- 2
- 3
- 12
2
votes
1 answer
"Error: forwarding ports: Upgrade request required" Error in helm of a kubernetes cluster
I have a kubernetes cluster built using kubespray and imported to Rancher.
The nodes are configured with
CentOS Linux 7 3.10.0-957.12.1.el7.x86_64
Docker version : 18.9.5
Kubelet version : v1.14.1
Tiller version : v2.14.1 ( got this version from…
AnjK
- 121
- 3
2
votes
1 answer
why can't map local path to docker's inside?
I want to build private docker hub. and I did it with:
docker run -it --restart=always -p 7901:5000 -v /data/registry:/tmp/registry registry /bash/bin
And my disk informations as below:
[root@10-19-47-24 docker]# df -lh
Filesystem Size …
Frank AK
- 131
- 4
2
votes
1 answer
vagrant on windows 10 incorrect network configuration on multi-machine setup
I have a problem with vagrant that is running on windows 10 when I deploy centos 8 machines all the machines have eth0 with the same Ip and they cannot communicate with each other
the ip 10.0.2.15 is always present. this is the vagrant file:…
danidar
- 123
- 2
2
votes
1 answer
how to prevent Ansible from showing output on screen?
I have this in my playbook which execute a command on remote server and enters its log on local server.
- name: run script
shell: runuser -l testuser -c "/tmp/test.sh"
register: myshell_output
- name: copy output to a local file
…
BlackCrystal
- 197
- 2
- 3
- 12
1
vote
1 answer
Failed to install kubernetes on centos
Following the official documentation, I have an error when trying to install kubernetes cluster yum package.
I am on Centos 7 using yum. So I run this commands:
cat <
french_dev
- 171
- 1
- 2
- 7
1
vote
1 answer
What is the difference between a jail environment in linux and docker container?
I am curious about difference between a jail environment in linux and Docker. What separates these two technologies?
Vishwanath
- 111
- 1
- 4
0
votes
2 answers
How deploy public key to newly created VM on GCP?
I create VM instance using ansible module gcp_compute_instance
My code:
---
- name: Create jenkins node-1
hosts: localhost
connection: local
gather_facts: no
vars:
address:
project_id: geocitizen-app
machine_type:…
Danylo Mysko
- 47
- 5
0
votes
2 answers
copy contents of file on ansible server to another file on remote servers
I have a bash script on about 70 severs in /opt/zservice/etc/config that i want to change its content with ansible. the new content is on ansible server in this path /data/new_config.
how i can use ansible (how to write a task) that reads this file…
BlackCrystal
- 197
- 2
- 3
- 12
0
votes
1 answer
how to run an Ansible command for specific number of hosts
I am new to Ansible and i have a question about limitting hosts in a host group at running commands.I have these host groups in my inventory:
[primary]
host1
host2
[standby]
host3
host4
i have thses configuration in my .yml:
---
…
BlackCrystal
- 197
- 2
- 3
- 12