You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

38 lines
1.8 KiB

  1. ---
  2. - name: Set timezone
  3. when: timezone is defined
  4. file: path=/etc/localtime state=link src=/usr/share/zoneinfo/{{timezone}} force=yes
  5. #Three commands to install a service on CentOS/RedHat
  6. #wget -O - http://tendermint-packages.s3-website-us-west-1.amazonaws.com/centos/7/os/x86_64/RPM-GPG-KEY-Tendermint | rpm --import -
  7. #wget -O /etc/yum.repos.d/tendermint.repo http://tendermint-packages.s3-website-us-west-1.amazonaws.com/centos/7/os/x86_64/tendermint.repo
  8. #yum update && yum install basecoin
  9. #This has a bug in Ansible 2.3: https://github.com/ansible/ansible/issues/20711
  10. #- name: Add repository key on CentOS/RedHat
  11. # when: ansible_os_family == "RedHat"
  12. # rpm_key: key=http://tendermint-packages.s3-website-us-west-1.amazonaws.com/centos/7/os/x86_64/RPM-GPG-KEY-Tendermint
  13. #Workaround
  14. - name: Download repository key for CentOS/RedHat
  15. when: ansible_os_family == "RedHat"
  16. get_url: "url=http://tendermint-packages.s3-website-us-west-1.amazonaws.com/centos/7/os/x86_64/RPM-GPG-KEY-Tendermint dest=/root/RPM-GPG-KEY-Tendermint force=yes checksum=sha256:a8c61d4061697d2595562c703dbafbdfdcfa7f0c75a523ac84d5609d1b444abe"
  17. - name: Import repository key for CentOS/RedHat
  18. when: ansible_os_family == "RedHat"
  19. command: "rpm --import /root/RPM-GPG-KEY-Tendermint"
  20. - name: Install tendermint repository on CentOS/RedHat
  21. when: ansible_os_family == "RedHat"
  22. yum_repository:
  23. name: tendermint
  24. baseurl: http://tendermint-packages.s3-website-us-west-1.amazonaws.com/centos/7/os/x86_64
  25. description: "Tendermint repo"
  26. gpgcheck: yes
  27. gpgkey: http://tendermint-packages.s3-website-us-west-1.amazonaws.com/centos/7/os/x86_64/RPM-GPG-KEY-Tendermint
  28. # repo_gpgcheck: yes
  29. - name: Install package on CentOS/RedHat
  30. when: ansible_os_family == "RedHat"
  31. yum: "pkg={{service}} update_cache=yes state=latest"