Skip to content

Releases: cloudposse/geodesic

v4.3.0 Fix excessive CPU usage introduced in v4.1.0

26 Feb 22:32
3cb2146
Compare
Choose a tag to compare

🐛 Bug Fixes

This release fixes bugs introduced in v4.1.0-rc1. Because of the excessive CPU usage bug, versions 4.1.x and 4.2.x should not be used.

Fix Excessive CPU usage, fix --solo @Nuru (#974)

what

  • Fix shell monitoring introduced in v4.1.0 #970
  • Fix --solo / ONE_SHELL=true option broken in v4.1.0 #970

why

  • Bug caused shell monitor to burn CPU busy waiting on shell exits rather than sleep and poll
  • Oversight in refactoring launch vs exec parameters left out terminal allocation for --solo option, causing Geodesic to immediately exit

Footnote

In every release, we update all unpinned packages to their latest packaged versions. These changes are not detailed here.

v4.2.1 Excessive CPU usage, do not use

25 Feb 19:18
03448f4
Compare
Choose a tag to compare
Pre-release

Do not use this version because it has the Excessive CPU usage bug. Upgrade to v4.3.0 or downgrade to v4.0.2.

🐛 Bug Fixes

Fix manual install to use APP_NAME and INSTALL_PATH properly @Nuru (#972)
  • Fix manual install to use APP_NAME and INSTALL_PATH properly @Nuru (#972)

  • Fix default app name in installation output @Nuru (#973)

    what

  • Fix manual install to use APP_NAME and INSTALL_PATH properly

why

  • When installing without the Makefile, displayed instructions and resulting install did not work

Footnote

In every release, we update all unpinned packages to their latest packaged versions. These changes are not detailed here.

v4.2.0 Fix Role Prompt, bypass buggy secrets check, add lsb_release

25 Feb 16:28
4f2eac5
Compare
Choose a tag to compare

Impotant:

Do not use this version because it has the Excessive CPU usage bug. Upgrade to v4.3.0 or downgrade to v4.0.2.

Summary

Due to moby/buildkit#5775, if you are setting CHAMBER_KMS_KEY_ALIAS in your Dockerfile, you are likely getting a warning when you build the Docker image:

 1 warning found (use docker --debug to expand):
 - SecretsUsedInArgOrEnv: Do not use ARG or ENV instructions for sensitive data (ENV "CHAMBER_KMS_KEY_ALIAS") 

To get around the spurious warning, Geodesic now lets you set CHAMBER_KMS_ALIAS in your Docker file, and will convert that value to CHAMBER_KMS_KEY_ALIAS during startup processing.

🚀 Enhancements

Fix Role Prompt, bypass buggy secrets check, add lsb_release @Nuru (#971)

what

  • Fix the script for converting the current AWS IAM role to something short and meaningful for the shell command prompt
  • Add support for converting Identity Center Permission Sets to profile names in the shell prompt
  • Support setting CHAMBER_KMS_KEY_ALIAS via CHAMBER_KMS_ALIAS
  • Add the lsb-release package to provide lsb_release

why

  • The code was buggy due too piecemeal changes resulting in unreachable code
  • Many people are using Identity Center now
  • Setting CHAMBER_KMS_KEY_ALIAS as is customary in Cloud Posse Dockerfiles triggers the SecretsUsedInArgOrEnv warning. While this is arguably a bug in the warning, this change allows concerned users to avoid the issue.
  • Some tool installation scripts require lsb_release to be already installed

references

Footnote

In every release, we update all unpinned packages to their latest packaged versions. These changes are not detailed here.

v4.1.0-rc1

20 Feb 07:02
cdf5e15
Compare
Choose a tag to compare
v4.1.0-rc1 Pre-release
Pre-release

This is a release candidate because there are a large number of changes without the corresponding large volume of testing, but we have confidence that it is an improvement over v4.0.2 in any case. Please report any feedback immediately in in the #geodesic channel in the Cloud Posse Slack workspace. (Invitations available here.)

Released as v4.1.0

https://github.com/cloudposse/geodesic/releases/tag/4.1.0

v4.1.0 Better terminal and shell process management

21 Feb 10:41
cdf5e15
Compare
Choose a tag to compare

Important

  • Do not use this version because it introduced a bug causing Excessive CPU. Upgrade to v4.3.0 or downgrade to v4.0.2.
  • This release also broke the --solo / ONE_SHELL=true option, which is also fixed in v4.3.0

Reminder

Geodesic is both a Docker image and a launch wrapper script. Often you can just update the image without updating the script. In this release, the script has changed greatly, and you must install the new script to work with the new image. (This does not affect CI/CD systems that always use the script without the wrapper.)

Changes of Greatest Note:

  • Automatic detection of changes in the terminal's light/dark theme has been disabled by default and should be considered experimental. Manually update the theme by using set-terminal-theme [light | dark] if desired. Geodesic still tries to detect the theme when the shell is first launched, and this appears to be reasonably reliable.
  • Significant internal changes have been made regarding configuring the shells launched into the container. Whereas previously the first shell set defaults and subsequent shells could change very little, now each shell can configure its own environment to the extent the configuration is not considered part of the launch configuration (such as attaching volumes).
  • Internal changes have been made with regard to tracking shells so that the container exits promptly when the last shell exits and not before. This should make the process of quitting the shells and stopping the container faster and more reliable.
  • Previously, you had to use a configuration override if you wanted to keep TF_PLUGIN_CACHE_DIR from being set. Geodesic respects your setting, but if unset, Geodesic sets it to "${HOME}/.terraform.d/plugin-cache". To preserve backward compatibility, it is still set if left unset, but now if you set it to "false" or "disabled" Geodesic will unset it for you.

🚀 Enhancements and 🐛 Bug fixes

what

  • Better detection of terminal color settings at startup
  • Added --light and --dark command line options to manually set terminal theme
  • By default, disable attempt to detect terminal theme changes while running
  • Make a better separation between settings that only affect the container when it launches and settings that can vary from exec'd shell to shell
  • Correlate shells exec'd into the container with their wrapper processes
  • Make detection of tracked shells much more efficient
  • Provide an opt-out mechanism for setting TF_PLUGIN_CACHE_DIR
why

why

  • Because of a lack of consistent implementation of features in terminal emulators, automatically determining the terminal's appearance (e.g. light/dark theme) requires a case-by-case approach. Our implementation of the OSC protocol was basically correct, but did not account for the wide variations seen in practice. We now outsource this to the terminal-colorsaurus library, which is much further along in handling all the quirks.
  • Mechanisms to detect changes in the appearance of a terminal while the shell is running are not even close to be standardized. Our attempts frequently failed. This feature has now been marked experimental and disabled by default because it does not work acceptably well and is not something we want to invest in.
  • Geodesic now has a large number of settings. Many of them only affect the launch of the container (such as what volumes to mount and where). However, many of them can and should be allowed to vary from shell to shell in the same container (e.g. TERM). Previously, Geodesic mainly limited configuration to the launch of the container, and forced later shells to inherit that launch configuration. Now, to the extent practical, each shell can have different settings.
  • Now that the Geodesic container can remain running after the initial shell exits, it becomes important to track the shells so that the container exits when and only when all shells have exited. The v4.0.0 implementation suffered from not being able to distinguish the shell the wrapper launched from the shells other wrappers launched, nor could it tell the shells launched by docker exec and the shells launch by other shells, and therefore it could not reliably report on the status of the container. Now each shell is matched with its wrapper process, and the shell monitor tracks shells according to whether or not they were launched by docker exec, making the whole process much more reliable and efficient.
  • Cloud Posse highly recommends that Terraform users take advantage of the Terraform Provider Plugin Cache, and so Geodesic has been configuring it by setting the TF_PLUGIN_CACHE_DIR environment variable to a location on the host filesystem since the feature first became available. However, the cache does not have any protection against parallel modifications, so it is not always appropriate. Previously, Geodesic did not provide a good way to opt out of having the cache configured. Now you can set TF_PLUGIN_CACHE_DIR to "false" or "disabled" and Geodesic will honor that by unsetting the variable (leaving Terraform with its default non-caching behavior) rather than forcing you into using a cache.

references

Footnote

In every release, we update all unpinned packages to their latest packaged versions. These changes are not detailed here.

v4.0.2

12 Feb 03:30
35c47fe
Compare
Choose a tag to compare

what

  • Move update of terminal color mode from signal handler to prompt command
  • Fix typo in README (thanks @petabook)
  • Rename os/alpine/requirements.txt -> os/alpine/requirements-Alpine-disabled.txt
  • Allow the --workspace command-line option to use = or space, e.g. --workspace=$HOME/dev or --workspace $HOME/dev

why

  • Fixes #967
  • Fixes and supersedes #966 (which did not regenerate README.md)
  • The Alpine implementation is obsolete but being kept for reference and historical context, how ever Dependabot keeps trying to update it with security patches. This removes one source of unnecessary updates.
  • Better user experience

Footnote

In every release, we update all unpinned packages to their latest packaged versions. These changes are not detailed here.

v4.0.1

06 Feb 20:37
73778fa
Compare
Choose a tag to compare

🚀 Enhancements

Fix wrapper to be compatible with macOS' `bash` 3.2 @Nuru (#965)

what

  • Fix wrapper to be compatible with bash 3.2

why

  • bash 3.2 was the last GPL licensed version and is what ships with macOS

references

Add extra caution to terminal color detection @Nuru (#963)

what

  • Add extra safeguards when querying terminal for color status

why

  • Handle more unusual cases
  • Reduce duplication of code

🏗️ Build/Release Maintenance

Better default for`APP_NAME` @Nuru (#963)

what

  • Update demo gif
  • Prefer NAMESPACE (if set) to basename $DOCKER_IMAGE as default for APP_NAME

why

  • Better reflect common usage

Footnote

In every release, we update all unpinned packages to their latest packaged versions. These changes are not detailed here.

v4.0.0

31 Jan 21:40
ffb16cc
Compare
Choose a tag to compare

Geodesic version 4 is a major release, with breaking changes and significant new features. (PR #961)

Please read the Release Notes for more details.

If you had customized your derivative of Geodesic to work with Spacelift, please pay special attention to the "Special notes for Spacelift Users" in the Breaking Changes section of the release notes. It has not been tested with Atlantis, as we no longer officially support it.

Highlights

Breaking Changes

Although we recommend a thorough review of the Breaking Changes in the referenced Release Notes, for most users, we expect no action will be needed to switch from Geodesic v3 to v4. The breaking changes generally only affect people who have heavily customized Geodesic, or who are using Geodesic to run Atlantis or Spacelift.

Geodesic configuration files previously had to be placed under $HOME/.geodesic. The can remain there indefinitely, but now they may alternatively be placed in $XDG_CONFIG_HOME/geodesic (defaults to $HOME/.config/geodesic). If any are found there, then anything under $HOME/.geodesic will be ignored.

Previously, preferences and overrides files (and the preferences.d directory) could be placed directly in the Geodesic configuration directory. Now they must be placed in the defaults subdirectory (e.g. $XDG_CONFIG_HOME/geodesic/defaults/) or a Docker image-specific subdirectory. The history file is the only file that can be placed directly in the configuration directory.

Because Geodesic needs to locate the configuration files before it can read them for configuration, you cannot configure where the configuration files are located other than by setting $XDG_CONFIG_HOME.

Geodesic always mounts the current working directory from the host into the container. Previously, it also mounted the host's $HOME directory into the container as well. It no longer does that, because that can cause significant performance issues. (For example, on macOS, Docker's virtual disk is (several levels) under the $HOME directory, causing perpetual changes to be synced.) So do not launch Geodesic from your $HOME directory. Change to the root of your source directory first and launch it from there. (Even better, set WORKSPACE_FOLDER_HOST_DIR to the root of your source directory in launch-options.sh.)

New Features

Again, there is a lot more information in the Release Notes, and also updated documentation about customization and new documentation about Geodesic's configuration via environment variables. We list here only some of the more significant changes.

  • Exiting the first shell that launched Geodesic no longer kills all the other running shells. Fixes #774
  • By default, running the geodesic command multiple times will launch multiple shells into the same container. Now you have the option (--solo, ONE_SHELL=true) of launching each shell into a separate container.
  • If you are running multiple shells in one container (the default), you can no longer detach from the shell using Ctrl-P,Ctrl-Q (or your customized detachKeys setting). This is for 2 reasons. First, there is no way to reattach to a shell once detached from it, and second, Ctrl-P is used in command-line editing, and allowing it to be used as part of a detach sequence interferes with that.
  • While previously there were multiple options for customizing the Geodesic shell, there had been no options other than setting shell environment variables for customizing the launch of the Geodesic Docker container itself. Now you can create a launch-options.sh file to configure the launch without having to pollute all your shells with extra environment variables.
  • geodesic help lists the major command-line options. Environment variables can also be set on the command line using the format --var=value.
  • geodesic stop cleanly shuts down all the shells in the container, then the container itself. Much preferable to docker kill.
  • Geodesic shells now exit cleanly in most cases, meaning you can run scripts inside Geodesic on exit via trap script EXIT.
  • New hooks have been added to the wrapper to run on shell exit or on container exit, based on the wrapper's view of what happened when it exits. It is not foolproof, but it can be handy for things like updating window titles where it is not a big issue if they are not run or are run at the wrong time.

4.0.0-rc6

24 Jan 23:58
0dffaba
Compare
Choose a tag to compare
4.0.0-rc6 Pre-release
Pre-release

This is a release candidate for Geodesic v4. Please try it out and let us know what you think in the #geodesic channel in the Cloud Posse Slack workspace. (Invitations available here.)

Read about the new features and breaking changes in the Release Notes.

4.0.0-rc5

20 Jan 08:41
6e637c2
Compare
Choose a tag to compare
4.0.0-rc5 Pre-release
Pre-release

This is a release candidate for Geodesic v4. Please try it out and let us know what you think in the #geodesic channel in the Cloud Posse Slack workspace. (Invitations available here.)

Read about the new features and breaking changes in the Release Notes.