Skip to content

Commit

Permalink
Rename to bin/dev-shell to avoid confusion
Browse files Browse the repository at this point in the history
  • Loading branch information
xZero707 committed May 20, 2024
1 parent 650bdcb commit a24c5bd
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 16 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.idea/
wordpress.iml
data/
build/patch-util/wp-src/
build/tests-util/composer.lock
build/tests-util/vendor/
19 changes: 19 additions & 0 deletions Dockerfile.dev
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
ARG WP_VERSION=6.5.3
FROM scratch AS rootfs

# Install composer
COPY --from=composer:2.7 ["/usr/bin/composer", "/usr/local/bin/composer"]



ARG WP_VERSION
FROM ghcr.io/n0rthernl1ghts/wordpress:${WP_VERSION}

RUN set -eux \
&& apk add --update --no-cache exa file fish git less nano openssh-client rsync tree unzip wget

COPY --from=rootfs ["/", "/"]


WORKDIR "/workspace"
ENTRYPOINT ["/usr/bin/fish"]
24 changes: 24 additions & 0 deletions bin/dev-shell
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#!/usr/bin/env bash



# This is development util
main() {
local wpVersion="${1:-6.5.3}"

set -ex

docker build \
--file=Dockerfile.dev \
--build-arg="WP_VERSION=${wpVersion}" \
-t "localhost/nlss-wp-dev:${wpVersion}" .

docker run \
--init \
--rm \
-it \
-v "${PWD}/src/:/workspace" \
"localhost/nlss-wp-dev:${wpVersion}"
}

main "${@}"
16 changes: 0 additions & 16 deletions bin/shell

This file was deleted.

0 comments on commit a24c5bd

Please sign in to comment.