mirror of
https://github.com/ChristianLight/tutor.git
synced 2025-01-22 21:28:24 +00:00
Merge remote-tracking branch 'origin/master' into nightly
This commit is contained in:
commit
dbe3571ed4
@ -4,6 +4,11 @@ Note: Breaking changes between versions are indicated by "💥".
|
||||
|
||||
## Unreleased
|
||||
|
||||
## v13.1.7 (2022-03-17)
|
||||
|
||||
- [Bugfix] Fix dockerize on arm64 by switching to the [powerman/dockerize](https://github.com/powerman/dockerize) fork (#591).
|
||||
- [Bugfix] Fix "Unexpected args" error during service initialization on Kubernetes (#611).
|
||||
|
||||
## v13.1.6 (2022-03-15)
|
||||
|
||||
- [Bugfix] Fix `local/k8s quickstart` commands when upgrading from an older release (#595).
|
||||
|
@ -53,7 +53,7 @@ Enable SAML authentication
|
||||
|
||||
openedx-lms-common-settings: |
|
||||
# saml special settings
|
||||
AUTHENTICATION_BACKENDS += ["third_party_auth.saml.SAMLAuthBackend", "django.contrib.auth.backends.ModelBackend"]
|
||||
AUTHENTICATION_BACKENDS += ["common.djangoapps.third_party_auth.saml.SAMLAuthBackend", "django.contrib.auth.backends.ModelBackend"]
|
||||
|
||||
openedx-auth: |
|
||||
"SOCIAL_AUTH_SAML_SP_PRIVATE_KEY": "yoursecretkey",
|
||||
|
@ -22,9 +22,9 @@ Next, configure Tutor::
|
||||
|
||||
Go through the configuration process, answering each question.
|
||||
|
||||
Then, build the Open edX image::
|
||||
Then, build the "openedx" and "permissions" images::
|
||||
|
||||
tutor images build openedx
|
||||
tutor images build openedx permissions
|
||||
|
||||
If you want to use Tutor as an Open edX development environment, you should also build the development images::
|
||||
|
||||
@ -45,18 +45,16 @@ Configure Tutor to use MariaDB::
|
||||
Finish setup and start Tutor
|
||||
----------------------------
|
||||
|
||||
From this point on, use Tutor as normal.
|
||||
|
||||
For example, to apply migrations and start Open edX::
|
||||
From this point on, use Tutor as normal. For example, start Open edX and run migrations with::
|
||||
|
||||
tutor local start -d
|
||||
tutor local init
|
||||
tutor local start
|
||||
|
||||
Or for a development environment::
|
||||
|
||||
tutor local init
|
||||
tutor local stop
|
||||
tutor dev start
|
||||
tutor dev start -d
|
||||
tutor dev init
|
||||
|
||||
Using with tutor-mfe
|
||||
--------------------
|
||||
|
@ -2,7 +2,7 @@ import os
|
||||
|
||||
# Increment this version number to trigger a new release. See
|
||||
# docs/tutor.html#versioning for information on the versioning scheme.
|
||||
__version__ = "13.1.6"
|
||||
__version__ = "13.1.7"
|
||||
|
||||
# The version suffix will be appended to the actual version, separated by a
|
||||
# dash. Use this suffix to differentiate between the actual released version and
|
||||
|
@ -113,6 +113,7 @@ class K8sJobRunner(jobs.BaseJobRunner):
|
||||
# We cannot use the k8s API to create the job: configMap and volume names need
|
||||
# to be found with the right suffixes.
|
||||
kubectl_apply(
|
||||
self.root,
|
||||
"--selector",
|
||||
f"app.kubernetes.io/name={job_name}",
|
||||
)
|
||||
@ -232,27 +233,21 @@ def start(context: Context, names: List[str]) -> None:
|
||||
for name in names:
|
||||
if name == "all":
|
||||
# Create volumes
|
||||
utils.kubectl(
|
||||
"apply",
|
||||
"--kustomize",
|
||||
tutor_env.pathjoin(context.root),
|
||||
kubectl_apply(
|
||||
context.root,
|
||||
"--wait",
|
||||
"--selector",
|
||||
"app.kubernetes.io/component=volume",
|
||||
)
|
||||
# Create everything else except jobs
|
||||
utils.kubectl(
|
||||
"apply",
|
||||
"--kustomize",
|
||||
tutor_env.pathjoin(context.root),
|
||||
kubectl_apply(
|
||||
context.root,
|
||||
"--selector",
|
||||
"app.kubernetes.io/component notin (job,volume,namespace)",
|
||||
)
|
||||
else:
|
||||
utils.kubectl(
|
||||
"apply",
|
||||
"--kustomize",
|
||||
tutor_env.pathjoin(context.root),
|
||||
kubectl_apply(
|
||||
context.root,
|
||||
"--selector",
|
||||
f"app.kubernetes.io/name={name}",
|
||||
)
|
||||
|
@ -56,24 +56,20 @@ def initialise(runner: BaseJobRunner, limit_to: Optional[str] = None) -> None:
|
||||
if limit_to is None or limit_to == plugin_name:
|
||||
for service in hook:
|
||||
fmt.echo_info(
|
||||
"Plugin {}: running pre-init for service {}...".format(
|
||||
plugin_name, service
|
||||
)
|
||||
f"Plugin {plugin_name}: running pre-init for service {service}..."
|
||||
)
|
||||
runner.run_job_from_template(
|
||||
service, plugin_name, "hooks", service, "pre-init"
|
||||
)
|
||||
for service in ["lms", "cms"]:
|
||||
if limit_to is None or limit_to == service:
|
||||
fmt.echo_info("Initialising {}...".format(service))
|
||||
fmt.echo_info(f"Initialising {service}...")
|
||||
runner.run_job_from_template(service, "hooks", service, "init")
|
||||
for plugin_name, hook in runner.iter_plugin_hooks("init"):
|
||||
if limit_to is None or limit_to == plugin_name:
|
||||
for service in hook:
|
||||
fmt.echo_info(
|
||||
"Plugin {}: running init for service {}...".format(
|
||||
plugin_name, service
|
||||
)
|
||||
f"Plugin {plugin_name}: running init for service {service}..."
|
||||
)
|
||||
runner.run_job_from_template(
|
||||
service, plugin_name, "hooks", service, "init"
|
||||
@ -136,9 +132,7 @@ site.themes.create(theme_dir_name='{theme_name}')
|
||||
""".format(
|
||||
theme_name=theme_name, domain_name=domain_name
|
||||
)
|
||||
command = BASE_OPENEDX_COMMAND + './manage.py lms shell -c "{python_code}"'.format(
|
||||
python_code=python_code
|
||||
)
|
||||
command = BASE_OPENEDX_COMMAND + f'./manage.py lms shell -c "{python_code}"'
|
||||
runner.run_job("lms", command)
|
||||
|
||||
|
||||
|
@ -23,10 +23,12 @@ RUN $PYENV_ROOT/versions/$PYTHON_VERSION/bin/python -m venv /openedx/venv
|
||||
|
||||
###### Install Dockerize to wait for mysql DB availability
|
||||
FROM minimal as dockerize
|
||||
ARG DOCKERIZE_VERSION=v0.6.1
|
||||
RUN curl -L -o /tmp/dockerize.tar.gz https://github.com/jwilder/dockerize/releases/download/$DOCKERIZE_VERSION/dockerize-linux-amd64-$DOCKERIZE_VERSION.tar.gz \
|
||||
&& tar -C /usr/local/bin -xzvf /tmp/dockerize.tar.gz \
|
||||
&& rm /tmp/dockerize.tar.gz
|
||||
# https://github.com/powerman/dockerize/releases
|
||||
ARG DOCKERIZE_VERSION=v0.16.0
|
||||
RUN dockerize_url="https://github.com/powerman/dockerize/releases/download/$DOCKERIZE_VERSION/dockerize-linux-$(uname -m | sed 's@aarch@arm@')" \
|
||||
&& echo "Downloading dockerize from $dockerize_url" \
|
||||
&& curl --fail --location --output /usr/local/bin/dockerize $dockerize_url \
|
||||
&& chmod a+x /usr/local/bin/dockerize
|
||||
|
||||
###### Checkout edx-platform code
|
||||
FROM minimal as code
|
||||
@ -123,7 +125,7 @@ ARG APP_USER_ID=1000
|
||||
RUN useradd --home-dir /openedx --create-home --shell /bin/bash --uid ${APP_USER_ID} app
|
||||
USER ${APP_USER_ID}
|
||||
|
||||
COPY --chown=app:app --from=dockerize /usr/local/bin/dockerize /usr/local/bin/dockerize
|
||||
COPY --from=dockerize /usr/local/bin/dockerize /usr/local/bin/dockerize
|
||||
COPY --chown=app:app --from=code /openedx/edx-platform /openedx/edx-platform
|
||||
COPY --chown=app:app --from=locales /openedx/locale /openedx/locale
|
||||
COPY --chown=app:app --from=python /opt/pyenv /opt/pyenv
|
||||
|
Loading…
x
Reference in New Issue
Block a user