20 Commits
v2.0.3 ... dev

Author SHA1 Message Date
Ruben Momoa
8ec450138a no multi arch build for test image
[SKIP CI]
2024-08-30 15:50:29 +02:00
Ruben Momoa
fba60fa0e2 multi arch builds 2024-08-30 15:50:10 +02:00
Ruben Momoa
d9d95a285e build platforms
All checks were successful
ci/woodpecker/push/build_dev Pipeline was successful
2024-08-30 15:31:00 +02:00
Ruben Momoa
6e956702bc run option to run artisan migrate before staring
All checks were successful
ci/woodpecker/push/build_dev Pipeline was successful
2024-08-30 14:14:45 +02:00
Ruben Momoa
e4e5dc6524 check of a laravel project before doing other things 2024-08-30 14:12:46 +02:00
Ruben Momoa
be2d681161 Merge remote-tracking branch 'origin/dev' into dev
All checks were successful
ci/woodpecker/push/build_dev Pipeline was successful
2024-08-30 14:04:03 +02:00
Ruben Momoa
da37cc3c4a add port to health check 2024-08-30 14:03:56 +02:00
Ruben Momoa
426eb92f1a add port to health check
[SKIP CI]
2024-08-30 14:03:23 +02:00
Ruben Momoa
54cf43aad8 add comment
[SKIP CI]
2024-08-30 13:56:28 +02:00
Ruben Momoa
5d9b68323b add a healthcheck to the image and an HEALTHCHECK_PATH env var
All checks were successful
ci/woodpecker/push/build_dev Pipeline was successful
2024-08-30 13:52:14 +02:00
Ruben Momoa
a6400ebb95 add latest tag for php-8 builds
[SKIP CI]
2024-08-29 10:19:39 +02:00
Ruben Momoa
3483285a2e remove debug commands 2024-08-29 09:57:14 +02:00
Ruben Momoa
6ffb2b6ed9 fix for none root users move npm cache to /tmp
All checks were successful
ci/woodpecker/push/build_dev Pipeline was successful
2024-08-28 13:46:01 +02:00
Ruben Momoa
2e4ae4d861 remove old build test
All checks were successful
ci/woodpecker/push/build_dev Pipeline was successful
2024-08-28 13:17:20 +02:00
Ruben Momoa
a45c6d4b1d feat: add simplexml and xmlreader
Some checks failed
ci/woodpecker/push/build_dev Pipeline failed
2024-08-28 13:04:17 +02:00
Ruben Momoa
d6d66a85d5 feat: only run first boot as root 2024-08-28 12:58:03 +02:00
Ruben Momoa
0de77a89c9 Merge branch 'master' into dev 2024-08-26 15:30:39 +02:00
557fc719e8 Update .woodpecker/build_dev.yml
Some checks failed
ci/woodpecker/push/build_dev Pipeline failed
2024-08-26 15:07:24 +02:00
6f030ef1f9 Update .woodpecker/build_dev.yml
Some checks failed
ci/woodpecker/push/build_dev Pipeline failed
2024-08-26 15:06:55 +02:00
17d09da770 Update .woodpecker/build_release.yml 2024-08-26 15:06:19 +02:00
5 changed files with 32 additions and 18 deletions

View File

@@ -10,14 +10,6 @@ when:
event: [ push, manual ]
steps:
gen_tags:
image: docker
commands:
- pwd
- ./gen-version-list.sh "v2.0.4" php-${PHP_VERSION}
- cat tags.txt
dev_alpine_build_and_publish:
image: woodpeckerci/plugin-docker-buildx
settings:

View File

@@ -1,9 +1,9 @@
matrix:
PHP_VERSION:
- 8
- 8.3
- 8.2
- 8.1
- 8.2
- 8.3
- 8
when:
branch:
@@ -44,6 +44,7 @@ steps:
release_alpine_build_and_publish:
image: woodpeckerci/plugin-docker-buildx
settings:
platforms: linux/386,linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64/v8,linux/ppc64le,linux/riscv64,linux/s390x
username: vistanarvas
password:
from_secret: DOCKERHUB_TOKEN

View File

@@ -5,6 +5,9 @@ FROM php:${BASE_VERSION}-fpm-alpine
# port to for the webserver
ENV WEBSERVER_PORT=8080
# path without leading / (slash)
ENV HEALTHCHECK_PATH=""
COPY start-container.sh /usr/local/bin/start-container
RUN apk add --no-cache \
@@ -25,11 +28,16 @@ RUN apk add --no-cache \
php-exif \
php-xmlwriter \
php-tokenizer \
php-simplexml \
php-xmlreader \
composer \
npm \
&& docker-php-ext-install filter pdo_mysql \
&& chmod +x /usr/local/bin/start-container
HEALTHCHECK --interval=5m --timeout=3s --start-period=5m --start-interval=10s \
CMD curl -f http://localhost:${WEBSERVER_PORT}/${HEALTHCHECK_PATH} || exit 1
EXPOSE ${WEBSERVER_PORT}
WORKDIR /var/www/html

View File

@@ -3,8 +3,13 @@
# exit when any command fails
set -e
if [ ! -f /var/www/html/artisan ]; then
echo "No existing Laravel project found"
exit
fi
# install extra packages and extensions on first boot
if [[ ! -f /etc/first_boot ]]; then
if [[ $(id -u) -eq 0 && ! -f /etc/first_boot ]]; then
if [[ -n "${EXTRA_APK_PACKAGES// /}" ]]; then
# shellcheck disable=SC2086
apk add --no-cache $EXTRA_APK_PACKAGES
@@ -23,12 +28,12 @@ fi
if [[ "$BOOT_NPM_INSTALL" = true ]]; then
echo "npm install"
npm install
npm install --cache /tmp/npm
fi
if [ ! -f /var/www/html/artisan ]; then
echo "No existing Laravel project found"
exit
if [[ "$BOOT_MIGRATE" = true ]]; then
echo "artisan migrate"
php /var/www/html/artisan migrate
fi
if [[ "$BOOT_NPM_DEV" = true ]]; then

View File

@@ -12,14 +12,22 @@ fi
version=$1
# Suffix
[[ -n $2 ]] && suffix="-$2" || suffix=""
suffix=""
if [[ -n $2 ]]; then
suffix="-$2"
fi
touch tags.txt
if [[ "$2" = "php-8" ]]; then
echo "latest" >> tags.txt
fi
# Check if the first character is "V" or "v" and remove it
if [[ "${version:0:1}" == "V" || "${version:0:1}" == "v" ]]; then
version="${version#?}"
fi
echo "latest$suffix" > tags.txt
echo "latest$suffix" >> tags.txt
echo "$version" | cut -d'.' -f1 | xargs -I {} echo "{}$suffix" >> tags.txt
echo "$version" | cut -d'.' -f1,2 | xargs -I {} echo "{}$suffix" >> tags.txt
echo "$version" | cut -d'.' -f1,2,3 | xargs -I {} echo "{}$suffix" >> tags.txt