Skip to content

Commit 2239033

Browse files
authoredDec 24, 2024··
[source-postgres] make source-postgres work with non-root base image (#50410)
This patch starts using non-root base image for postgres. To do so, we have to save the SSL key to "/tmp" instead of ""
1 parent 21c8774 commit 2239033

File tree

9 files changed

+305
-301
lines changed

9 files changed

+305
-301
lines changed
 

‎airbyte-cdk/java/airbyte-cdk/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,7 @@ corresponds to that version.
174174

175175
| Version | Date | Pull Request | Subject |
176176
|:-----------|:-----------|:------------------------------------------------------------|:---------------------------------------------------------------------------------------------------------------------------------------------------------------|
177+
| 0.48.4 | 2024-12-24 | [\#50410](https://github.com/airbytehq/airbyte/pull/50410) | Save SSL key to /tmp |
177178
| 0.48.3 | 2024-12-23 | [\#49858](https://github.com/airbytehq/airbyte/pull/49858) | Relax various Destination CDK methods visibility. |
178179
| 0.48.1 | 2024-11-13 | [\#48482](https://github.com/airbytehq/airbyte/pull/48482) | Adding support converting very large numbers via BigInteger |
179180
| 0.48.0 | 2024-10-23 | [\#46302](https://github.com/airbytehq/airbyte/pull/46302) | Add support for file transfer |

‎airbyte-cdk/java/airbyte-cdk/core/src/main/kotlin/io/airbyte/cdk/db/util/SSLCertificateUtils.kt

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ object SSLCertificateUtils {
5050
directory: String?
5151
): URI {
5252
val fs = Objects.requireNonNullElse(filesystem, FileSystems.getDefault())
53-
val pathToStore = fs!!.getPath(Objects.toString(directory, ""))
53+
val pathToStore = fs!!.getPath(Objects.toString(directory, "/tmp"))
5454
val pathToFile =
5555
pathToStore.resolve(KEYSTORE_FILE_NAME + RANDOM.nextInt() + KEYSTORE_FILE_TYPE)
5656
val os = Files.newOutputStream(pathToFile)
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
version=0.48.3
1+
version=0.48.4

‎airbyte-ci/connectors/pipelines/README.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -853,7 +853,8 @@ airbyte-ci connectors --language=low-code migrate-to-manifest-only
853853
## Changelog
854854

855855
| Version | PR | Description |
856-
| ------- | ---------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- |
856+
|---------|------------------------------------------------------------| ---------------------------------------------------------------------------------------------------------------------------- |
857+
| 4.48.1 | [#50410](https://github.com/airbytehq/airbyte/pull/50410) | Java connector build: give ownership of built artifacts to the current image user. |
857858
| 4.48.0 | [#49960](https://github.com/airbytehq/airbyte/pull/49960) | Deprecate airbyte-ci format command |
858859
| 4.47.0 | [#49832](https://github.com/airbytehq/airbyte/pull/49462) | Build java connectors from the base image declared in `metadata.yaml`. |
859860
| 4.46.5 | [#49835](https://github.com/airbytehq/airbyte/pull/49835) | Fix connector language discovery for projects with Kotlin Gradle build scripts. |

‎airbyte-ci/connectors/pipelines/pipelines/dagger/containers/java.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -183,10 +183,11 @@ async def with_airbyte_java_connector(context: ConnectorContext, connector_java_
183183
)
184184
base = with_integration_base_java(context, build_platform).with_entrypoint(["/airbyte/base.sh"])
185185

186+
current_user = (await base.with_exec(["whoami"]).stdout()).strip()
186187
connector_container = (
187188
base.with_workdir("/airbyte")
188189
.with_env_variable("APPLICATION", application)
189-
.with_mounted_directory("built_artifacts", build_stage.directory("/airbyte"))
190+
.with_mounted_directory("built_artifacts", build_stage.directory("/airbyte"), owner=current_user)
190191
.with_exec(sh_dash_c(["mv built_artifacts/* ."]))
191192
)
192193
return await finalize_build(context, connector_container)

‎airbyte-ci/connectors/pipelines/pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api"
44

55
[tool.poetry]
66
name = "pipelines"
7-
version = "4.48.0"
7+
version = "4.48.1"
88
description = "Packaged maintained by the connector operations team to perform CI for connectors' pipelines"
99
authors = ["Airbyte <contact@airbyte.io>"]
1010

‎airbyte-integrations/connectors/source-postgres/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ java {
1212
}
1313

1414
airbyteJavaConnector {
15-
cdkVersionRequired = '0.48.2'
15+
cdkVersionRequired = '0.48.4'
1616
features = ['db-sources', 'datastore-postgres']
1717
useLocalCdk = false
1818
}

‎airbyte-integrations/connectors/source-postgres/metadata.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ data:
99
connectorSubtype: database
1010
connectorType: source
1111
definitionId: decd338e-5647-4c0b-adf4-da0e75f5a750
12-
dockerImageTag: 3.6.26
12+
dockerImageTag: 3.6.27
1313
dockerRepository: airbyte/source-postgres
1414
documentationUrl: https://docs.airbyte.com/integrations/sources/postgres
1515
githubIssueLabel: source-postgres
@@ -27,7 +27,7 @@ data:
2727
tags:
2828
- language:java
2929
connectorBuildOptions:
30-
baseImage: docker.io/airbyte/java-connector-base:1.0.0@sha256:be86e5684e1e6d9280512d3d8071b47153698fe08ad990949c8eeff02803201a
30+
baseImage: docker.io/airbyte/java-connector-base:2.0.0-rc.2@sha256:e5543b3de4c38e9ef45dba886bad5ee319b0d7bfe921f310c788f1d4466e25eb
3131
connectorTestSuitesOptions:
3232
- suite: unitTests
3333
- suite: integrationTests

‎docs/integrations/sources/postgres.md

+294-293
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)
Please sign in to comment.