| 
									
										
										
										
											2020-09-09 16:10:19 +00:00
										 |  |  | ARG ALPINE_VERSION=3.12.0
 | 
					
						
							| 
									
										
										
										
											2019-06-17 09:01:30 +00:00
										 |  |  | FROM alpine:${ALPINE_VERSION}
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-09-09 16:10:19 +00:00
										 |  |  | RUN apk add --no-cache git python3 python3-dev py-pip
 | 
					
						
							| 
									
										
										
										
											2018-12-19 12:29:25 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  | # build wheels in first image
 | 
					
						
							|  |  |  | ADD . /tmp/src
 | 
					
						
							| 
									
										
										
										
											2019-09-08 08:08:15 +00:00
										 |  |  | # restore the hooks directory so that the repository isn't marked as dirty
 | 
					
						
							|  |  |  | RUN cd /tmp/src && git clean -xfd && git checkout -- hooks && git status
 | 
					
						
							| 
									
										
										
										
											2018-12-19 12:29:25 +00:00
										 |  |  | RUN mkdir /tmp/wheelhouse \
 | 
					
						
							|  |  |  |  && cd /tmp/wheelhouse \
 | 
					
						
							| 
									
										
										
										
											2019-06-17 09:01:30 +00:00
										 |  |  |  && pip3 install wheel \
 | 
					
						
							| 
									
										
										
										
											2019-09-06 10:26:56 +00:00
										 |  |  |  && pip3 wheel --no-cache-dir /tmp/src \
 | 
					
						
							|  |  |  |  && ls -l /tmp/wheelhouse
 | 
					
						
							| 
									
										
										
										
											2018-12-19 12:29:25 +00:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2019-06-17 09:01:30 +00:00
										 |  |  | FROM alpine:${ALPINE_VERSION}
 | 
					
						
							| 
									
										
										
										
											2018-12-19 12:29:25 +00:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-09-09 16:10:19 +00:00
										 |  |  | # install python, git, bash, mercurial
 | 
					
						
							|  |  |  | RUN apk add --no-cache git git-lfs python3 py-pip bash docker mercurial
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-09-10 19:48:46 +00:00
										 |  |  | # install hg-evolve (Mercurial extensions)
 | 
					
						
							| 
									
										
										
										
											2020-09-09 16:10:19 +00:00
										 |  |  | RUN pip3 install hg-evolve --user --no-cache-dir
 | 
					
						
							| 
									
										
										
										
											2018-12-19 12:29:25 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  | # install repo2docker
 | 
					
						
							|  |  |  | COPY --from=0 /tmp/wheelhouse /tmp/wheelhouse
 | 
					
						
							| 
									
										
										
										
											2019-09-06 10:26:56 +00:00
										 |  |  | RUN pip3 install --no-cache-dir /tmp/wheelhouse/*.whl \
 | 
					
						
							|  |  |  |  && pip3 list
 | 
					
						
							| 
									
										
										
										
											2018-12-19 12:29:25 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  | # add git-credential helper
 | 
					
						
							|  |  |  | COPY ./docker/git-credential-env /usr/local/bin/git-credential-env
 | 
					
						
							|  |  |  | RUN git config --system credential.helper env
 | 
					
						
							| 
									
										
										
										
											2017-05-09 10:07:56 +00:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-01-13 12:32:17 +00:00
										 |  |  | # add entrypoint
 | 
					
						
							|  |  |  | COPY ./docker/entrypoint /usr/local/bin/entrypoint
 | 
					
						
							|  |  |  | RUN chmod +x /usr/local/bin/entrypoint
 | 
					
						
							|  |  |  | ENTRYPOINT ["/usr/local/bin/entrypoint"]
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-12-25 02:03:17 +00:00
										 |  |  | # Used for testing purpose in ports.py
 | 
					
						
							|  |  |  | EXPOSE 52000
 |