Browse Source

Remove systemctl testing task in favor of #4. More debugging.

Jeff Geerling 8 years ago
parent
commit
98b05af85b
3 changed files with 6 additions and 6 deletions
  1. 4 0
      .travis.yml
  2. 0 6
      tasks/init-setup.yml
  3. 2 0
      tests/test.yml

+ 4 - 0
.travis.yml

@@ -51,6 +51,10 @@ script:
     && (echo 'Idempotence test: pass' && exit 0)
     || (echo 'Idempotence test: fail' && exit 1)
 
+  - 'sudo docker exec --tty "$(cat ${container_id})" env TERM=xterm sudo service gogs status'
+  - 'sudo docker exec --tty "$(cat ${container_id})" env TERM=xterm sudo service gogs restart'
+  - sleep 10
+
   # Check if we get an installation page.
   - 'sudo docker exec --tty "$(cat ${container_id})" env TERM=xterm curl http://localhost:3000/install'
 

+ 0 - 6
tasks/init-setup.yml

@@ -9,12 +9,6 @@
     src: "{{ item.src }}"
     dest: "{{ item.dest }}"
     state: link
-  register: gogs_file_symlinks
   with_items:
     - { src: "{{ gogs_user_home }}/gogs/gogs", dest: "/usr/local/bin/gogs" }
     - { src: "{{ gogs_user_home }}/{{ gogs_init_script_path }}" , dest: "/etc/init.d/gogs" }
-
-# SEE: https://github.com/ansible/ansible-modules-core/issues/191
-- name: Restart systemctl daemon on systemd systems.
-  shell: systemctl daemon-reload
-  when: gogs_file_symlinks.changed and (ansible_os_family == "RedHat" and ansible_distribution_major_version|int == 7)

+ 2 - 0
tests/test.yml

@@ -5,6 +5,7 @@
       yum: 'name="{{ item }}" state=present'
       with_items:
         - curl
+        - sudo
         - which
       when: ansible_os_family == 'RedHat'
 
@@ -12,6 +13,7 @@
       apt: 'name="{{ item }}" state=installed'
       with_items:
         - curl
+        - sudo
       when: ansible_os_family == 'Debian'
 
   roles: