Skip to content

Commit

Permalink
Merge pull request OpenConext#13 from OpenConext/feature/php82_upgrad…
Browse files Browse the repository at this point in the history
…e_node14_to_node20

PHP82: Create a node20 image. Node14 is not used at all. Removing  it
  • Loading branch information
MKodde authored Oct 30, 2023
2 parents e55a4e2 + 9bcdfd0 commit 6f9cf8c
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 9 deletions.
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
name: Build the PHP 8.2 Apache2 Node14 Composer2 container
name: Build the PHP 8.2 Apache2 Node20 Composer2 container

on:
push:
branches:
- main
paths:
- php82-apache2-node14-composer2/**
- php82-apache2-node20-composer2/**
schedule:
- cron: '0 7 * * *'

Expand Down Expand Up @@ -42,12 +42,12 @@ jobs:
- name: Build and push
uses: docker/build-push-action@v4
with:
context: ./php82-apache2-node14-composer2
context: ./php82-apache2-node20-composer2
platforms: linux/amd64,linux/arm64
push: true
tags: |
ghcr.io/openconext/openconext-basecontainers/php82-apache2-node14-composer2:latest
ghcr.io/openconext/openconext-basecontainers/php82-apache2-node14-composer2:${{ github.sha }}
ghcr.io/openconext/openconext-basecontainers/php82-apache2-node20-composer2:latest
ghcr.io/openconext/openconext-basecontainers/php82-apache2-node20-composer2:${{ github.sha }}
cache-from: type=local,src=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache-new,mode=max

Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
FROM ghcr.io/openconext/openconext-basecontainers/php82-apache2:latest
COPY --from=composer:2 /usr/bin/composer /usr/bin/composer
SHELL ["/bin/bash", "--login", "-c"]
COPY --from=node:20-slim /usr/local/bin /usr/local/bin
COPY --from=node:20-slim /opt /opt
COPY --from=node:20-slim /usr/local/lib/node_modules /usr/local/lib/node_modules
RUN apt update && apt -y install git unzip
RUN curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.3/install.sh | bash
RUN nvm install 14
RUN npm install -g yarn
RUN pecl install xdebug && docker-php-ext-enable xdebug
COPY ./conf/xdebug.ini /usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini
RUN apt autoremove -y && apt clean && apt autoclean && rm -rf /var/lib/apt/lists/*

0 comments on commit 6f9cf8c

Please sign in to comment.