Skip to content

Commit

Permalink
Merge pull request #7 from canonical/create-working-dir-explicitly
Browse files Browse the repository at this point in the history
[DPE-4808] create directory /var/lib/redis and take ownership
  • Loading branch information
reneradoi committed Jul 2, 2024
2 parents 96f1028 + b2c858b commit 15dfd84
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,15 @@ parts:
redis-user:
plugin: nil
overlay-script: |
set -x
useradd -R $CRAFT_OVERLAY -M -U -r redis
groupadd -R $CRAFT_OVERLAY -g 584788 redis
useradd -R $CRAFT_OVERLAY -M -r -g redis -u 584788 redis
override-prime: |
craftctl default
# Give permission and create the required directories
mkdir -p $CRAFT_PRIME/var/lib/redis
chmod 0755 $CRAFT_PRIME/var/lib/redis
chown -R 584788:584788 $CRAFT_PRIME/var/lib/redis
redis:
plugin: nil
after:
Expand Down

0 comments on commit 15dfd84

Please sign in to comment.