Skip to content
This repository has been archived by the owner on Apr 2, 2024. It is now read-only.

Commit

Permalink
Refactor ccache file storage paths for better organization (#95)
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexGodbehere authored Jan 26, 2024
1 parent a41aa17 commit 1d90e50
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions .docker/Dockerfiles/Dockerfile.backend-build
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,5 @@ RUN mkdir -p /app/storage/logs
RUN mkdir -p /app/storage/app/purify
RUN mkdir -p /app/storage/app/purify/HTML
RUN mkdir -p /app/storage/app/purify/JSON
RUN mkdir -p /app/storage/ccache
RUN chmod -R 775 /app/storage
2 changes: 1 addition & 1 deletion app/Domain/Auth/Actions/AuthenticateUserAction.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ public function execute(string $username, string $password)
// At this point we have a valid ccache for the user. Store
// the cache to disk using the user's full principal as the
// filename, replacing the @ with a - to avoid issues with
$ccache->save("FILE:/app/storage/" . $user->username . '.ccache');
$ccache->save("FILE:/app/storage/ccache/" . $user->username . '.ccache');

// Log the user in
return action_success($user);
Expand Down
2 changes: 1 addition & 1 deletion app/Support/Providers/AppServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public function register()
try {
// If the user is logged in then get their ccache
// and use that for all future requests
$ccache->open("FILE:/app/storage/" . auth()->user()->username . '.ccache');
$ccache->open("FILE:/app/storage/ccache/" . auth()->user()->username . '.ccache');

$ccache->isValid();
} catch (\Exception $e) {
Expand Down

0 comments on commit 1d90e50

Please sign in to comment.