-
-
Save armenr/c9af67ae20d1a0849bc5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# Cookbook Name:: myapp-bot | |
# Recipe:: _botuser.rb | |
# | |
# | |
# | |
# | |
# | |
# Create user & group | |
user 'gravbot' do | |
supports :manage_home => true | |
gid 'users' | |
end | |
group 'gravbot' do | |
action :create | |
members ['gravbot'] | |
end | |
# Set up ssh items | |
directory '/home/gravbot/.ssh' do | |
owner 'gravbot' | |
group 'gravbot' | |
mode '0755' | |
recursive true | |
action :create | |
end | |
file '/home/gravbot/.ssh/config' do | |
action :create | |
owner 'gravbot' | |
group 'gravbot' | |
mode '0644' | |
content <<-EOF | |
Host * | |
StrictHostKeyChecking no | |
EOF | |
end | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment