Skip to content

Commit

Permalink
fix: local docker build
Browse files Browse the repository at this point in the history
  • Loading branch information
notdryft committed Jan 23, 2025
1 parent b0d75f1 commit 83b2dc1
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 19 deletions.
16 changes: 0 additions & 16 deletions bin/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -51,28 +51,12 @@ clean() {
./resources
}

install_dependencies() {
# envsubst
apk add gettext

# yq
wget https://github.com/mikefarah/yq/releases/download/v4.40.7/yq_linux_amd64.tar.gz -O - |\
tar xz && mv yq_linux_amd64 /usr/bin/yq

# global node modules
npm install -g postcss postcss-cli @fullhuman/postcss-purgecss purgecss-whitelister flexsearch lodash
}

prepare () {
if [[ "$PREPARE" = true ]]; then
clean

echo "=====> prepare phase"

if [[ "$DOCKER" = true ]]; then
install_dependencies
fi

hugo mod get -u
hugo mod npm pack

Expand Down
4 changes: 1 addition & 3 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,9 @@ services:
image: floryn90/hugo:0.135.0-ext-alpine
ports:
- 1313:1313
user: root:root
volumes:
- .:/src
- /src/content
- /src/resources
- /src/node_modules
working_dir: /src
environment:
- DOCKER=true
Expand Down

0 comments on commit 83b2dc1

Please sign in to comment.