Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitb0d084f

Browse files
committed
Use pg10 for custom container
1 parent0967d41 commitb0d084f

File tree

2 files changed

+21
-18
lines changed

2 files changed

+21
-18
lines changed

‎.travis.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,6 @@ env:
2626
-DOCKER_IMAGE=pathman/pg10_clang_check_code
2727
-DOCKER_IMAGE=pathman/pg10_cppcheck
2828
-DOCKER_IMAGE=pathman/pg10_pathman_tests
29-
-DOCKER_IMAGE=pathman/pg96_ca_clang_check_code
30-
-DOCKER_IMAGE=pathman/pg96_ca_cppcheck
31-
-DOCKER_IMAGE=pathman/pg96_ca_pathman_tests
29+
-DOCKER_IMAGE=pathman/pg10_ca_clang_check_code
30+
-DOCKER_IMAGE=pathman/pg10_ca_cppcheck
31+
-DOCKER_IMAGE=pathman/pg10_ca_pathman_tests

‎make_images.py

Lines changed: 18 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -10,21 +10,20 @@
1010
fromurllib.requestimporturlopen
1111

1212
DOCKER_ID='pathman'
13-
ALPINE_BASE_URL='https://raw.githubusercontent.com/docker-library/postgres/master/9.6/alpine/'
13+
ALPINE_BASE_URL='https://raw.githubusercontent.com/docker-library/postgres/master/10/alpine/'
1414
ALPINE_ENTRYPOINT='docker-entrypoint.sh'
1515
ALPINE_PATCH=b'''
16-
diff --git a/Dockerfile b/Dockerfile
17-
index 9878023..ba215bc 100644
18-
--- a/Dockerfile
19-
+++ b/Dockerfile
20-
@@ -80,6 +80,7 @@ RUN set -ex\\
21-
# configure options taken from:
22-
# https://anonscm.debian.org/cgit/pkg-postgresql/postgresql.git/tree/debian/rules?h=9.5
23-
&& ./configure\\
16+
--- Dockerfile2017-07-25 12:43:20.424984422 +0300
17+
+++ Dockerfile2017-07-25 12:46:10.279267520 +0300
18+
@@ -86,6 +86,7 @@
19+
--enable-integer-datetimes\\
20+
--enable-thread-safety\\
21+
--enable-tap-tests\\
2422
+--enable-cassert\\
25-
--build="$gnuArch"\\
26-
# "/usr/src/postgresql/src/backend/access/common/tupconvert.c:105: undefined reference to `libintl_gettext'"
27-
#--enable-nls\\
23+
# skip debugging info -- we want tiny size instead
24+
#--enable-debug\\
25+
--disable-rpath\\
26+
2827
'''
2928
CUSTOM_IMAGE_NAME="%s/postgres_stable"%DOCKER_ID
3029

@@ -34,16 +33,20 @@ def make_alpine_image(image_name):
3433

3534
withtempfile.TemporaryDirectory()astmpdir:
3635
print("Creating build in %s"%tmpdir)
36+
patch_name=os.path.join(tmpdir,"cassert.patch")
37+
3738
withopen(os.path.join(tmpdir,'Dockerfile'),'w')asf:
3839
f.write(dockerfile.decode())
3940

4041
withopen(os.path.join(tmpdir,ALPINE_ENTRYPOINT),'w')asf:
4142
f.write(entrypoint_sh.decode())
4243

43-
withopen(os.path.join(tmpdir,'cassert.patch'),'w')asf:
44+
withopen(patch_name,'w')asf:
4445
f.write(ALPINE_PATCH.decode())
4546

46-
subprocess.check_output(["git","apply","cassert.patch"],cwd=tmpdir)
47+
withopen(patch_name,'r')asf:
48+
p=subprocess.Popen(["patch","-p0"],cwd=tmpdir,stdin=subprocess.PIPE)
49+
p.communicate(str.encode(f.read()))
4750
print("patch applied")
4851
subprocess.check_output(["docker","build",".",'-t',image_name],cwd=tmpdir)
4952
print("build ok: ",image_name)
@@ -57,7 +60,7 @@ def make_alpine_image(image_name):
5760
('pg95','postgres:9.5-alpine'),
5861
('pg96','postgres:9.6-alpine'),
5962
('pg10','postgres:10-alpine'),
60-
('pg96_ca',CUSTOM_IMAGE_NAME),
63+
('pg10_ca',CUSTOM_IMAGE_NAME),
6164
]
6265

6366
image_types= {

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp