You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by br...@apache.org on 2023/01/13 17:29:46 UTC

[allura] branch master updated (5c097234d -> d83ca5900)

This is an automated email from the ASF dual-hosted git repository.

brondsem pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/allura.git


    from 5c097234d performance optimizations related to anonymous()
     new 259ffd830 add --rm to single-use docker-compose commands, so container is cleaned up after
     new d83ca5900 [#8488] make new image names work still on docker compose 1.x

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 Allura/docs/development/contributing.rst       |  6 +++---
 Allura/docs/getting_started/administration.rst |  2 +-
 Allura/docs/getting_started/installation.rst   | 16 ++++++++--------
 docker-compose-prod.yml                        |  1 +
 docker-compose.yml                             |  1 +
 scripts/jenkins-python3.7.sh                   |  2 +-
 6 files changed, 15 insertions(+), 13 deletions(-)


[allura] 02/02: [#8488] make new image names work still on docker compose 1.x

Posted by br...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

brondsem pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/allura.git

commit d83ca5900f6e032bce3a2df7d4b88291b384ad91
Author: Dave Brondsema <db...@slashdotmedia.com>
AuthorDate: Fri Jan 13 12:28:28 2023 -0500

    [#8488] make new image names work still on docker compose 1.x
---
 docker-compose-prod.yml | 1 +
 docker-compose.yml      | 1 +
 2 files changed, 2 insertions(+)

diff --git a/docker-compose-prod.yml b/docker-compose-prod.yml
index 9fd59fc60..9f035d0d7 100644
--- a/docker-compose-prod.yml
+++ b/docker-compose-prod.yml
@@ -39,6 +39,7 @@ version: "2.1"
 services:
   web:
     build: .
+    image: allura-web  # default in Compose 2+, makes work in Compose 1.x
     environment: &env
       # PATH=/allura-data/virtualenv/bin:$PATH doesn't work; see https://github.com/docker/compose/issues/650
       - PATH=/allura-data/virtualenv/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
diff --git a/docker-compose.yml b/docker-compose.yml
index ea91932ab..d340c4b1d 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -19,6 +19,7 @@ version: "2.1"
 services:
   web:
     build: .
+    image: allura-web  # default in Compose 2+, makes work in Compose 1.x
     environment: &env
       # PATH=/allura-data/virtualenv/bin:$PATH doesn't work; see https://github.com/docker/compose/issues/650
       - PATH=/allura-data/virtualenv/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin


[allura] 01/02: add --rm to single-use docker-compose commands, so container is cleaned up after

Posted by br...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

brondsem pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/allura.git

commit 259ffd8301585dcdab53b7dc7eb313814764bc51
Author: Dave Brondsema <db...@slashdotmedia.com>
AuthorDate: Fri Jan 13 12:27:55 2023 -0500

    add --rm to single-use docker-compose commands, so container is cleaned up after
---
 Allura/docs/development/contributing.rst       |  6 +++---
 Allura/docs/getting_started/administration.rst |  2 +-
 Allura/docs/getting_started/installation.rst   | 16 ++++++++--------
 scripts/jenkins-python3.7.sh                   |  2 +-
 4 files changed, 13 insertions(+), 13 deletions(-)

diff --git a/Allura/docs/development/contributing.rst b/Allura/docs/development/contributing.rst
index 29ac70776..d02207aaa 100644
--- a/Allura/docs/development/contributing.rst
+++ b/Allura/docs/development/contributing.rst
@@ -198,10 +198,10 @@ as ``pudb`` are also available.
 
    To do this with docker, the commands are::
 
-       docker-compose run web pip install ipdb
+       docker-compose run --rm web pip install ipdb
        docker-compose stop web taskd
-       docker-compose run --service-ports web gunicorn --reload --paste Allura/docker-dev.ini -b :8088
-       docker-compose run taskd paster taskd docker-dev.ini --nocapture
+       docker-compose run --rm --service-ports web gunicorn --reload --paste Allura/docker-dev.ini -b :8088
+       docker-compose run --rm taskd paster taskd docker-dev.ini --nocapture
 
 
 Testing
diff --git a/Allura/docs/getting_started/administration.rst b/Allura/docs/getting_started/administration.rst
index 7ab6e12b1..44694c048 100644
--- a/Allura/docs/getting_started/administration.rst
+++ b/Allura/docs/getting_started/administration.rst
@@ -114,7 +114,7 @@ Scripts are in the :file:`scripts/` directory and run slightly differently, via
 
 To run these when using docker, prefix with :code:`docker-compose run taskd` and use :file:`docker-dev.ini` like::
 
-    docker-compose run taskd paster create-neighborhood docker-dev.ini myneighborhood myuser ...
+    docker-compose run --rm taskd paster create-neighborhood docker-dev.ini myneighborhood myuser ...
 
 Or with the docker *production* setup::
 
diff --git a/Allura/docs/getting_started/installation.rst b/Allura/docs/getting_started/installation.rst
index 8baea1555..e0b3df4f5 100644
--- a/Allura/docs/getting_started/installation.rst
+++ b/Allura/docs/getting_started/installation.rst
@@ -69,7 +69,7 @@ Python and JS package setup (and first containers started):
 
 .. code-block:: bash
 
-    docker-compose run web scripts/init-docker-dev.sh
+    docker-compose run --rm web scripts/init-docker-dev.sh
 
 Restart SOLR container, so it will see changes from the command above and create index:
 
@@ -81,11 +81,11 @@ Initialize database with test data:
 
 .. code-block:: bash
 
-    docker-compose run taskd paster setup-app docker-dev.ini
+    docker-compose run --rm taskd paster setup-app docker-dev.ini
 
 .. note::
 
-   If you want to skip test data creation you can instead run: :code:`docker-compose run -e ALLURA_TEST_DATA=False taskd paster setup-app docker-dev.ini`
+   If you want to skip test data creation you can instead run: :code:`docker-compose run --rm -e ALLURA_TEST_DATA=False taskd paster setup-app docker-dev.ini`
 
 Start containers in the background:
 
@@ -174,8 +174,8 @@ Update requirements and reinstall apps:
 
 .. code-block:: bash
 
-    docker-compose run web pip install -r requirements.txt
-    docker-compose run web ./rebuild-all.bash
+    docker-compose run --rm web pip install -r requirements.txt
+    docker-compose run --rm web ./rebuild-all.bash
 
 You may want to restart at least "taskd" container after that in order for it to
 pick up changes.  Run :code:`docker-compose restart taskd`
@@ -184,19 +184,19 @@ Run all tests:
 
 .. code-block:: bash
 
-    docker-compose run web ./run_tests
+    docker-compose run --rm web ./run_tests
 
 Running subset of tests:
 
 .. code-block:: bash
 
-    docker-compose run web bash -c 'cd ForgeGit && pytest forgegit/tests/functional/test_controllers.py::TestFork'
+    docker-compose run --rm web bash -c 'cd ForgeGit && pytest forgegit/tests/functional/test_controllers.py::TestFork'
 
 Connecting to mongo using a container:
 
 .. code-block:: bash
 
-    docker-compose run mongo mongo --host mongo
+    docker-compose run --rm mongo mongo --host mongo
 
 
 .. _post-setup-instructions:
diff --git a/scripts/jenkins-python3.7.sh b/scripts/jenkins-python3.7.sh
index d8f5baa67..f6f08ba4c 100755
--- a/scripts/jenkins-python3.7.sh
+++ b/scripts/jenkins-python3.7.sh
@@ -56,7 +56,7 @@ echo
 echo "============================================================================="
 echo "Setup: venv, pip, pysvn, ./rebuild-all.sh, npm, etc."
 echo "============================================================================="
-docker-compose run web scripts/init-docker-dev.sh
+docker-compose run --rm web scripts/init-docker-dev.sh
 
 echo
 echo "============================================================================="