forked from openedx-unsupported/devstack
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathmktg.mk
More file actions
executable file
·62 lines (48 loc) · 2.69 KB
/
mktg.mk
File metadata and controls
executable file
·62 lines (48 loc) · 2.69 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
mktg.help:
@echo ""
@echo "make mktg.COMMAND"
@echo "======================================"
@echo ""
@echo "Commands:"
@echo "build: Build the docker image"
@echo "pushimage: Push the docker image to the shared container repository"
@echo "migrate: Run django migrations i.e. python manage.py migrate"
@echo "langs_push: Run django langs_push command i.e. python manage.py langs_push"
@echo "langs_pull: Run django langs_pull command i.e. python manage.py langs_pull"
@echo "install_pip: Install python dependencies in 'requirements.txt' file"
@echo "install_npm: Install npm dependencies in 'package.json' file"
@echo "copy_cache: Copy node_modules, installed at build time, to the current app"
@echo "dev: Run npm run dev command"
@echo "watch: Run gulp watch"
@echo "install_all: Runs install_pip, install_npm, dev, migrate"
@echo "shell: Open bash shell inside docker container"
@echo "provision: Run provision script, prepare the env"
@echo "restart: Restart the container"
@echo "fix-npm: Fix .npm folder ownership issue"
@echo "help: Print help and exit"
@echo ""
mktg.build:
docker build -t eu.gcr.io/openedx-231314/edraak/marketing:latest -f ../marketing-site/Dockerfile ../marketing-site
mktg.pushimage:
docker push eu.gcr.io/openedx-231314/edraak/marketing:latest
mktg.migrate: ## Kill the Marketing Django development server. The watcher process will restart it.
docker compose `echo ${DOCKER_COMPOSE_FILES}` exec mktg bash -c 'python manage.py migrate --settings=marketingsite.envs.dev'
mktg.langs_push:
docker compose `echo ${DOCKER_COMPOSE_FILES}` exec mktg python manage.py langs_push --settings=marketingsite.envs.dev
mktg.langs_pull:
docker compose `echo ${DOCKER_COMPOSE_FILES}` exec mktg python manage.py langs_pull --settings=marketingsite.envs.dev
mktg.install_pip:
docker compose `echo ${DOCKER_COMPOSE_FILES}` exec mktg pip install -r requirements.txt
mktg.install_npm:
docker compose `echo ${DOCKER_COMPOSE_FILES}` exec mktg npm install
mktg.install_yarn:
docker compose `echo ${DOCKER_COMPOSE_FILES}` exec mktg yarn
mktg.copy_cache:
docker compose `echo ${DOCKER_COMPOSE_FILES}` exec mktg cp -Rnv /cache/node_modules /cache/.compiled /app
mktg.dev:
docker compose `echo ${DOCKER_COMPOSE_FILES}` exec mktg npm run dev
mktg.watch:
docker compose `echo ${DOCKER_COMPOSE_FILES}` exec mktg npx gulp watcher
mktg.install_all: | mktg.install_pip mktg.install_npm mktg.dev mktg.migrate
mktg.fix-npm:
docker compose `echo ${DOCKER_COMPOSE_FILES}` exec mktg bash -c 'chown -R root ~/.npm'