diff --git a/Repositories/otago_eprints/Makefile b/Repositories/otago_eprints/Makefile index 0c71102..0a50cf3 100755 --- a/Repositories/otago_eprints/Makefile +++ b/Repositories/otago_eprints/Makefile @@ -40,7 +40,7 @@ --recursive --times . $(EPRINTS_ROOT)/archives > .del-rsync-output @-grep $(ARCHIVE_NAME) .del-rsync-output @announce "Correcting ownership..." - sudo chown -R www:www $(ARCHIVE_CONFIG) $(ARCHIVE_ROOT) + sudo chown -R $(EPRINTS_USER):$(EPRINTS_USER) $(ARCHIVE_CONFIG) $(ARCHIVE_ROOT) @-grep --quiet "$(ARCHIVE_NAME)\\.xml" .del-rsync-output && $(MAKE) generate_apacheconf @-grep --quiet "$(ARCHIVE_NAME)/cfg/subjects" .del-rsync-output && $(MAKE) import_subjects @-grep --quiet "\\(otago_eprints/cfg/static/\\)\\|\\(\\.xml\\)" .del-rsync-output && $(MAKE) generate_static @@ -62,19 +62,19 @@ generate_apacheconf: @announce "generate_apacheconf" - @sudo -u www touch -r $(ARCHIVE_NAME).xml $(ARCHIVE_CONFIG) - @sudo -u www $(BINDIR)/$@ + @sudo -u $(EPRINTS_USER) touch -r $(ARCHIVE_NAME).xml $(ARCHIVE_CONFIG) + @sudo -u $(EPRINTS_USER) $(BINDIR)/$@ import_subjects generate_static generate_abstracts generate_views: @announce "$@ $(ARCHIVE_NAME)" - @sudo -u www $(BINDIR)/$@ $(ARCHIVE_NAME) + @sudo -u $(EPRINTS_USER) $(BINDIR)/$@ $(ARCHIVE_NAME) restart_apache: @announce "Waiting for Apache to shut down..." @sudo /sw/sbin/apachectl stop - @sudo -u www touch -r $(ARCHIVE_NAME)/cfg/apachevhost.conf $(ARCHIVE_ROOT)/cfg/apachevhost.conf + @sudo -u $(EPRINTS_USER) touch -r $(ARCHIVE_NAME)/cfg/apachevhost.conf $(ARCHIVE_ROOT)/cfg/apachevhost.conf @sleep 10 @announce "Waiting for Apache to start up..." @sudo /sw/sbin/apachectl start @@ -83,13 +83,13 @@ index: @announce "Rebuilding indexes..." - @sudo -u www $(BINDIR)/indexer start --once --notdaemon + @sudo -u $(EPRINTS_USER) $(BINDIR)/indexer start --once --notdaemon stats: @announce "Generating statistics..." - @sudo -u www php $(EPRINTS_ROOT)/ePrintsStats/scripts/eprints-usage.php -# @sudo -u www perl $(EPRINTS_ROOT)/ePrintsStats/scripts/add_country.pl + @sudo -u $(EPRINTS_USER) php $(EPRINTS_ROOT)/ePrintsStats/scripts/eprints-usage.php +# @sudo -u $(EPRINTS_USER) perl $(EPRINTS_ROOT)/ePrintsStats/scripts/add_country.pl debug: