Skip to content

Commit 428f90e

Browse files
authored
#152 Prepare for versioned release (#153)
1 parent a9f29ce commit 428f90e

File tree

5 files changed

+37
-9
lines changed

5 files changed

+37
-9
lines changed

CHANGELOG.md

+7
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1010

1111
-
1212

13+
## [0.4.11] - 2023-07-25
14+
15+
### Changed in 0.4.11
16+
17+
- In `Dockerfile`, added `HEALTHCHECK`
18+
- Switch default port to 8261
19+
1320
## [0.4.10] - 2023-07-25
1421

1522
### Changed in 0.4.10

Dockerfile

+3
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ LABEL Name="senzing/serve-grpc" \
6262

6363
# Copy files from repository.
6464

65+
COPY ./rootfs /
6566
COPY ./testdata/senzing-license/g2.lic /etc/opt/senzing/g2.lic
6667
COPY ./testdata/sqlite/G2C.db /tmp/sqlite/G2C.db
6768

@@ -76,5 +77,7 @@ ENV SENZING_TOOLS_DATABASE_URL=sqlite3://na:na@/tmp/sqlite/G2C.db
7677

7778
# Runtime execution.
7879

80+
HEALTHCHECK --interval=30s --timeout=30s --start-period=5s --retries=3 CMD [ "/app/healthcheck.sh" ]
81+
7982
WORKDIR /app
8083
ENTRYPOINT ["/app/serve-grpc"]

go.mod

