Sign inSign up

stano/postgres-tds-fdw-debian

By stano

Updated over 7 years ago

Image
0

165

stano/postgres-tds-fdw-debian repository overview

Dockerfile
FROM postgres:9.6

ENV POSTGIS_MAJOR 2.5
ENV POSTGIS_VERSION 2.5.1+dfsg-1.pgdg90+1

RUN apt-get update \
      && apt-cache showpkg postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR \
      && apt-get install -y --no-install-recommends \
           postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR=$POSTGIS_VERSION \
           postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR-scripts=$POSTGIS_VERSION \
	   postgresql-server-dev-$PG_MAJOR \
           postgis=$POSTGIS_VERSION \
      && rm -rf /var/lib/apt/lists/*

RUN echo 'deb http://ftp.de.debian.org/debian stretch main' >>/etc/apt/sources.list \
	&& apt-get update
RUN apt-get install -y \
	make \
	autoconf \
	libtool \
	pkgconf \
	gettext \
	wget \
	git \
	libsybdb5 \
	vim \
	sudo \
      && rm -rf /var/lib/apt/lists/*
RUN wget -O freetds.tar.gz "ftp://ftp.freetds.org/pub/freetds/stable/freetds-patched.tar.gz" \
	&& mkdir -p /usr/src/freetds \
	&& tar \
		--extract \
		--file freetds.tar.gz \
		--strip-components 1 \
		--directory /usr/src/freetds \
	&& rm freetds.tar.gz \
	&& cd /usr/src/freetds \
	&& ./autogen.sh \
	&& ./configure \
	&& make \
	&& make install \
	&& rm -fR /usr/src/freetds* \
	&& cd /
#	&& apk del .fetch-deps .build-deps .build-deps-edge
#RUN cd /usr/src \
#	&& git clone --single-branch --branch 1.0 https://github.com/tds-fdw/tds_fdw.git \
RUN cd /usr/src \
       && git clone --single-branch --branch master https://github.com/tds-fdw/tds_fdw.git \
	&& cd tds_fdw \
	&& make USE_PGXS=1 \
	&& make USE_PGXS=1 install \
	&& rm -fR /usr/src/tds_fdw \
        && cd /

USER postgres
#COPY ./.freetds.conf /var/lib/postgresql/.freetds.conf

RUN mkdir -p /docker-entrypoint-initdb.d
COPY ./initdb-postgis.sh /docker-entrypoint-initdb.d/postgis.sh
COPY ./update-postgis.sh /usr/local/bin

Tag summary

Content type

Image

Digest

Size

313.1 MB

Last updated

over 7 years ago

docker pull stano/postgres-tds-fdw-debian