8000 GitHub - pjh/konlet · GitHub
[go: up one dir, main page]

Skip to content

About

No description, website, or topics provided.

Resources

Contributing

Stars

0 stars

Watchers

0 watching

Forks

 
 

Latest commit

 

History

46 Commits

Folders and files

Repository files navigation

Compute Engine Container Startup Agent

The Compute Engine container startup agent starts a container deployed on a VM instance using Deploying Containers on VMs and Managed Instance Groups method.

The agent parses container declaration that is stored in VM instance metadata under gce-container-declaration key and starts the container with the declared configuration options.

The agent is bundled with Container-Optimized OS image, version 62 or higher.

Building the agent

Container startup agent is deployed as a Docker container and is hosted in Container Registry: gcr.io/gce-containers/konlet.

To build the agent using bazel run these commands from the repository root:

$ pushd gce-containers-startup
$ bazel build :gce-containers-startup
$ popd

Export your GCP project name to an environment variable:

$ export MY_PROJECT=your-project-name

To build a Docker image, copy the build binary to the 'docker' directory and invoke the docker build command:

$ cp gce-containers-startup/bazel-bin/gce-containers-startup docker/
$ docker build docker/ -t gcr.io/$MY_PROJECT/gce-containers-startup

To push resulting Docker image to Google Container Registry you can use gcloud command:

$ gcloud docker -- push gcr.io/$MY_PROJECT/gce-containers-startup

Usage

If you would like to install the container startup agent on your VM, copy its systemd service definition and scripts:

  • Copy systemd service definition konlet-startup.service into systemd services directory, e.g. /usr/lib/systemd/system.

  • Copy get_metadata_value script to /usr/share/google directory.

  • Copy konlet-startup script to /var/lib/google directory

You can also those scripts directly by a startup script, cloud-init or rc.d scripts.

License

Compute Engine containe 5744 r startup agent is licensed under Apache License 2.0. The license is available in the LICENSE file.

You can find out more about the Apache License 2.0 at: http://www.apache.org/licenses/LICENSE-2.0.

About

No description, website, or topics provided.

Resources

Contributing

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages

0