Skip to content
This repository has been archived by the owner on Aug 1, 2024. It is now read-only.

Commit

Permalink
docs: add make help output to docs (#1180)
Browse files Browse the repository at this point in the history
Also includes minor typo fixes.
  • Loading branch information
robrap committed Sep 19, 2023
1 parent 0c0c72f commit 8b892ff
Showing 1 changed file with 94 additions and 3 deletions.
97 changes: 94 additions & 3 deletions docs/devstack_interface.rst
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ Examples:
make dev.logs.frontend-app-gradebook
make frontend-app-gradebook-logs
The user interface for devstack often also gives you both big hammers(``make dev.pull.large-and-slow``) and small hammers(``make dev.pull.<service>``) to do things. It is recommend you opt for the small hammer commands, because they often tend to be alot faster.
The user interface for devstack often also gives you both big hammers (``make dev.pull.large-and-slow``) and small hammers (``make dev.pull.<service>``) to do things. It is recommend you opt for the small hammer commands, because they often tend to be a lot faster.

See the ``make help`` section below for a complete list of commands.

Useful Commands and Summary
~~~~~~~~~~~~~~~~~~~~~~~~~~~
Expand All @@ -27,7 +29,7 @@ Useful Commands and Summary
- ``dev.pull.<service>`` - Pull latest Docker images for the service and its dependencies

When to use: If you have not used Devstack for a while or pulled new images for a while, the installed requirements in your containers might no longer match those used by your code. So it is recommended you pull new images whenever you want your containers to have the latest requirements(python libraries...) installed.
When to use: If you have not used Devstack for a while or pulled new images for a while, the installed requirements in your containers might no longer match those used by your code. So it is recommended you pull new images whenever you want your containers to have the latest requirements (python libraries...) installed.

Note: for new service images to be used, you first need to bring down those services and then bring them back up after a pull.

Expand Down Expand Up @@ -116,7 +118,7 @@ Useful Commands and Summary

Variation: ``make <service>-restart-devserver``.

- ``dev.restart-container.<service>`` restarts service container. This is essentially a stronger version of ``dev.restrart-devserver``
- ``dev.restart-container.<service>`` restarts service container. This is essentially a stronger version of ``dev.restart-devserver``

Note: this will only restart <container> and not its dependencies

Expand All @@ -129,3 +131,92 @@ Useful Commands and Summary
- ``dev.restore`` will restore your database volumes to the backups created using ``dev.backup``

Warning: This will overwrite your databases. Only use if you want all your database volumes to revert back to the backup.

Make Help
~~~~~~~~~

The following ``make help`` output was generated in 09-2023 to make these commands searchable in documentation.

If you want to ensure you are getting the latest listing, simply use ``make help``.

.. code:: sh
% make help
Please use `make <target>' where <target> is one of
build-courses Build course and provision cms, and ecommerce with it.
create-test-course Provisions cms, and ecommerce with course(s) in test-course.json.
dev.attach.% Attach to the specified service container process for debugging & seeing logs.
dev.backup Write all data volumes to the host.
dev.cache-programs Copy programs from Discovery to Memcached for use in LMS.
dev.check Run checks for the default service set.
dev.check-memory Check if enough memory has been allocated to Docker.
dev.checkout Check out "openedx-release/$OPENEDX_RELEASE" in each repo if set, use default branch otherwise.
dev.clone Clone service repos to the parent directory.
dev.clone.https Clone service repos using HTTPS method to the parent directory.
dev.clone.ssh Clone service repos using SSH method to the parent directory.
dev.dbcopy8.% Copy data from old mysql 5.7 container into a new 8 db
dev.dbshell.% Run a SQL shell on the given database.
dev.destroy Irreversibly remove all devstack-related containers and networks (though not data volumes)
dev.destroy.coursegraph Remove all coursegraph data.
dev.down Documentation for a change to naming
dev.drop-db.% Irreversably drop the contents of a MySQL database in each mysql container.
dev.forum.build-indices Build indices for forum service
dev.kill Kill all running services.
dev.kill.% Kill specific services.
dev.logs View logs from running containers.
dev.logs.% View the logs of the specified service container.
dev.migrate Run migrations for applicable default services.
dev.migrate.% Run migrations on a service.
dev.print-container.% Get the ID of the running container for a given service.
dev.provision Provision dev environment with default services, and then stop them.
dev.provision.% Provision specified services.
dev.prune Prune dangling docker images, containers, and networks. Useful when you get the 'no space left on device' error
dev.ps View list of created services and their statuses.
dev.pull.% Pull latest Docker images for services and their dependencies.
dev.pull.large-and-slow Pull latest Docker images required by default services.
dev.pull.without-deps.% Pull latest Docker images for specific services.
dev.remove-containers Stop and remove containers and networks for all services.
dev.remove-containers.% Stop and remove containers for specific services.
dev.reset Attempt to reset the local devstack to the default branch working state without destroying data.
dev.reset-repos Attempt to reset the local repo checkouts to the default branch working state.
dev.restart-container Restart all service containers.
dev.restart-container.% Restart specific services' containers.
dev.restart-devserver.% Kill an edX service's development server. Watcher should restart it.
dev.restore Restore all data volumes from the host. WILL OVERWRITE ALL EXISTING DATA!
dev.rm-stopped Remove stopped containers. Does not affect running containers.
dev.shell.% Run a shell on the specified service's container.
dev.static.% Rebuild static assets for the specified service's container.
dev.stats Get per-container CPU and memory utilization data.
dev.status Prints the status of all git repositories.
dev.stop Stop all running services.
dev.stop.% Stop specific services.
dev.up.attach.% Bring up a service and its dependencies + and attach to it.
dev.up.large-and-slow Bring up default services.
dev.up.shell.% Bring up a service and its dependencies + shell into it.
dev.up.with-programs Bring up default services + cache programs in LMS.
dev.up.with-programs.% Bring up services and their dependencies + cache programs in LMS.
dev.up.with-watchers Bring up default services + asset watcher containers.
dev.up.with-watchers.% Bring up services and their dependencies + asset watcher containers.
dev.up.without-deps.% Bring up services by themselves.
dev.up.without-deps.shell.% Bring up a service by itself + shell into it.
dev.validate Print effective Docker Compose config, validating files in COMPOSE_FILE.
devpi-password Get the root devpi password for the devpi container.
docs generate Sphinx HTML documentation, including API docs
hadoop-application-logs-% View hadoop logs by application Id.
help Display this help message.
impl-dev.clone.https Clone service repos using HTTPS method to the parent directory.
impl-dev.clone.ssh Clone service repos using SSH method to the parent directory.
impl-dev.provision Provision dev environment with default services, and then stop them.
impl-dev.provision.% Provision specified services.
impl-dev.pull.% Pull latest Docker images for services and their dependencies.
impl-dev.pull.without-deps.% Pull latest Docker images for specific services.
impl-dev.up.% Bring up services and their dependencies.
impl-dev.up.attach.% Bring up a service and its dependencies + and attach to it.
impl-dev.up.without-deps.% Bring up services by themselves.
metrics-opt-in To opt into basic data collection to help improve devstack
metrics-opt-out To opt out of metrics data collection
requirements install development environment requirements
selfcheck Check that the Makefile is free of Make syntax errors.
upgrade Upgrade requirements with pip-tools.
validate-lms-volume Validate that changes to the local workspace are reflected in the LMS container.
vnc-passwords Get the VNC passwords for the Chrome and Firefox Selenium containers.

0 comments on commit 8b892ff

Please sign in to comment.