Skip to content

Commit 082bc5b

Browse files
author
Rens Sikma
committed
Merge branch 'enable-openid' into 'master'
fix pipeline See merge request training/lab-tools/moodle-local_oauth!5
2 parents 7ca728c + 36c9f1e commit 082bc5b

File tree

114 files changed

+2610
-11481
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

114 files changed

+2610
-11481
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
/vendor/
2+
.well-known/

.gitlab-ci.yml

100644100755
Lines changed: 38 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
---
22
stages:
3+
# - prepare
34
- test
45
- publish
56

@@ -11,51 +12,61 @@ variables:
1112
COMPOSER_ALLOW_SUPERUSER: 1
1213
COMPOSER_CACHE_DIR: "$CI_PROJECT_DIR/.cache/composer"
1314
NPM_CONFIG_CACHE: "$CI_PROJECT_DIR/.cache/npm"
14-
MOODLE_BRANCH: 'master'
15+
MOODLE_BRANCH: 'main'
1516
MOODLE_BEHAT_WWWROOT: 'http://localhost:8000'
1617
MOODLE_BEHAT_WDHOST: 'http://behat:4444/wd/hub'
1718
MOODLE_START_BEHAT_SERVERS: 'no'
1819
DB: 'mariadb'
1920

2021
default:
21-
# services:
22-
# - name: selenium/standalone-chrome:3
23-
# alias: behat
24-
# - name: mariadb:10.6
25-
# alias: db
26-
# command:
27-
# - '--character-set-server=utf8mb4'
28-
# - '--collation-server=utf8mb4_unicode_ci'
29-
# - '--innodb_file_per_table=On'
30-
# - '--wait-timeout=28800'
31-
# - '--skip-log-bin'
32-
# variables:
33-
# MARIADB_ALLOW_EMPTY_ROOT_PASSWORD: 'yes'
3422
cache:
3523
paths:
3624
- .cache
37-
image: moodlehq/moodle-php-apache:8.1
25+
- vendor/
26+
27+
image: moodlehq/moodle-php-apache:8.3
3828
before_script:
3929
# move to container
4030
- mkdir -p /usr/share/man/man1 /usr/share/man/man3 /usr/share/man/man7
41-
# - apt-get -qq update
42-
# - apt-get -yqq install --no-install-suggests default-jre-headless mariadb-client
31+
- 'curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer'
4332
- 'curl -sS https://raw.githubusercontent.com/creationix/nvm/v0.39.3/install.sh | bash'
4433
- source ~/.bashrc
4534
- nvm install --default --latest-npm lts/gallium
46-
- 'curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer'
47-
- composer create-project -n --no-dev --no-progress --no-ansi --prefer-dist moodlehq/moodle-plugin-ci /opt/mci ^4
48-
- export PATH="/opt/mci/bin:/opt/mci/vendor/bin:$PATH"
35+
- composer create-project -n --no-dev --no-progress --no-ansi --prefer-dist moodlehq/moodle-plugin-ci /opt/moodle-plugin-ci ^4
36+
- export PATH="/opt/moodle-plugin-ci/bin:/opt/moodle-plugin-ci/vendor/bin:$PATH"
4937
# TODO not always needed
5038
# install moodle
5139
# - moodle-plugin-ci install --db-host db
5240
# - '{ php -S 0.0.0.0:8000 -t "$CI_PROJECT_DIR/moodle" >/dev/null 2>&1 & }'
5341

42+
# install dependencies:
43+
# stage: prepare
44+
# script:
45+
# composer install
46+
5447
test:
5548
stage: test
49+
services:
50+
# - name: selenium/standalone-chrome:3
51+
# alias: behat
52+
- name: mariadb:11.6
53+
alias: db
54+
command:
55+
- '--character-set-server=utf8mb4'
56+
- '--collation-server=utf8mb4_unicode_ci'
57+
- '--innodb_file_per_table=On'
58+
- '--wait-timeout=28800'
59+
- '--skip-log-bin'
60+
variables:
61+
MARIADB_ALLOW_EMPTY_ROOT_PASSWORD: 'yes'
5662
script:
63+
- composer install
64+
- apt update
65+
- apt -yqq install --no-install-suggests default-jre-headless mariadb-client
66+
- moodle-plugin-ci install --moodle=/opt/moodle --db-name moodle --db-host db
5767
- moodle-plugin-ci phplint $CI_PROJECT_DIR
5868
- moodle-plugin-ci phpunit $CI_PROJECT_DIR
69+
- moodle-plugin-ci validate $CI_PROJECT_DIR
5970
- moodle-plugin-ci behat --auto-rerun 0 --profile chrome $CI_PROJECT_DIR
6071

6172

@@ -66,8 +77,8 @@ validate:
6677
# variables:
6778
# MOODLE_BRANCH: 'MOODLE_310_STABLE'
6879
script:
80+
- composer install
6981
# - validate-version # TODO complains about CHANGELOG.md, even if it exist double check
70-
# - moodle-plugin-ci validate $CI_PROJECT_DIR # need moodle installed
7182
- moodle-plugin-ci savepoints $CI_PROJECT_DIR
7283

7384
# TODO
@@ -79,19 +90,21 @@ validate:
7990
moodle-lint:
8091
stage: test
8192
image: moodlehq/moodle-php-apache:8.1
82-
# variables:
83-
# MOODLE_BRANCH: 'master'
8493
script:
94+
- composer install
8595
- moodle-plugin-ci phpcs $CI_PROJECT_DIR --ansi
86-
96+
allow_failure: true
8797

8898
package plugin:
8999
stage: publish
90-
image: ubuntu:latest
100+
image: moodlehq/moodle-php-apache:8.1
91101
before_script:
92102
- apt update
93103
- apt install zip -y
94104
script:
105+
- rm -rf vendor/ .cache
106+
- 'curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer'
107+
- composer install --no-dev
95108
- 'version=$(sed -n ''s/\s*$plugin->version\s*=\s\([0-9]*\);.*/\1/p'' version.php)'
96109
- 'echo "version: ${version}"'
97110
- 'folder="$(basename $CI_PROJECT_DIR)"'

OAuth2/Autoloader.php

Lines changed: 0 additions & 54 deletions
This file was deleted.

OAuth2/ClientAssertionType/ClientAssertionTypeInterface.php

Lines changed: 0 additions & 28 deletions
This file was deleted.

OAuth2/ClientAssertionType/HttpBasic.php

Lines changed: 0 additions & 139 deletions
This file was deleted.

0 commit comments

Comments
 (0)