Skip to content

Commit 1c70ac5

Browse files
authored
Merge pull request #7 from hellofresh/feature/trusty-support
PTII-273 Add ubuntu trusty support
2 parents e262f01 + 8e84d30 commit 1c70ac5

File tree

3 files changed

+19
-4
lines changed

3 files changed

+19
-4
lines changed

molecule/default/molecule.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,12 @@ driver:
66
lint:
77
name: yamllint
88
platforms:
9+
- name: ubuntu-trusty
10+
image: ubuntu-upstart
11+
command: /sbin/init
12+
privileged: True
913
- name: ubuntu-xenial
10-
image: solita/ubuntu-systemd:latest
14+
image: solita/ubuntu-systemd
1115
command: /sbin/init
1216
privileged: True
1317
capabilities:

molecule/default/tests/test_default.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,14 @@ def test_sssd_service_state(host):
2626

2727

2828
def test_sshd_service_state(host):
29-
assert host.service('sshd').is_enabled
30-
assert host.service('sshd').is_running
29+
ssh_service_name = {
30+
'centos': 'sshd',
31+
'ubuntu': 'ssh'
32+
}
33+
assert host.service(
34+
ssh_service_name[host.system_info.distribution]).is_enabled
35+
assert host.service(
36+
ssh_service_name[host.system_info.distribution]).is_running
3137

3238

3339
def test_ssh_access(host):

tasks/sshd.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,10 @@
1515

1616
- name: sshd | ensure sshd service is enabled
1717
service:
18-
name: sshd
18+
name: "{{ sssd_ldap_ssh_service }}"
1919
enabled: true
20+
21+
- name: sshd | ensure sshd service is started
22+
service:
23+
name: "{{ sssd_ldap_ssh_service }}"
24+
state: started

0 commit comments

Comments
 (0)