Skip to content

Commit

Permalink
Merge pull request #719 from Pixilib/GaelO2-dev
Browse files Browse the repository at this point in the history
Version 2.5.0
  • Loading branch information
salimkanoun committed Feb 17, 2024
2 parents b22159b + 926ee85 commit e7dc0d6
Show file tree
Hide file tree
Showing 77 changed files with 2,113 additions and 1,295 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/clean-packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: 'Build checkout'
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Login to github registery
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
registry: ghcr.io
username: 'salimkanoun'
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/php-stan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: 'Build checkout'
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: 'Setup PHP'
uses: shivammathur/setup-php@v2
with:
php-version: '8.2'
php-version: '8.3'

- name: 'Copy .env'
working-directory: ./GaelO2
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: 'Build checkout'
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Docker meta
id: meta
uses: docker/metadata-action@v4
uses: docker/metadata-action@v5
with:
images: ghcr.io/pixilib/gaelo
tags: |
Expand All @@ -27,17 +27,17 @@ jobs:
v2-latest
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3

- name: Login to github registery
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
registry: ghcr.io
username: 'salimkanoun'
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push
uses: docker/build-push-action@v3
uses: docker/build-push-action@v5
with:
context: .
push: true
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: 'Build checkout'
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: 'Setup PHP'
uses: shivammathur/setup-php@v2
with:
php-version: '8.2'
php-version: '8.3'

- name: 'Copy .env'
working-directory: ./GaelO2
Expand Down
38 changes: 19 additions & 19 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
FROM php:8.2.13-apache-bullseye
FROM php:8.3.2-fpm-bullseye

ENV PHP_OPCACHE_VALIDATE_TIMESTAMPS="0"
ENV TZ="UTC"

RUN apt-get update -qy && \
apt-get install -y --no-install-recommends apt-utils\
nginx \
git \
cron \
nano \
Expand All @@ -16,6 +17,7 @@ RUN apt-get update -qy && \
libbz2-dev \
libmcrypt-dev \
libxml2-dev \
libcurl4-gnutls-dev \
openssl \
sqlite3 \
supervisor \
Expand All @@ -27,46 +29,44 @@ RUN apt-get update -qy && \
apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*

RUN pecl install pcov redis memcached
RUN docker-php-ext-install gd zip pdo pdo_mysql pdo_pgsql mbstring bcmath ctype fileinfo xml bz2 pcntl
RUN docker-php-ext-install gd zip pdo pdo_mysql pdo_pgsql mbstring bcmath ctype fileinfo xml bz2 pcntl curl ftp
RUN docker-php-ext-configure opcache --enable-opcache \
&& docker-php-ext-install opcache

RUN docker-php-ext-enable redis memcached pcov

COPY php.ini "$PHP_INI_DIR/php.ini"

RUN curl -s https://getcomposer.org/installer | php -- --install-dir=/usr/bin/ --filename=composer

COPY vhost.conf /etc/apache2/sites-available/000-default.conf
COPY apache.conf /etc/apache2/conf-available/zgaelo.conf

RUN a2enmod rewrite
RUN a2enmod headers
RUN a2enmod remoteip
RUN a2enmod deflate
RUN a2enmod http2

RUN a2enconf zgaelo
# Copy configuration files.
COPY php.ini /usr/local/etc/php/php.ini
COPY php-fpm.conf /usr/local/etc/php-fpm.d/www.conf
COPY nginx.conf /etc/nginx/nginx.conf

ENV APP_HOME /var/www/html
ENV APP_HOME /var/www
ENV COMPOSER_ALLOW_SUPERUSER=1

WORKDIR $APP_HOME

COPY docker_start.sh /usr/local/bin/start
COPY --chown=www-data:www-data GaelO2 .
COPY GaelO2 .
COPY laravel-worker.conf /etc/supervisor/conf.d

RUN mv .env.example .env

RUN composer install --optimize-autoloader --no-interaction

