gitlab-ce-ldap-sync icon indicating copy to clipboard operation
gitlab-ce-ldap-sync copied to clipboard

Dockerize

Open d0lb33 opened this issue 3 years ago • 1 comments

Would love to have this on docker hub. I wrote a little docker file that can probably be optimized, but works fine for me right now if you'd like to expand on it/add it to the project:

FROM php:7.4.9-cli-alpine3.12

COPY --from=mlocati/php-extension-installer /usr/bin/install-php-extensions /usr/bin/

RUN apk update
RUN apk add bash
RUN apk add curl

# Install PHP extensions
RUN install-php-extensions ldap


# INSTALL COMPOSER
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/bin --filename=composer 

WORKDIR /app
COPY . .

RUN composer install

CMD ["php", "bin/console", "ldap:sync"]

d0lb33 avatar Aug 09 '22 12:08 d0lb33

I've literally never used Docker, but feel free to send a PR up so you can retain credit. :)

Adambean avatar Oct 13 '22 15:10 Adambean