Skip to content

Commit 6d4bffb

Browse files
eddyblnejch
authored andcommitted
docs: Note how to use the Docker image from within GitLab CI
Ref: #2823
1 parent d5b5fb0 commit 6d4bffb

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

README.rst

+17
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,23 @@ You can also mount your own config file:
112112
113113
$ docker run -it --rm -v /path/to/python-gitlab.cfg:/etc/python-gitlab.cfg registry.gitlab.com/python-gitlab/python-gitlab:latest <command> ...
114114
115+
Usage inside GitLab CI
116+
~~~~~~~~~~~~~~~~~~~~~~
117+
118+
If you want to use the Docker image directly inside your GitLab CI as an `image`, you will need to override
119+
the `entrypoint`, `as noted in the official GitLab documentation <https://docs.gitlab.com/ee/ci/docker/using_docker_images.html#override-the-entrypoint-of-an-image>`__:
120+
121+
.. code-block:: yaml
122+
123+
Job Name:
124+
image:
125+
name: registry.gitlab.com/python-gitlab/python-gitlab:latest
126+
entrypoint: [""]
127+
before_script:
128+
gitlab --version
129+
script:
130+
gitlab <command>
131+
115132
Building the image
116133
~~~~~~~~~~~~~~~~~~
117134

0 commit comments

Comments
 (0)