mirror of
https://github.com/ChristianLight/tutor.git
synced 2025-01-06 07:30:40 +00:00
ACTIVATE_* env vars are only necessary during configuration
This commit is contained in:
parent
f85b0abac4
commit
7f5e91a0db
@ -1,10 +1,8 @@
|
||||
language: minimal
|
||||
services:
|
||||
- docker
|
||||
env:
|
||||
- ACTIVATE_NOTES=1 ACTIVATE_XQUEUE=1
|
||||
script:
|
||||
- make configure SILENT=1
|
||||
- make configure SILENT=1 ACTIVATE_NOTES=1 ACTIVATE_XQUEUE=1
|
||||
- make build
|
||||
- make migrate
|
||||
#- make assets # too time-consuming
|
||||
|
10
Makefile
10
Makefile
@ -4,6 +4,7 @@ PWD ?= $$(pwd)
|
||||
USERID ?= $$(id -u)
|
||||
EDX_PLATFORM_SETTINGS ?= universal.production
|
||||
DOCKER_COMPOSE = docker-compose -f docker-compose.yml
|
||||
-include $(PWD)/config/Makefile.env
|
||||
|
||||
post_configure_targets =
|
||||
ifneq ($(DISABLE_STATS), 1)
|
||||
@ -34,7 +35,12 @@ endif
|
||||
DOCKER_COMPOSE_RUN_LMS = $(DOCKER_COMPOSE_RUN_OPENEDX) -p 8000:8000 lms
|
||||
DOCKER_COMPOSE_RUN_CMS = $(DOCKER_COMPOSE_RUN_OPENEDX) -p 8001:8001 cms
|
||||
|
||||
all: configure $(post_configure_targets) update migrate assets daemonize
|
||||
all: configure # other targets are not listed as requirements in order to reload the env file
|
||||
@$(MAKE) post_configure
|
||||
@$(MAKE) update
|
||||
@$(MAKE) migrate
|
||||
@$(MAKE) assets
|
||||
@$(MAKE) daemonize
|
||||
@echo "All set \o/ You can access the LMS at http://localhost and the CMS at http://studio.localhost"
|
||||
|
||||
##################### Bootstrapping
|
||||
@ -45,6 +51,8 @@ configure: build-configurator
|
||||
-e SETTING_ACTIVATE_HTTPS=$(ACTIVATE_HTTPS) -e SETTING_ACTIVATE_NOTES=$(ACTIVATE_NOTES) -e SETTING_ACTIVATE_PORTAINER=$(ACTIVATE_PORTAINER) -e SETTING_ACTIVATE_XQUEUE=$(ACTIVATE_XQUEUE) \
|
||||
regis/openedx-configurator:hawthorn
|
||||
|
||||
post_configure: $(post_configure_targets)
|
||||
|
||||
stats:
|
||||
@docker run --rm -it --volume="$(PWD)/config:/openedx/config" \
|
||||
regis/openedx-configurator:hawthorn /openedx/config/openedx/stats 2> /dev/null|| true
|
||||
|
@ -29,6 +29,8 @@ Some optional features may be activated by defining `ACTIVATE_*` environment var
|
||||
|
||||
ACTIVATE_HTTPS=1 make all
|
||||
|
||||
Technically, the `ACTIVATE_*` environment variables are only required during `make configure`. After that, they will be automatically loaded from `config/Makefile.env`.
|
||||
|
||||
### SSL/TLS certificates for HTTPS access (`ACTIVATE_HTTPS`)
|
||||
|
||||
By activating this feature, a free SSL/TLS certificate from the [Let's Encrypt](https://letsencrypt.org/) certificate authority will be created for your platform. With this feature, **your platform will no longer be accessible in HTTP**. Calls to http urls will be redirected to https url.
|
||||
|
@ -154,6 +154,8 @@ def interactive(args):
|
||||
'XQUEUE_MYSQL_PASSWORD', "", random_string(8)
|
||||
).add(
|
||||
'XQUEUE_SECRET_KEY', "", random_string(24)
|
||||
).add_bool(
|
||||
'DISABLE_STATS', "", False
|
||||
).add_bool(
|
||||
'ACTIVATE_NOTES', "", False
|
||||
).add_bool(
|
||||
|
5
configurator/templates/Makefile.env
Normal file
5
configurator/templates/Makefile.env
Normal file
@ -0,0 +1,5 @@
|
||||
DISABLE_STATS = {{ 1 if DISABLE_STATS else 0 }}
|
||||
ACTIVATE_HTTPS = {{ 1 if ACTIVATE_HTTPS else 0 }}
|
||||
ACTIVATE_XQUEUE = {{ 1 if ACTIVATE_XQUEUE else 0 }}
|
||||
ACTIVATE_NOTES = {{ 1 if ACTIVATE_NOTES else 0 }}
|
||||
ACTIVATE_PORTAINER = {{ 1 if ACTIVATE_PORTAINER else 0 }}
|
Loading…
Reference in New Issue
Block a user