Skip to content
This repository has been archived by the owner on Jul 12, 2023. It is now read-only.

Commit

Permalink
Break-up Makefile lines
Browse files Browse the repository at this point in the history
I tried a few layouts. The only one I can really rationalize is
committing to newlines 100%.
  • Loading branch information
ross-spencer committed Aug 5, 2020
1 parent 82081b3 commit c88f15b
Showing 1 changed file with 75 additions and 10 deletions.
85 changes: 75 additions & 10 deletions compose/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -114,24 +114,89 @@ restart-am-services: ## Restart Archivematica services: MCPServer, MCPClient, D
CALLER_GID=$(shell id -u)

compile-am-requirements-am: ## Run pip-compile for Archivematica
docker-compose run --workdir /src/MCPServer/requirements --volume "tmpfs:/pip-cache:rw" -e XDG_CACHE_HOME=/pip-cache --rm --no-deps --user=root --entrypoint bash archivematica-mcp-server -c "make clean && make all"
docker-compose run --workdir /src/MCPClient/requirements --volume "tmpfs:/pip-cache:rw" -e XDG_CACHE_HOME=/pip-cache --rm --no-deps --user=root --entrypoint bash archivematica-mcp-client -c "make clean && make all"
docker-compose run --workdir /src/dashboard/src/requirements --volume "tmpfs:/tmp/pip-cache:rw" -e XDG_CACHE_HOME=/tmp//pip-cache --rm --no-deps --user=root --entrypoint bash archivematica-dashboard -c "make clean && make all"
docker-compose run --workdir /src/archivematicaCommon/requirements --volume "tmpfs:/pip-cache:rw" -e XDG_CACHE_HOME=/pip-cache --rm --no-deps --user=root --entrypoint bash archivematica-dashboard -c "make clean && make all"
docker-compose run --workdir /src/MCPServer/requirements \
--volume "tmpfs:/pip-cache:rw" \
-e XDG_CACHE_HOME=/pip-cache \
--rm \
--no-deps \
--user=root \
--entrypoint bash archivematica-mcp-server \
-c "make clean && make all"
docker-compose run --workdir /src/MCPClient/requirements \
--volume "tmpfs:/pip-cache:rw" \
-e XDG_CACHE_HOME=/pip-cache \
--rm \
--no-deps \
--user=root \
--entrypoint bash archivematica-mcp-client \
-c "make clean && make all"
docker-compose run --workdir /src/dashboard/src/requirements \
--volume "tmpfs:/tmp/pip-cache:rw" \
-e XDG_CACHE_HOME=/tmp//pip-cache \
--rm \
--no-deps \
--user=root \
--entrypoint bash archivematica-dashboard \
-c "make clean && make all"
docker-compose run --workdir /src/archivematicaCommon/requirements \
--volume "tmpfs:/pip-cache:rw" \
-e XDG_CACHE_HOME=/pip-cache \
--rm \
--no-deps \
--user=root \
--entrypoint bash archivematica-dashboard \
-c "make clean && make all"
@$(MAKE) --no-print-directory reset-permissions-to-user-am

compile-am-requirements-ss: ## Run pip-compile for Storage Service
docker-compose run --workdir /src/requirements --volume "tmpfs:/pip-cache:rw" -e XDG_CACHE_HOME=/pip-cache --rm --no-deps --user=root --entrypoint bash archivematica-storage-service -c "make clean && make all"
docker-compose run --workdir /src/requirements \
--volume "tmpfs:/pip-cache:rw" \
-e XDG_CACHE_HOME=/pip-cache \
--rm \
--no-deps \
--user=root \
--entrypoint bash archivematica-storage-service \
-c "make clean && make all"
@$(MAKE) --no-print-directory reset-permissions-to-user-ss

reset-permissions-to-user-am:
docker-compose run --workdir /src/MCPServer/ --rm --no-deps --user=root --entrypoint 'chown -R ${CALLER_GID}:${CALLER_GID} requirements/' archivematica-mcp-server
docker-compose run --workdir /src/MCPClient/ --rm --no-deps --user=root --entrypoint 'chown -R ${CALLER_GID}:${CALLER_GID} requirements/' archivematica-mcp-client
docker-compose run --workdir /src/dashboard/src/ --rm --no-deps --user=root --entrypoint 'chown -R ${CALLER_GID}:${CALLER_GID} requirements/' archivematica-dashboard
docker-compose run --workdir /src/archivematicaCommon/ --rm --no-deps --user=root --entrypoint 'chown -R ${CALLER_GID}:${CALLER_GID} requirements/' archivematica-dashboard
docker-compose run --workdir /src/MCPServer/ \
--rm \
--no-deps \
--user=root \
--entrypoint \
'chown -R ${CALLER_GID}:${CALLER_GID} requirements/' \
archivematica-mcp-server
docker-compose run --workdir /src/MCPClient/ \
--rm \
--no-deps \
--user=root \
--entrypoint \
'chown -R ${CALLER_GID}:${CALLER_GID} requirements/' \
archivematica-mcp-client
docker-compose run --workdir /src/dashboard/src/ \
--rm \
--no-deps \
--user=root \
--entrypoint \
'chown -R ${CALLER_GID}:${CALLER_GID} requirements/' \
archivematica-dashboard
docker-compose run --workdir /src/archivematicaCommon/ \
--rm \
--no-deps \
--user=root \
--entrypoint \
'chown -R ${CALLER_GID}:${CALLER_GID} requirements/' \
archivematica-dashboard

reset-permissions-to-user-ss:
docker-compose run --workdir /src/ --rm --no-deps --user=root --entrypoint 'chown -R ${CALLER_GID}:${CALLER_GID} requirements/' archivematica-storage-service
docker-compose run --workdir /src/ \
--rm \
--no-deps \
--user=root \
--entrypoint \
'chown -R ${CALLER_GID}:${CALLER_GID} requirements/' \
archivematica-storage-service

db: ## Connect to the MySQL server using the CLI.
docker-compose exec mysql mysql -hlocalhost -uroot -p12345
Expand Down

0 comments on commit c88f15b

Please sign in to comment.