diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml index fbe1764..494d45d 100644 --- a/.github/workflows/php.yml +++ b/.github/workflows/php.yml @@ -3,11 +3,10 @@ name: Lion-Framework (CI Workflow) on: push: branches: - - actions + - php-actions pull_request: branches: - - main - - 4.x + - 5.x paths: - '.github/workflows/php.yml' - 'app/**' @@ -19,9 +18,11 @@ on: - '.env.actions' - 'composer.json' - 'composer.lock' - - 'phpstan.neon' - 'phpunit.xml' +env: + PHP_VERSION: 8.5 + jobs: install-dependencies: runs-on: ubuntu-latest @@ -33,7 +34,7 @@ jobs: - name: Setup PHP uses: shivammathur/setup-php@v2 with: - php-version: 8.4 + php-version: ${{ env.PHP_VERSION }} extensions: mbstring, gd, zip - name: Install PHP dependencies @@ -46,13 +47,6 @@ jobs: key: php-vendor-${{ runner.os }}-${{ github.run_id }} restore-keys: php-vendor-${{ runner.os }}-${{ github.run_id }} - - name: Cache composer.lock - uses: actions/cache@v4 - with: - path: composer.lock - key: php-composer-lock-${{ runner.os }}-${{ github.run_id }} - restore-keys: php-composer-lock-${{ runner.os }}-${{ github.run_id }} - composer-validation: runs-on: ubuntu-latest name: Composer Validation @@ -65,16 +59,9 @@ jobs: - name: Set up PHP uses: shivammathur/setup-php@v2 with: - php-version: '8.4' + php-version: ${{ env.PHP_VERSION }} extensions: mbstring, gd, zip - - name: Restore composer.lock from cache - uses: actions/cache@v4 - with: - path: composer.lock - key: php-composer-lock-${{ runner.os }}-${{ github.run_id }} - restore-keys: php-composer-lock-${{ runner.os }}-${{ github.run_id }} - - name: Restore vendor directory from cache uses: actions/cache@v4 with: @@ -103,17 +90,10 @@ jobs: - name: Check out the repository uses: actions/checkout@v4 - - name: Restore composer.lock from cache - uses: actions/cache@v4 - with: - path: composer.lock - key: php-composer-lock-${{ runner.os }}-${{ github.run_id }} - restore-keys: php-composer-lock-${{ runner.os }}-${{ github.run_id }} - - name: Dependency Review uses: actions/dependency-review-action@v4 with: - base-ref: main + base-ref: ${{ github.event.repository.default_branch }} head-ref: ${{ github.sha }} comment-summary-in-pr: true # Possible values: "critical", "high", "moderate", "low" diff --git a/Dockerfile b/Dockerfile index fc1d6bc..def25d9 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM php:8.4-apache +FROM php:8.5-apache ARG DEBIAN_FRONTEND=noninteractive # ---------------------------------------------------------------------------------------------------------------------- @@ -13,17 +13,6 @@ RUN apt-get update -y \ && apt-get clean \ && curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer \ && rm -rf /var/lib/apt/lists/* - -RUN apt-get update -y \ - && apt-get install -y wget lsb-release gnupg \ - && wget https://dev.mysql.com/get/mysql-apt-config_0.8.29-1_all.deb \ - && dpkg -i mysql-apt-config_0.8.29-1_all.deb \ - && sed -i 's/trixie/bookworm/g' /etc/apt/sources.list.d/mysql.list \ - && apt-get update -y \ - && apt-get install -y mysql-client \ - && rm -f mysql-apt-config_0.8.29-1_all.deb \ - && apt-get clean \ - && rm -rf /var/lib/apt/lists/* # Electron-Vite Dependencies ------------------------------------------------------------------------------------------- # RUN apt-get update -y \ # && apt-get install -y libnss3 mesa-utils libgl1-mesa-glx mesa-utils-extra libx11-xcb1 libxcb-dri3-0 libxtst6 \ diff --git a/composer.lock b/composer.lock index 628060f..4a169f3 100644 --- a/composer.lock +++ b/composer.lock @@ -7263,5 +7263,5 @@ "php": ">=8.4" }, "platform-dev": {}, - "plugin-api-version": "2.6.0" + "plugin-api-version": "2.9.0" } diff --git a/docker-compose.yml b/docker-compose.yml index 1c60b02..667d3db 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,6 +1,6 @@ services: - app: - container_name: framework-app + php: + container_name: framework-php build: context: . dockerfile: Dockerfile @@ -19,8 +19,6 @@ services: - ./:/var/www/html depends_on: - mysql - - phpmyadmin - # - redis networks: - lion @@ -38,78 +36,8 @@ services: networks: - lion - phpmyadmin: - image: phpmyadmin/phpmyadmin - container_name: framework-phpmyadmin - links: - - mysql:mysql - ports: - - 8080:80 - environment: - PMA_HOST: mysql - MYSQL_USER: root - MYSQL_PASSWORD: lion - MYSQL_ROOT_PASSWORD: lion - networks: - - lion - - # mailhog: - # image: mailhog/mailhog - # container_name: framework-mailhog - # restart: unless-stopped - # ports: - # - 8025:8025 - # - 1025:1025 - # networks: - # - lion - - # redis: - # image: redis - # container_name: framework-redis - # restart: always - # ports: - # - 6379:6379 - # volumes: - # - redis_data:/data - # environment: - # REDIS_HOST: redis - # REDIS_PASSWORD: lion - # REDIS_DATABASES: 1 - # networks: - # - lion - - # postgres: - # image: postgres - # container_name: framework-postgres - # ports: - # - 5432:5432 - # environment: - # POSTGRES_DB: lion_database - # POSTGRES_USER: root - # POSTGRES_PASSWORD: lion - # volumes: - # - postgres_data:/var/lib/postgresql/data - # networks: - # - lion - - # pgadmin: - # image: dpage/pgadmin4 - # container_name: framework-pgadmin4 - # ports: - # - 5050:80 - # environment: - # PGADMIN_DEFAULT_EMAIL: root@dev.com - # PGADMIN_DEFAULT_PASSWORD: lion - # depends_on: - # - postgres - # networks: - # - lion - volumes: mysql_data: - postgres_data: - redis_data: - driver: local networks: lion: