forked from moodle/moodle
-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Topic/ucsfcle 404/tugboatqa #55
Merged
ctam
merged 4 commits into
ucsf-education:UCSFCLE_404_STABLE
from
lbailey-ucsf:topic/UCSFCLE_404/tugboatqa
Sep 4, 2024
Merged
Changes from 3 commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
52b6891
added tugboatqa config. uses php8.3 and mariadb:latest images
lbailey-ucsf eae9640
Update config.yml. Downgraded mariddb image from latest to 10.11.9.
lbailey-ucsf cd96173
Update config.yml. Downgraded mariadb image to 10.11.8.
lbailey-ucsf 3bec237
Update Tugboat config.yml to remove phpmyadmin and fix a message typo.
lbailey-ucsf File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
services: | ||
webserver: | ||
image: "tugboatqa/php:8.3-apache" | ||
default: true | ||
checkout_path: "/var/www/moodle" | ||
depends_on: | ||
- db | ||
commands: | ||
init: | ||
- echo "****** initializing webserver *****" | ||
|
||
- echo "****** installing required php extensions *****" | ||
- sudo apt-get update | ||
- sudo apt-get install libzip-dev | ||
- sudo apt-get install -y unzip git | ||
- docker-php-ext-install mysqli | ||
- docker-php-ext-install zip | ||
- docker-php-ext-install soap | ||
- docker-php-ext-install intl | ||
- docker-php-ext-install exif | ||
|
||
- echo "****** initializing the submodules *****" | ||
- git config submodule.admin/tool/ucsfsomapi.url https://${GITHUB_TOKEN_USER}:${GITHUB_TOKEN}@github.com/ucsf-education/tool_ucsfsomapi.git | ||
- git submodule update --init | ||
|
||
- echo "****** Setting php config variables ******" | ||
- echo "max_input_vars = 5000" >> /usr/local/etc/php/conf.d/max_input_vars.ini | ||
|
||
# Link the document root to the expected path. | ||
- ln -snf "$TUGBOAT_ROOT" "${DOCROOT}" | ||
|
||
#make required dirs and set permissions. | ||
- mkdir /var/www/moodledata | ||
- mkdir /var/www/phpunitdata | ||
- mkdir /var/www/behatdata | ||
- mkdir /var/www/behatfaildumps | ||
- chmod 0777 /var/www/moodledata | ||
|
||
update: | ||
- echo "****** updatig webserver *****" | ||
- composer install --optimize-autoloader --ignore-platform-req=ext-zip --ignore-platform-req=ext-intl | ||
- service apache2 start | ||
|
||
build: | ||
# - npm install | ||
# - npx grunt | ||
- echo "****** building webserver *****" | ||
- chown www-data $DOCROOT | ||
- | | ||
sudo -u www-data php admin/cli/install.php \ | ||
--non-interactive --agree-license --lang=en \ | ||
--wwwroot=https://${TUGBOAT_DEFAULT_SERVICE_URL_HOST} \ | ||
--dataroot=/var/www/moodledata \ | ||
--dbtype=${MOODLE_DBTYPE} --dbhost=db --dbname=${MOODLE_DBNAME} --dbuser=${MOODLE_DBUSER} --dbpass=${MOODLE_DBPASS} --prefix=m_ \ | ||
--adminuser=${MOODLE_DBADMIN_NAME} --adminpass=${MOODLE_DBADMIN_PASS} \ | ||
--fullname=PREVIEW --shortname=PREVIEW --adminemail=${MOODLE_ADMIN_EMAIL} | ||
- chown -R root $DOCROOT | ||
|
||
online: | ||
- php admin/tool/generator/cli/maketestsite.php --size=S --bypasscheck | ||
|
||
db: | ||
image: "tugboatqa/mariadb:10.11.8" | ||
commands: | ||
init: | ||
- echo "*** intializing database ***" | ||
- mysql -e "SET GLOBAL character_set_server=utf8mb4;" | ||
- mysql -e "SET GLOBAL collation_server=utf8mb4_bin;" | ||
- mysql -e "SET GLOBAL innodb_file_per_table=ON;" | ||
- mysql -e "SET GLOBAL wait_timeout=28800;" | ||
- export MYSQL_ROOT_PASSWORD=${MOODLE_DBPASS} | ||
- export MYSQL_DATABASE=${MOODLE_DBNAME} | ||
- export MYSQL_USER=${MOODLE_DBUSER} | ||
- export MYSQL_PASSWORD=${MOODLE_DBPASS} | ||
- mysql -e "CREATE DATABASE IF NOT EXISTS ${MOODLE_DBNAME}; GRANT ALL PRIVILEGES ON moodle.* TO '${MOODLE_DBNAME}'@'%' IDENTIFIED BY '${MOODLE_DBPASS}'; FLUSH PRIVILEGES;" | ||
|
||
phpmyadmin: | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. phpMyAdmin, interesting. Can we take this out for now, and save it for later, when there is a need for it? |
||
expose: 80 | ||
image: phpmyadmin/phpmyadmin |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Small typo: should be 'updating'.