From 7aa2d701145e47a26f103500b469e9e62b8fc7ad Mon Sep 17 00:00:00 2001 From: Roy Lenferink Date: Tue, 10 Oct 2023 18:58:51 +0200 Subject: [PATCH] Update container usage documentation --- README.md | 1 + container/README.md | 53 +++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 54 insertions(+) create mode 100644 container/README.md diff --git a/README.md b/README.md index e3b625e16..f2d408b34 100644 --- a/README.md +++ b/README.md @@ -21,6 +21,7 @@ limitations under the License. ![Celix MacOS](https://github.com/apache/celix/workflows/Celix%20MacOS/badge.svg) [![codecov](https://codecov.io/gh/apache/celix/branch/master/graph/badge.svg)](https://codecov.io/gh/apache/celix) [![Coverity Scan Build Status](https://scan.coverity.com/projects/6685/badge.svg)](https://scan.coverity.com/projects/6685) +[![Gitpod ready-to-code](https://img.shields.io/badge/Gitpod-ready--to--code-blue?logo=gitpod)](https://gitpod.io/#https://github.com/apache/celix) Apache Celix is a framework for C, C++14 and C++17 to develop dynamic modular software applications using component and in-process service-oriented programming. diff --git a/container/README.md b/container/README.md new file mode 100644 index 000000000..2c6630ffd --- /dev/null +++ b/container/README.md @@ -0,0 +1,53 @@ +# Celix dev container usage + +This subdirectory contains a [Containerfile](./Containerfile.gitpod) for developing on Celix locally or via Gitpod. +Since the image is based on the Gitpod workspace image, it is also usable via https://gitpod.io/#https://github.com/apache/celix + +The below steps only need to be executed if you want to develop locally, and not via Gitpod. + +## Using a pre-built image + +### Start locally with sshd daemon + +```bash +cd + +# Start a local container with the SSH daemon running +./container/start-gitpod-container.sh +``` + +Now connect to the container via the remote container option of your favoured IDE and start building/developing. + +### Start locally with only a bash shell + +The start script allows passing of additional paramters, which will override the starting of the SSH daemon. +Execute the following commands to open a bash shell and build Celix from the command line: + +```bash +cd + +# Start a local container and open a bash shell +./container/start-gitpod-container.sh bash + +# Build Apache Celix +mkdir celix-build +cd celix-build +../container/support-scripts/build-all.sh +make -j + +# Run the unit tests for Apache Celix +ctest --output-on-failure +``` + +## Build the celix-dev image yourself + +```bash +podman build -t docker.io/apache/celix-dev:$(date +%Y%m%d)-gitpod -f Containerfile.gitpod . +``` + +## Deploy a new celix-dev image (Celix PMC members only) + +```bash +podman login docker.io +podman push docker.io/apache/celix-dev:$(date +%Y%m%d)-gitpod +```