diff options
author | tv <tv@nomic.retiolum> | 2013-01-29 16:43:31 +0100 |
---|---|---|
committer | tv <tv@nomic.retiolum> | 2013-01-29 16:43:31 +0100 |
commit | 143f844b41e6e7643b523daa8aac0158483da2da (patch) | |
tree | 4873fd7b41b2cf2379f5df60e7c0d3c791987ce6 /services/Makefile | |
parent | 77501543d0f9aa94dcc9a814f420c43e07f09611 (diff) | |
parent | d378ba7014c4757fd78ac437c74ac5cfadd2ccc1 (diff) |
Merge branch 'master' of https://github.com/krebscode/painload
Diffstat (limited to 'services/Makefile')
-rw-r--r-- | services/Makefile | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/services/Makefile b/services/Makefile index 901769b8..3ef670a3 100644 --- a/services/Makefile +++ b/services/Makefile @@ -5,6 +5,15 @@ export host_key_file := test.key export services_home := /opt/services .PHONY: authorized_keys + +service-user: $(services_home)/services.txt $(services_home)/.ssh/authorized_keys + @echo 'also make sure that the user is created: make create-service-user' + +create-service-user: + mkdir -p $(services_home) + rmdir $(services_home) + useradd -m -r -l -f -1 -d $(services_home) services + $(services_home)/.ssh: mkdir $@ chown services:services $@ @@ -18,11 +27,6 @@ $(services_home)/services.txt: @echo 'make sure to configure the services correctly in $(services_home)/services.txt' cp $(services_file) $(services_home)/services.txt -service-user: $(services_home)/services.txt $(services_home)/.ssh/authorized_keys - @echo 'also make sure that the user is created: make create-service-user' - -create-service-user: - useradd -m -r -l -f -1 -d /opt/services services test-client: ssh localhost -p 1337 2>/dev/null |