Skip to content

Commit

Permalink
Migrate to .blueprintrc
Browse files Browse the repository at this point in the history
Earlier attempt overlooked a typo in listen.sh that was deleting the file on container start.
  • Loading branch information
Loki-101 committed Jan 30, 2025
1 parent 82b1753 commit a6277fd
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
2 changes: 2 additions & 0 deletions .helpers/.blueprintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
OWNERSHIP="nginx:nginx"
WEBUSER="nginx"
2 changes: 1 addition & 1 deletion .helpers/listen.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ set -euo pipefail
trap 'echo "Interrupted"; exit 1' INT TERM

# Initial sync
rsync -av --exclude=".blueprint" --include="*.blueprint*" --exclude="*" --delete "/blueprint_extensions/" "/app/"
rsync -av --exclude=".blueprint" --include="*.blueprint" --exclude="*" --delete "/blueprint_extensions/" "/app/"

# Continuous monitor task
inotifywait -m -q \
Expand Down
9 changes: 3 additions & 6 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -44,18 +44,15 @@ RUN wget $(curl -s https://api.github.com/repos/BlueprintFramework/framework/rel
# Required for tput (used in blueprint.sh)
ENV TERM=xterm

# Make blueprint.sh set ownership to nginx:nginx
RUN sed -i -E \
-e "s|OWNERSHIP=\"www-data:www-data\" #;|OWNERSHIP=\"nginx:nginx\" #;|g" \
-e "s|WEBUSER=\"www-data\" #;|WEBUSER=\"nginx\" #;|g" \
blueprint.sh
# Set Blueprint user and permissions
COPY .helpers/.blueprintrc /app/.blueprintrc

# Make the script executable and run it
RUN chmod +x blueprint.sh \
&& bash blueprint.sh

# Create directory for blueprint extensions
RUN mkdir -p /blueprint_extensions /app
RUN mkdir -p /blueprint_extensions

# Copy listen.sh from .helpers directory
COPY .helpers/listen.sh /listen.sh
Expand Down

0 comments on commit a6277fd

Please sign in to comment.