chef: User manage_home not working in chef-client 12.14.60

Description

User home has been working fine, 12.13.37 works.

  user username do
    comment comment
    gid     new_resource.gid
    home    new_resource.home
    supports :manage_home => true
    shell   shell
  end

Chef Version

12.14.60

Platform Version

Ubuntu 14.04

Client Output

When I log onto the box you can see its has not been created:

root@default-ubuntu-1404-1471838078:~# ls -l /home/
total 1
drwxr-xr-x 3 ubuntu ubuntu 6 Sep 13 04:56 ubuntu
root@default-ubuntu-1404-1471838078:~# cat /etc/passwd
root:x:0:0:root:/root:/bin/bash
daemon:x:1:1:daemon:/usr/sbin:/usr/sbin/nologin
bin:x:2:2:bin:/bin:/usr/sbin/nologin
sys:x:3:3:sys:/dev:/usr/sbin/nologin
sync:x:4:65534:sync:/bin:/bin/sync
games:x:5:60:games:/usr/games:/usr/sbin/nologin
man:x:6:12:man:/var/cache/man:/usr/sbin/nologin
lp:x:7:7:lp:/var/spool/lpd:/usr/sbin/nologin
mail:x:8:8:mail:/var/mail:/usr/sbin/nologin
news:x:9:9:news:/var/spool/news:/usr/sbin/nologin
uucp:x:10:10:uucp:/var/spool/uucp:/usr/sbin/nologin
proxy:x:13:13:proxy:/bin:/usr/sbin/nologin
www-data:x:33:33:www-data:/var/www:/usr/sbin/nologin
backup:x:34:34:backup:/var/backups:/usr/sbin/nologin
list:x:38:38:Mailing List Manager:/var/list:/usr/sbin/nologin
irc:x:39:39:ircd:/var/run/ircd:/usr/sbin/nologin
gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/usr/sbin/nologin
nobody:x:65534:65534:nobody:/nonexistent:/usr/sbin/nologin
libuuid:x:100:101::/var/lib/libuuid:
syslog:x:101:104::/home/syslog:/bin/false
messagebus:x:102:106::/var/run/dbus:/bin/false
landscape:x:103:109::/var/lib/landscape:/bin/false
sshd:x:104:65534::/var/run/sshd:/usr/sbin/nologin
pollinate:x:105:1::/var/cache/pollinate:/bin/false
ubuntu:x:1000:1000:Ubuntu:/home/ubuntu:/bin/bash
ntp:x:106:111::/home/ntp:/bin/false
bwright:x:1001:110::/home/bwright:
root@default-ubuntu-1404-1471838078:~# ls -l /home/
total 1
drwxr-xr-x 3 ubuntu ubuntu 6 Sep 13 04:56 ubuntu
root@default-ubuntu-1404-1471838078:~# 

About this issue

  • Original URL
  • State: closed
  • Created 8 years ago
  • Comments: 19 (12 by maintainers)

Commits related to this issue

Most upvoted comments

I was also bit by this and while it is an easy fix it was an aggravation to track down why my cookbook was working fine previously.

@lamont-granquist it’s a breaking change in a minor version bump. Is this normal Chef behavior?

Guys it’s an easy Fix ,although it took me time to find this thread. Can you please update the documentation ? https://docs.chef.io/resource_user.html

@lamont-granquist I think the bigger issue is that the default changed again.

it looks like supports { :manage_home => true } used to be a synonym for manage_home true which “broke”

we can go back to that behavior i guess, but its pretty terrible behavior, and we’ll definitely break everyone with Chef 13.

you’re using supports { :manage_home => true } not manage_home true try using the latter.