# docker_start.sh
COPY docker_start.sh /usr/local/bin/start
RUN chmod u+x /usr/local/bin/start

EXPOSE 80
# Adjust user permission & group
RUN usermod --uid 1000 www-data
RUN groupmod --gid 1001 www-data

# Set correct permission.
RUN chown -R www-data:www-data $APP_HOME
RUN chmod -R 755 /var/www/storage
RUN chmod -R 755 /var/www/bootstrap

RUN service apache2 restart
EXPOSE 80

ENTRYPOINT ["/usr/local/bin/start"]
2 changes: 2 additions & 0 deletions GaelO2/.env.example
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ FILESYSTEM_DISK='local'
AZURE_BLOB_DSN=''
AZURE_CONTAINER_NAME=''
AZURE_BLOB_PREFIX=''
AZURE_FILE_CACHE_CONTAINER_NAME=''
FILE_CACHE_DRIVER='file'

BROADCAST_DRIVER=log
CACHE_DRIVER=file
Expand Down
73 changes: 73 additions & 0 deletions GaelO2/.env.testing
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
APP_NAME=GaelO
APP_CORPORATION=Pixilib
APP_ENV="testing"
APP_KEY=base64:Eqa/LcdPhfxg6PQ9uytXcu5WoMN8p5Ms2rlBywsOq08=
APP_DEBUG=false
TZ=UTC
DB_CONNECTION="sqlite_testing"
APP_URL='http://localhost:80'
LOG_CHANNEL=stderr

TUS_URL='http://localhost:1080'

ORTHANC_TEMPORARY_URL='http://localhost:8042'
ORTHANC_TEMPORARY_LOGIN='login'
ORTHANC_TEMPORARY_PASSWORD='password'

ORTHANC_STORAGE_URL='http://localhost:8043'
ORTHANC_STORAGE_LOGIN='login'
ORTHANC_STORAGE_PASSWORD='password'

GAELO_PROCESSING_URL='http://gaeloprocessing:8000'
GAELO_PROCESSING_LOGIN='login'
GAELO_PROCESSING_PASSWORD='password'

AZURE_CLIENT_ID=''
AZURE_DIRECTORY_ID=''
AZURE_CLIENT_SECRET=''
AZURE_SUBSCRIPTION_ID=''
AZURE_CONTAINER_GROUP=''
AZURE_RESOURCE_GROUP=''

FILESYSTEM_DISK='local'
AZURE_BLOB_DSN=''
AZURE_CONTAINER_NAME=''
AZURE_BLOB_PREFIX=''
AZURE_FILE_CACHE_CONTAINER_NAME=''
FILE_CACHE_DRIVER='file'

BROADCAST_DRIVER=log
CACHE_DRIVER=file
QUEUE_CONNECTION=sync
SESSION_DRIVER=array
SESSION_LIFETIME=120
SESSION_SECURE_COOKIE=true

REDIS_HOST=127.0.0.1
REDIS_PASSWORD=null
REDIS_PORT=6379

MAIL_MAILER=array
MAIL_USERNAME=null
MAIL_PASSWORD=null
MAIL_ENCRYPTION=null
MAIL_FROM_ADDRESS="[email protected]"
MAIL_FROM_NAME="${APP_NAME}"
MAIL_REPLY_TO_DEFAULT="[email protected]"

SENTRY_DSN=null
SENTRY_ENVIRONMENT=null
SENTRY_TRACES_SAMPLE_RATE=0.0

AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=
AWS_DEFAULT_REGION=us-east-1
AWS_BUCKET=

PUSHER_APP_ID=
PUSHER_APP_KEY=
PUSHER_APP_SECRET=
PUSHER_APP_CLUSTER=mt1

MIX_PUSHER_APP_KEY="${PUSHER_APP_KEY}"
MIX_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"
Loading

0 comments on commit e7dc0d6

Please sign in to comment.