Compare commits
11 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a6d5e2b026 | ||
|
|
688ea98922 | ||
|
|
d55a9cfdd5 | ||
|
|
e9021c22fa | ||
|
|
939660a715 | ||
|
|
fb3e7b20ff | ||
|
|
699dbaabc3 | ||
|
|
484ac40d99 | ||
|
|
b8a22e63c9 | ||
|
|
e489f73f7c | ||
|
|
554b7774f6 |
2
.env
2
.env
@@ -31,6 +31,8 @@ DATABASE_URL=
|
|||||||
|
|
||||||
###< doctrine/doctrine-bundle ###
|
###< doctrine/doctrine-bundle ###
|
||||||
MERCURE_JWT_SECRET="!ChangeThisMercureHubJWTSecretKey!"
|
MERCURE_JWT_SECRET="!ChangeThisMercureHubJWTSecretKey!"
|
||||||
|
MERCURE_PUBLISHER_JWT_KEY="!ChangeThisMercureHubJWTSecretKey!"
|
||||||
|
MERCURE_SUBSCRIBER_JWT_KEY="!ChangeThisMercureHubJWTSecretKey!"
|
||||||
###> symfony/messenger ###
|
###> symfony/messenger ###
|
||||||
# Choose one of the transports below
|
# Choose one of the transports below
|
||||||
# MESSENGER_TRANSPORT_DSN=amqp://guest:guest@localhost:5672/%2f/messages
|
# MESSENGER_TRANSPORT_DSN=amqp://guest:guest@localhost:5672/%2f/messages
|
||||||
|
|||||||
74
.gitea/workflows/build_base_images.yml
Normal file
74
.gitea/workflows/build_base_images.yml
Normal file
@@ -0,0 +1,74 @@
|
|||||||
|
name: CI
|
||||||
|
|
||||||
|
on: [push]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-base-app:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout repo
|
||||||
|
uses: actions/checkout@v5
|
||||||
|
|
||||||
|
- name: Login to registry
|
||||||
|
uses: docker/login-action@v2
|
||||||
|
with:
|
||||||
|
registry: "${{ vars.REGISTRY_URL }}"
|
||||||
|
username: "${{ vars.REGISTRY_USER }}"
|
||||||
|
password: "${{ vars.REGISTRY_PASS }}"
|
||||||
|
|
||||||
|
- name: Create torsearch-app docker image
|
||||||
|
run: |
|
||||||
|
export APP_FRANKENPHP_TAG=php8.4
|
||||||
|
docker buildx build --platform=linux/amd64 -f docker/Dockerfile.base.app -t code.caldwell.digital/home/torsearch-base:${APP_FRANKENPHP_TAG} -t code.caldwell.digital/home/torsearch-base:latest --build-arg "FRANKENPHP_TAG=${APP_FRANKENPHP_TAG}" .
|
||||||
|
docker push --platform=linux/amd64 code.caldwell.digital/home/torsearch-base:${APP_FRANKENPHP_TAG}
|
||||||
|
docker push --platform=linux/amd64 code.caldwell.digital/home/torsearch-base:latest
|
||||||
|
|
||||||
|
build-base-worker:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout repo
|
||||||
|
uses: actions/checkout@v5
|
||||||
|
|
||||||
|
- name: Login to registry
|
||||||
|
uses: docker/login-action@v2
|
||||||
|
with:
|
||||||
|
registry: "${{ vars.REGISTRY_URL }}"
|
||||||
|
username: "${{ vars.REGISTRY_USER }}"
|
||||||
|
password: "${{ vars.REGISTRY_PASS }}"
|
||||||
|
|
||||||
|
- name: Create torsearch-worker docker image
|
||||||
|
run: |
|
||||||
|
export WORKER_FRANKENPHP_TAG=php8.4-alpine
|
||||||
|
docker buildx build --platform=linux/amd64 -f docker/Dockerfile.base.worker -t code.caldwell.digital/home/torsearch-base-worker:${WORKER_FRANKENPHP_TAG} -t code.caldwell.digital/home/torsearch-base-worker:latest --build-arg "FRANKENPHP_TAG=${WORKER_FRANKENPHP_TAG}" .
|
||||||
|
docker push --platform=linux/amd64 code.caldwell.digital/home/torsearch-base-worker:${WORKER_FRANKENPHP_TAG}
|
||||||
|
docker push --platform=linux/amd64 code.caldwell.digital/home/torsearch-base-worker:latest
|
||||||
|
|
||||||
|
build-base-worker-supervisord:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout repo
|
||||||
|
uses: actions/checkout@v5
|
||||||
|
|
||||||
|
- name: Login to registry
|
||||||
|
uses: docker/login-action@v2
|
||||||
|
with:
|
||||||
|
registry: "${{ vars.REGISTRY_URL }}"
|
||||||
|
username: "${{ vars.REGISTRY_USER }}"
|
||||||
|
password: "${{ vars.REGISTRY_PASS }}"
|
||||||
|
|
||||||
|
- name: Build and push
|
||||||
|
uses: docker/build-push-action@v5
|
||||||
|
with:
|
||||||
|
context: .
|
||||||
|
build-args:
|
||||||
|
ALPINE_VERSION: 3.22
|
||||||
|
push: true
|
||||||
|
file: docker/Dockerfile.base.worker
|
||||||
|
platforms: linux/amd64
|
||||||
|
tags: |
|
||||||
|
code.caldwell.digital/home/torsearch-base-worker-supervisord:latest
|
||||||
|
|
||||||
|
# - name: Create torsearch-scheduler docker image
|
||||||
|
# run: |
|
||||||
|
# docker buildx build --platform=linux/amd64 -f docker/Dockerfile.base.worker -t code.caldwell.digital/home/torsearch-base-worker-supervisord:latest --build-arg "ALPINE_VERSION=${ALPINE_VERSION}" .
|
||||||
@@ -22,7 +22,7 @@ jobs:
|
|||||||
run: composer global require phing/phing
|
run: composer global require phing/phing
|
||||||
|
|
||||||
- name: Run composer
|
- name: Run composer
|
||||||
run: composer install --no-dev --no-scripts -o
|
run: composer install --no-dev --no-scripts --ignore-platform-reqs -o
|
||||||
|
|
||||||
- name: Build tailwind
|
- name: Build tailwind
|
||||||
run: APP_ENV=build php bin/console tailwind:build
|
run: APP_ENV=build php bin/console tailwind:build
|
||||||
@@ -45,7 +45,7 @@ jobs:
|
|||||||
tag="${{ gitea.REF_NAME }}"
|
tag="${{ gitea.REF_NAME }}"
|
||||||
tmdb_api="${{ vars.TMDB_API }}"
|
tmdb_api="${{ vars.TMDB_API }}"
|
||||||
version=${tag:1}
|
version=${tag:1}
|
||||||
docker build -f docker/Dockerfile.app \
|
docker build --pull -f docker/Dockerfile.app \
|
||||||
-t code.caldwell.digital/home/torsearch-app:${version} \
|
-t code.caldwell.digital/home/torsearch-app:${version} \
|
||||||
-t code.caldwell.digital/home/torsearch-app:latest \
|
-t code.caldwell.digital/home/torsearch-app:latest \
|
||||||
--build-arg "APP_VERSION=${version}" \
|
--build-arg "APP_VERSION=${version}" \
|
||||||
@@ -59,7 +59,7 @@ jobs:
|
|||||||
tag="${{ gitea.REF_NAME }}"
|
tag="${{ gitea.REF_NAME }}"
|
||||||
tmdb_api="${{ vars.TMDB_API }}"
|
tmdb_api="${{ vars.TMDB_API }}"
|
||||||
version=${tag:1}
|
version=${tag:1}
|
||||||
docker build -f docker/Dockerfile.worker \
|
docker build --pull -f docker/Dockerfile.worker \
|
||||||
-t code.caldwell.digital/home/torsearch-worker:${version} \
|
-t code.caldwell.digital/home/torsearch-worker:${version} \
|
||||||
-t code.caldwell.digital/home/torsearch-worker:latest \
|
-t code.caldwell.digital/home/torsearch-worker:latest \
|
||||||
--build-arg "APP_VERSION=${version}" \
|
--build-arg "APP_VERSION=${version}" \
|
||||||
@@ -73,7 +73,7 @@ jobs:
|
|||||||
tag="${{ gitea.REF_NAME }}"
|
tag="${{ gitea.REF_NAME }}"
|
||||||
tmdb_api="${{ vars.TMDB_API }}"
|
tmdb_api="${{ vars.TMDB_API }}"
|
||||||
version=${tag:1}
|
version=${tag:1}
|
||||||
docker build -f docker/Dockerfile.scheduler \
|
docker build --pull -f docker/Dockerfile.scheduler \
|
||||||
-t code.caldwell.digital/home/torsearch-scheduler:${version} \
|
-t code.caldwell.digital/home/torsearch-scheduler:${version} \
|
||||||
-t code.caldwell.digital/home/torsearch-scheduler:latest \
|
-t code.caldwell.digital/home/torsearch-scheduler:latest \
|
||||||
--build-arg "APP_VERSION=${version}" \
|
--build-arg "APP_VERSION=${version}" \
|
||||||
|
|||||||
@@ -1,22 +1,19 @@
|
|||||||
# torsearch-app is built from this base
|
# torsearch-app is built from this base
|
||||||
export APP_FRANKENPHP_TAG=php8.4
|
export APP_FRANKENPHP_TAG=php8.4
|
||||||
|
|
||||||
#docker buildx build --platform=linux/amd64,linux/arm64 -f docker/Dockerfile.base.app -t code.caldwell.digital/home/torsearch-base:${APP_FRANKENPHP_TAG} -t code.caldwell.digital/home/torsearch-base:latest --build-arg "FRANKENPHP_TAG=${APP_FRANKENPHP_TAG}" .
|
docker buildx build --platform=linux/amd64 -f docker/Dockerfile.base.app -t code.caldwell.digital/home/torsearch-base:${APP_FRANKENPHP_TAG} -t code.caldwell.digital/home/torsearch-base:latest --build-arg "FRANKENPHP_TAG=${APP_FRANKENPHP_TAG}" .
|
||||||
docker build -f docker/Dockerfile.base.app -t code.caldwell.digital/home/torsearch-base:${APP_FRANKENPHP_TAG} -t code.caldwell.digital/home/torsearch-base:latest --build-arg "FRANKENPHP_TAG=${APP_FRANKENPHP_TAG}" .
|
docker push --platform=linux/amd64 code.caldwell.digital/home/torsearch-base:${APP_FRANKENPHP_TAG}
|
||||||
docker push code.caldwell.digital/home/torsearch-base:${APP_FRANKENPHP_TAG}
|
docker push --platform=linux/amd64 code.caldwell.digital/home/torsearch-base:latest
|
||||||
docker push code.caldwell.digital/home/torsearch-base:latest
|
|
||||||
|
|
||||||
# torsearch-worker & torsearch-scheduler are built from this base
|
# torsearch-worker & torsearch-scheduler are built from this base
|
||||||
export WORKER_FRANKENPHP_TAG=php8.4-alpine
|
export WORKER_FRANKENPHP_TAG=php8.4-alpine
|
||||||
|
|
||||||
#docker buildx build --platform=linux/amd64,linux/arm64 -f docker/Dockerfile.base.worker -t code.caldwell.digital/home/torsearch-base-worker:${WORKER_FRANKENPHP_TAG} -t code.caldwell.digital/home/torsearch-base-worker:latest --build-arg "FRANKENPHP_TAG=${WORKER_FRANKENPHP_TAG}" .
|
docker buildx build --platform=linux/amd64 -f docker/Dockerfile.base.worker -t code.caldwell.digital/home/torsearch-base-worker:${WORKER_FRANKENPHP_TAG} -t code.caldwell.digital/home/torsearch-base-worker:latest --build-arg "FRANKENPHP_TAG=${WORKER_FRANKENPHP_TAG}" .
|
||||||
docker build -f docker/Dockerfile.base.worker -t code.caldwell.digital/home/torsearch-base-worker:${WORKER_FRANKENPHP_TAG} -t code.caldwell.digital/home/torsearch-base-worker:latest --build-arg "FRANKENPHP_TAG=${WORKER_FRANKENPHP_TAG}" .
|
docker push --platform=linux/amd64 code.caldwell.digital/home/torsearch-base-worker:${WORKER_FRANKENPHP_TAG}
|
||||||
docker push code.caldwell.digital/home/torsearch-base-worker:${WORKER_FRANKENPHP_TAG}
|
docker push --platform=linux/amd64 code.caldwell.digital/home/torsearch-base-worker:latest
|
||||||
docker push code.caldwell.digital/home/torsearch-base-worker:latest
|
|
||||||
|
|
||||||
# torsearch-worker-supervisord
|
# torsearch-worker-supervisord
|
||||||
export ALPINE_VERSION=3.22
|
export ALPINE_VERSION=3.22
|
||||||
|
|
||||||
#docker buildx build --platform=linux/amd64,linux/arm64 -f docker/Dockerfile.base.worker -t code.caldwell.digital/home/torsearch-base-worker-supervisord:latest --build-arg "ALPINE_VERSION=${ALPINE_VERSION}" .
|
docker buildx build --platform=linux/amd64 -f docker/Dockerfile.base.worker -t code.caldwell.digital/home/torsearch-base-worker-supervisord:latest --build-arg "ALPINE_VERSION=${ALPINE_VERSION}" .
|
||||||
docker build -f docker/Dockerfile.base.worker -t code.caldwell.digital/home/torsearch-base-worker-supervisord:latest --build-arg "ALPINE_VERSION=${ALPINE_VERSION}" .
|
docker push --platform=linux/amd64 code.caldwell.digital/home/torsearch-base-worker-supervisord:latest
|
||||||
docker push code.caldwell.digital/home/torsearch-base-worker-supervisord:latest
|
|
||||||
|
|||||||
@@ -27,8 +27,8 @@ services:
|
|||||||
tty: true
|
tty: true
|
||||||
environment:
|
environment:
|
||||||
TZ: America/Chicago
|
TZ: America/Chicago
|
||||||
MERCURE_PUBLISHER_JWT_KEY: '!ChangeThisMercureHubJWTSecretKey!'
|
MERCURE_PUBLISHER_JWT_KEY: "${MERCURE_PUBLISHER_JWT_KEY}"
|
||||||
MERCURE_SUBSCRIBER_JWT_KEY: '!ChangeThisMercureHubJWTSecretKey!'
|
MERCURE_SUBSCRIBER_JWT_KEY: "${MERCURE_SUBSCRIBER_JWT_KEY}"
|
||||||
depends_on:
|
depends_on:
|
||||||
database:
|
database:
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
|
|||||||
@@ -16,11 +16,13 @@ RUN apk add --no-cache \
|
|||||||
php84-fileinfo \
|
php84-fileinfo \
|
||||||
php84-fpm \
|
php84-fpm \
|
||||||
php84-gd \
|
php84-gd \
|
||||||
|
php84-intl \
|
||||||
php84-mbstring \
|
php84-mbstring \
|
||||||
php84-mysqli \
|
php84-mysqli \
|
||||||
php84-opcache \
|
php84-opcache \
|
||||||
php84-openssl \
|
php84-openssl \
|
||||||
php84-pdo_mysql \
|
php84-pdo_mysql \
|
||||||
|
php84-session \
|
||||||
php84-tokenizer \
|
php84-tokenizer \
|
||||||
php84-xml \
|
php84-xml \
|
||||||
supervisor
|
supervisor
|
||||||
|
|||||||
@@ -15,6 +15,7 @@ FROM code.caldwell.digital/home/torsearch-app:${APP_VERSION} AS app_image
|
|||||||
FROM code.caldwell.digital/home/torsearch-base-worker-supervisord:latest
|
FROM code.caldwell.digital/home/torsearch-base-worker-supervisord:latest
|
||||||
|
|
||||||
# Set the APP_VERSION in the image
|
# Set the APP_VERSION in the image
|
||||||
|
ARG APP_VERSION="latest"
|
||||||
ENV APP_VERSION=${APP_VERSION}
|
ENV APP_VERSION=${APP_VERSION}
|
||||||
|
|
||||||
ARG TMDB_API=""
|
ARG TMDB_API=""
|
||||||
|
|||||||
@@ -15,6 +15,7 @@ FROM code.caldwell.digital/home/torsearch-app:${APP_VERSION} AS app_image
|
|||||||
FROM code.caldwell.digital/home/torsearch-base-worker-supervisord:latest
|
FROM code.caldwell.digital/home/torsearch-base-worker-supervisord:latest
|
||||||
|
|
||||||
# Set the APP_VERSION in the image
|
# Set the APP_VERSION in the image
|
||||||
|
ARG APP_VERSION="latest"
|
||||||
ENV APP_VERSION=${APP_VERSION}
|
ENV APP_VERSION=${APP_VERSION}
|
||||||
|
|
||||||
ARG TMDB_API=""
|
ARG TMDB_API=""
|
||||||
|
|||||||
Reference in New Issue
Block a user