GeezerVison is showing github.com — fix(docker): use docker image with current sources · python-gitlab/python-gitlab@06e8ca8
File tree
Expand file treeCollapse file tree
Open diff view settings
Expand file treeCollapse file tree
Open diff view settings
Collapse file
Copy file name to clipboard +5Lines changed: 5 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
|
| 1 | +venv/ |
| 2 | +dist/ |
| 3 | +build/ |
| 4 | +*.egg-info |
| 5 | +.github/ |
Collapse file
Copy file name to clipboard +16Lines changed: 16 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
|
| 1 | +FROM python:3.7-alpine AS build |
| 2 | + |
| 3 | +WORKDIR /opt/python-gitlab |
| 4 | +COPY . . |
| 5 | +RUN python setup.py bdist_wheel |
| 6 | + |
| 7 | +FROM python:3.7-alpine |
| 8 | + |
| 9 | +WORKDIR /opt/python-gitlab |
| 10 | +COPY --from=build /opt/python-gitlab/dist dist/ |
| 11 | +RUN pip install $(find dist -name *.whl) && \ |
| 12 | + rm -rf dist/ |
| 13 | +COPY docker-entrypoint.sh /usr/local/bin/ |
| 14 | + |
| 15 | +ENTRYPOINT ["docker-entrypoint.sh"] |
| 16 | +CMD ["--version"] |
Collapse file
Copy file name to clipboardExpand all lines: README.rst +22-1Lines changed: 22 additions & 1 deletion - Display the source diff
- Display the rich diff
| Original file line number | Diff line number | Diff line change |
|---|
@@ -20,7 +20,7 @@ It supports the v4 API of GitLab, and provides a CLI tool (``gitlab``). |
20 | 20 | Maintainer(s) wanted |
21 | 21 | ==================== |
22 | 22 |
|
23 | | -We are looking for neww maintainer(s) for this project. See |
| 23 | +We are looking for new maintainer(s) for this project. See |
24 | 24 | https://github.com/python-gitlab/python-gitlab/issues/596. |
25 | 25 |
|
26 | 26 | Installation |
@@ -41,6 +41,27 @@ Install with pip |
41 | 41 |
|
42 | 42 | pip install python-gitlab |
43 | 43 |
|
| 44 | +
|
| 45 | +Using the python-gitlab docker image |
| 46 | +==================================== |
| 47 | + |
| 48 | +How to build |
| 49 | +------------ |
| 50 | + |
| 51 | +``docker build -t python-gitlab:TAG .`` |
| 52 | + |
| 53 | +How to use |
| 54 | +---------- |
| 55 | + |
| 56 | +``docker run -it --rm -e GITLAB_PRIVATE_TOKEN=<your token> -v /path/to/python-gitlab.cfg:/python-gitlab.cfg python-gitlab <command> ...`` |
| 57 | + |
| 58 | +To change the GitLab URL, use `-e GITLAB_URL=<your url>` |
| 59 | + |
| 60 | + |
| 61 | +Bring your own config file: |
| 62 | +``docker run -it --rm -v /path/to/python-gitlab.cfg:/python-gitlab.cfg -e GITLAB_CFG=/python-gitlab.cfg python-gitlab <command> ...`` |
| 63 | + |
| 64 | + |
44 | 65 | Bug reports |
45 | 66 | =========== |
46 | 67 |
|
|
Collapse file
Copy file name to clipboardExpand all lines: contrib/docker/Dockerfile -10Lines changed: 0 additions & 10 deletions Collapse file
Copy file name to clipboardExpand all lines: contrib/docker/README.rst -20Lines changed: 0 additions & 20 deletions Collapse file
Copy file name to clipboard File renamed without changes.