Make running sytest docker work in worker mode#573
Merged
Conversation
This also includes moving a bunch of setup into the docker image so that the containers start up a lot faster.
richvdh
requested changes
Mar 15, 2019
| RUN /venv/bin/pip install -q --no-cache-dir lxml psycopg2 | ||
|
|
||
| # Uninstall matrix-synapse package so it doesn't collide with the version we try | ||
| # Zand test |
| RUN /venv/bin/pip install -q --no-cache-dir lxml psycopg2 | ||
|
|
||
| # Uninstall matrix-synapse package so it doesn't collide with the version we try | ||
| # Zand test |
|
|
||
| RUN su -c '/usr/lib/postgresql/9.6/bin/initdb -E "UTF-8" --lc-collate="en_US.UTF-8" --lc-ctype="en_US.UTF-8" --username=postgres' postgres | ||
|
|
||
| # Turn of all the fsync stuff for postgres |
| @@ -1,14 +1,35 @@ | |||
| FROM matrixdotorg/sytest:latest | |||
Member
There was a problem hiding this comment.
it'd be really nice to combine these two into one dockerfile with an ARG in the same way that synapse's dockerfile works.
Member
There was a problem hiding this comment.
given that the lifespan of the py2 version is only a fortnight, not important, I guess.
| This will run on the same branch in SyTest as the Synapse checkout, if possible, but will fall back to using develop. | ||
|
|
||
| If you want to use an existing checkout of SyTest, mount it to `/test` inside the container by adding `-v /path/to/sytest\:/test` to the docker command. | ||
| If you want to use an existing checkout of SyTest, mount it to `/test` inside the container by adding `-v /path/to/sytest\:/test` to the docker command (note that this will be written to). |
| server = HTTPServer(('', PORT_NUMBER), WebHandler) | ||
| server.serve_forever() | ||
|
|
||
| except KeyboardInterrupt: |
Member
Author
There was a problem hiding this comment.
This (empirically) captures when we ask docker to stop half way through a job.
| perl \ | ||
| wget \ | ||
| postgresql \ | ||
| postgresql-9.6 \ |
Member
There was a problem hiding this comment.
it feels weird that we are doing this here rather than in Dockerfile-synapsepy2 or whatever
richvdh
approved these changes
Mar 15, 2019
richvdh
approved these changes
Mar 15, 2019
Member
richvdh
left a comment
There was a problem hiding this comment.
actually it's fine. fix the typos and ship it.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This also includes moving a bunch of setup into the docker image so that
the containers start up a lot faster.
This does make the docker images about ~1.1GB, which is quite a lot bigger than before.
Depends on matrix-org/synapse#4853