+3-3
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ require (
77
github.com/senzing/g2-sdk-go v0.6.7
88
github.com/senzing/g2-sdk-go-base v0.2.2
99
github.com/senzing/g2-sdk-proto/go v0.0.0-20230608182106-25c8cdc02e3c
10-
github.com/senzing/go-cmdhelping v0.1.2
10+
github.com/senzing/go-cmdhelping v0.1.3
1111
github.com/senzing/go-common v0.2.6
1212
github.com/senzing/go-logging v1.3.1
1313
github.com/senzing/go-observing v0.2.6
@@ -35,11 +35,11 @@ require (
3535
github.com/spf13/jwalterweatherman v1.1.0 // indirect
3636
github.com/spf13/pflag v1.0.5 // indirect
3737
github.com/subosito/gotenv v1.4.2 // indirect
38-
golang.org/x/exp v0.0.0-20230713183714-613f0c0eb8a1 // indirect
38+
golang.org/x/exp v0.0.0-20230725093048-515e97ebf090 // indirect
3939
golang.org/x/net v0.12.0 // indirect
4040
golang.org/x/sys v0.10.0 // indirect
4141
golang.org/x/text v0.11.0 // indirect
42-
google.golang.org/genproto/googleapis/rpc v0.0.0-20230720185612-659f7aaaa771 // indirect
42+
google.golang.org/genproto/googleapis/rpc v0.0.0-20230726155614-23370e0ffb3e // indirect
4343
google.golang.org/protobuf v1.31.0 // indirect
4444
gopkg.in/ini.v1 v1.67.0 // indirect
4545
gopkg.in/yaml.v3 v3.0.1 // indirect

go.sum

+6-6
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,8 @@ github.com/senzing/g2-sdk-go-base v0.2.2 h1:zPrD5d5GNXhegbKMqwSFAB75tKyZVYVPT6cM
162162
github.com/senzing/g2-sdk-go-base v0.2.2/go.mod h1:2JRq3lI5QTzmugBiMYxiffoJBRHFEktzw2hW2785HN0=
163163
github.com/senzing/g2-sdk-proto/go v0.0.0-20230608182106-25c8cdc02e3c h1:jNOwfVczSPsD42TLj/+/Tn5CxzsPfoSpRYm+XB2iKH0=
164164
github.com/senzing/g2-sdk-proto/go v0.0.0-20230608182106-25c8cdc02e3c/go.mod h1:xAllYm5U1m8CBnK7pkn3CZ87kd3nXxEfGt2Wims4+Ic=
165-
github.com/senzing/go-cmdhelping v0.1.2 h1:F4hgE4VifwvYGRTHgdB1wWJprAGRie0aODuo2gYraeQ=
166-
github.com/senzing/go-cmdhelping v0.1.2/go.mod h1:Vp9IFch3zaUy1QXKPsMv0PLgrhJbxxWOKwgoazfpY9Y=
165+
github.com/senzing/go-cmdhelping v0.1.3 h1:zKsP3AfoJEMrs8WDKqKxfa+yG/q/Nvb5mrSXQ26AhN4=
166+
github.com/senzing/go-cmdhelping v0.1.3/go.mod h1:L8Rp66m4GM84NAenB1tFcEoj9meHhPz9FjA7ZuktsLs=
167167
github.com/senzing/go-common v0.2.6 h1:QKCbe5P77J2Ohv04RFK528Ca2yZQfbG5KDJaRhlpnsg=
168168
github.com/senzing/go-common v0.2.6/go.mod h1:6qV7VjigHkBnx/kNicAbfavg/Lt4ssPYiILsaeRHk5c=
169169
github.com/senzing/go-logging v1.3.1 h1:/isKaa+e2XQ/Mvp7z9cXxN36GvEF4sUwMQNuSBpwbTQ=
@@ -224,8 +224,8 @@ golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u0
224224
golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
225225
golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM=
226226
golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU=
227-
golang.org/x/exp v0.0.0-20230713183714-613f0c0eb8a1 h1:MGwJjxBy0HJshjDNfLsYO8xppfqWlA5ZT9OhtUUhTNw=
228-
golang.org/x/exp v0.0.0-20230713183714-613f0c0eb8a1/go.mod h1:FXUEEKJgO7OQYeo8N01OfiKP8RXMtf6e8aTskBGqWdc=
227+
golang.org/x/exp v0.0.0-20230725093048-515e97ebf090 h1:Di6/M8l0O2lCLc6VVRWhgCiApHV8MnQurBnFSHsQtNY=
228+
golang.org/x/exp v0.0.0-20230725093048-515e97ebf090/go.mod h1:FXUEEKJgO7OQYeo8N01OfiKP8RXMtf6e8aTskBGqWdc=
229229
golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
230230
golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
231231
golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
@@ -467,8 +467,8 @@ google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6D
467467
google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
468468
google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
469469
google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
470-
google.golang.org/genproto/googleapis/rpc v0.0.0-20230720185612-659f7aaaa771 h1:Z8qdAF9GFsmcUuWQ5KVYIpP3PCKydn/YKORnghIalu4=
471-
google.golang.org/genproto/googleapis/rpc v0.0.0-20230720185612-659f7aaaa771/go.mod h1:TUfxEVdsvPg18p6AslUXFoLdpED4oBnGwyqk3dV1XzM=
470+
google.golang.org/genproto/googleapis/rpc v0.0.0-20230726155614-23370e0ffb3e h1:S83+ibolgyZ0bqz7KEsUOPErxcv4VzlszxY+31OfB/E=
471+
google.golang.org/genproto/googleapis/rpc v0.0.0-20230726155614-23370e0ffb3e/go.mod h1:TUfxEVdsvPg18p6AslUXFoLdpED4oBnGwyqk3dV1XzM=
472472
google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
473473
google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38=
474474
google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=

rootfs/app/healthcheck.sh

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
#!/usr/bin/env bash
2+
3+
# Determine port.
4+
5+
DEFAULT_GRPC_PORT=8261
6+
7+
# If SENZING_TOOLS_GRPC_PORT exists, use it's value.
8+
9+
if [[ -z "${SENZING_TOOLS_GRPC_PORT}" ]]; then
10+
GRPC_PORT=${DEFAULT_GRPC_PORT}
11+
else
12+
GRPC_PORT=${SENZING_TOOLS_GRPC_PORT}
13+
fi
14+
15+
# Health check.
16+
17+
wget --no-verbose --tries=1 --spider http://localhost:${GRPC_PORT}
18+
exit $?

0 commit comments

Comments
 (0)