File tree Expand file tree Collapse file tree 18 files changed +110
-87
lines changed Expand file tree Collapse file tree 18 files changed +110
-87
lines changed Original file line number Diff line number Diff line change @@ -62,6 +62,7 @@ COPY --from=go_builder /usr/local/bin/extension-installer /usr/local/bin
62
62
COPY --from=go_builder /usr/local/bin/pgbackrest /usr/local/bin/
63
63
COPY --from=go_builder /licenses /licenses
64
64
COPY build/postgres-operator/install-extensions.sh /usr/local/bin
65
+ COPY build/postgres-operator/relocate-extensions.sh /usr/local/bin
65
66
COPY build/postgres-operator/init-entrypoint.sh /usr/local/bin
66
67
COPY build/postgres-operator/postgres-entrypoint.sh /usr/local/bin
67
68
COPY build/postgres-operator/postgres-liveness-check.sh /usr/local/bin
Original file line number Diff line number Diff line change @@ -9,3 +9,4 @@ install -o "$(id -u)" -g "$(id -g)" -m 0755 -D "/usr/local/bin/pgbackrest" "${CR
9
9
install -o " $( id -u) " -g " $( id -g) " -m 0755 -D " /usr/local/bin/postgres-entrypoint.sh" " ${CRUNCHY_BINDIR} /bin/postgres-entrypoint.sh"
10
10
install -o " $( id -u) " -g " $( id -g) " -m 0755 -D " /usr/local/bin/postgres-liveness-check.sh" " ${CRUNCHY_BINDIR} /bin/postgres-liveness-check.sh"
11
11
install -o " $( id -u) " -g " $( id -g) " -m 0755 -D " /usr/local/bin/postgres-readiness-check.sh" " ${CRUNCHY_BINDIR} /bin/postgres-readiness-check.sh"
12
+ install -o " $( id -u) " -g " $( id -g) " -m 0755 -D " /usr/local/bin/relocate-extensions.sh" " ${CRUNCHY_BINDIR} /bin/relocate-extensions.sh"
Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+ set -e
3
+
4
+ PG_EXTENSIONS_DIR=/usr/pgsql-${PG_VERSION} /share/extension
5
+ PG_LIB_DIR=/usr/pgsql-${PG_VERSION} /lib
6
+
7
+ PGDATA_EXTENSIONS_DIR=/pgdata/extension/${PG_VERSION} /usr/pgsql-${PG_VERSION} /share/extension
8
+ PGDATA_LIB_DIR=/pgdata/extension/${PG_VERSION} /usr/pgsql-${PG_VERSION} /lib
9
+
10
+ mkdir -p " ${PGDATA_EXTENSIONS_DIR} "
11
+ mkdir -p " ${PGDATA_LIB_DIR} "
12
+
13
+ cp -r " ${PG_EXTENSIONS_DIR} " /* " ${PGDATA_EXTENSIONS_DIR} /"
14
+ cp -r " ${PG_LIB_DIR} " /* " ${PGDATA_LIB_DIR} /"
Original file line number Diff line number Diff line change @@ -19,13 +19,17 @@ spec:
19
19
template :
20
20
spec :
21
21
initContainers :
22
+ - command :
23
+ - /usr/local/bin/init-entrypoint.sh
22
24
- name : postgres-startup
23
25
- command :
24
- - /usr/local /bin/relocate-extensions.sh
26
+ - /opt/crunchy /bin/relocate-extensions.sh
25
27
resources : {}
26
28
volumeMounts :
27
29
- mountPath : /pgdata
28
30
name : postgres-data
31
+ - mountPath : /opt/crunchy
32
+ name : crunchy-bin
29
33
- mountPath : /tmp
30
34
name : tmp
31
35
- command :
56
60
- name : postgres-data
57
61
- mountPath : /tmp
58
62
name : tmp
59
- - command :
60
- - /usr/local/bin/init-entrypoint.sh
61
63
- name : nss-wrapper-init
62
64
status :
63
65
observedGeneration : 2
Original file line number Diff line number Diff line change @@ -19,13 +19,17 @@ spec:
19
19
template :
20
20
spec :
21
21
initContainers :
22
+ - command :
23
+ - /usr/local/bin/init-entrypoint.sh
22
24
- name : postgres-startup
23
25
- command :
24
- - /usr/local /bin/relocate-extensions.sh
26
+ - /opt/crunchy /bin/relocate-extensions.sh
25
27
resources : {}
26
28
volumeMounts :
27
29
- mountPath : /pgdata
28
30
name : postgres-data
31
+ - mountPath : /opt/crunchy
32
+ name : crunchy-bin
29
33
- mountPath : /tmp
30
34
name : tmp
31
35
- command :
56
60
- name : postgres-data
57
61
- mountPath : /tmp
58
62
name : tmp
59
- - command :
60
- - /usr/local/bin/init-entrypoint.sh
61
63
- name : nss-wrapper-init
62
64
status :
63
65
observedGeneration : 2
Original file line number Diff line number Diff line change 1
1
apiVersion : kuttl.dev/v1beta1
2
2
kind : TestAssert
3
- timeout : 180
3
+ timeout : 240
4
4
---
5
5
kind : StatefulSet
6
6
apiVersion : apps/v1
@@ -19,15 +19,19 @@ spec:
19
19
template :
20
20
spec :
21
21
initContainers :
22
+ - command :
23
+ - /usr/local/bin/init-entrypoint.sh
22
24
- name : postgres-startup
23
25
- command :
24
- - /usr/local /bin/relocate-extensions.sh
26
+ - /opt/crunchy /bin/relocate-extensions.sh
25
27
env :
26
28
- name : PG_VERSION
27
29
resources : {}
28
30
volumeMounts :
29
31
- mountPath : /pgdata
30
32
name : postgres-data
33
+ - mountPath : /opt/crunchy
34
+ name : crunchy-bin
31
35
- mountPath : /tmp
32
36
name : tmp
33
37
- command :
58
62
- name : postgres-data
59
63
- mountPath : /tmp
60
64
name : tmp
61
- - command :
62
- - /usr/local/bin/init-entrypoint.sh
63
65
- name : nss-wrapper-init
64
66
status :
65
67
observedGeneration : 3
Original file line number Diff line number Diff line change @@ -19,13 +19,13 @@ spec:
19
19
template :
20
20
spec :
21
21
initContainers :
22
+ - command :
23
+ - /usr/local/bin/init-entrypoint.sh
22
24
- name : postgres-startup
23
25
- command :
24
- - /usr/local /bin/relocate-extensions.sh
26
+ - /opt/crunchy /bin/relocate-extensions.sh
25
27
- command :
26
28
- /usr/local/bin/install-extensions.sh
27
- - command :
28
- - /usr/local/bin/init-entrypoint.sh
29
29
- name : nss-wrapper-init
30
30
status :
31
31
observedGeneration : 3
Original file line number Diff line number Diff line change @@ -19,15 +19,11 @@ spec:
19
19
template :
20
20
spec :
21
21
initContainers :
22
+ - command :
23
+ - /usr/local/bin/init-entrypoint.sh
22
24
- name : postgres-startup
23
25
- command :
24
- - /usr/local/bin/relocate-extensions.sh
25
- resources : {}
26
- volumeMounts :
27
- - mountPath : /pgdata
28
- name : postgres-data
29
- - mountPath : /tmp
30
- name : tmp
26
+ - /opt/crunchy/bin/relocate-extensions.sh
31
27
- command :
32
28
- /usr/local/bin/install-extensions.sh
33
29
env :
52
48
- name : postgres-data
53
49
- mountPath : /tmp
54
50
name : tmp
55
- - command :
56
- - /usr/local/bin/init-entrypoint.sh
57
51
- name : nss-wrapper-init
58
52
status :
59
53
observedGeneration : 5
Original file line number Diff line number Diff line change @@ -19,15 +19,11 @@ spec:
19
19
template :
20
20
spec :
21
21
initContainers :
22
+ - command :
23
+ - /usr/local/bin/init-entrypoint.sh
22
24
- name : postgres-startup
23
25
- command :
24
- - /usr/local/bin/relocate-extensions.sh
25
- resources : {}
26
- volumeMounts :
27
- - mountPath : /pgdata
28
- name : postgres-data
29
- - mountPath : /tmp
30
- name : tmp
26
+ - /opt/crunchy/bin/relocate-extensions.sh
31
27
- command :
32
28
- /usr/local/bin/install-extensions.sh
33
29
env :
52
48
- name : postgres-data
53
49
- mountPath : /tmp
54
50
name : tmp
55
- - command :
56
- - /usr/local/bin/init-entrypoint.sh
57
51
- name : nss-wrapper-init
58
52
status :
59
53
observedGeneration : 5
Original file line number Diff line number Diff line change @@ -19,15 +19,11 @@ spec:
19
19
template :
20
20
spec :
21
21
initContainers :
22
+ - command :
23
+ - /usr/local/bin/init-entrypoint.sh
22
24
- name : postgres-startup
23
25
- command :
24
- - /usr/local/bin/relocate-extensions.sh
25
- resources : {}
26
- volumeMounts :
27
- - mountPath : /pgdata
28
- name : postgres-data
29
- - mountPath : /tmp
30
- name : tmp
26
+ - /opt/crunchy/bin/relocate-extensions.sh
31
27
- command :
32
28
- /usr/local/bin/install-extensions.sh
33
29
env :
52
48
- name : postgres-data
53
49
- mountPath : /tmp
54
50
name : tmp
55
- - command :
56
- - /usr/local/bin/init-entrypoint.sh
57
51
- name : nss-wrapper-init
58
52
status :
59
53
observedGeneration : 6
You can’t perform that action at this time.
0 commit comments