github getporter/porter v1.0.0-alpha.3

latest releases: canary, v1.1.1, v1.1.0...
pre-release3 years ago

Highlights

This is a big release for our v1 alpha with LOTS of major changes. This is your reminder that the v1 prerelease is not suitable for running with production workloads, and that data migrations will not be provided or supported for v1 prereleases. The prerelease is intended for you to try out the new features in Porter, and provide feedback but won't work with existing installations.

In this release we have removed support for deprecated flags and fields in porter.yaml So if you have been ignoring a warning message in Porter's output for months, now is the time to fix those messages before upgrading.

MongoDb Support

Porter now stores its data in MongoDB! We no longer store installation records on the filesystem, though we still do have a ~/.porter directory with our configuration and cache. In dev and test, Porter by default runs MongoDb in a container for you on porter 27018 and connects to it.

You can also use our mongodb storage plugin and connect to an existing MongoDB server. CosmosDB works as well, though we have a known performance problem with our CosmosDB indices that will be addressed in the next release.

default-storage = "mydb"

[[storage]]
  name = "mydb"
  plugin = "mongodb"

  [storage.config]
    url = "mongodb://username:password@host:port"

Namespaces

Porter resources such as installations, credential sets and parameter sets can optionally be defined within a namespace. Resources that are not defined in a namespace are considered global. When an installation is defined in a namespace, it can reference a credential or parameter set that is also defined in that namespace or at the global scope. Resources defined globally cannot reference other resources that are defined in a namespace.

When an installation references a parameter or credential set, Porter first looks for a resource with that name in the current namespace. If one does not exist, Porter then looks for that resource at the global level. This lets you define a common set of credentials to be used for an environment, like staging environment credentials that everyone can reuse, while allowing for overriding that resource within a particular namespace.

# list just in the current namespace defined in your porter config
porter installations list

# list in the specified namespace
porter installation list --namespace myuser

# list across all namespaces
porter installation list --all-namespaces

# list across all namespaces (alternate syntax)
porter installation list --namespace '*'

Labels

Porter resources also now support labels which may be used for filtering with the porter list commands. For example:

porter installations list --namespace myuser --label env=dev --label app=myapp

Bundle State

Bundle authors can now declare that certain files are "state" and should be preserved between bundle runs. A prime example is the tfstate and tfvars files created by the terraform mixin. Now instead of using the old method of declaring those files as both parameters and outputs, you should declare them as state and Porter will ensure that they are always available to your bundle.

This corrects the problem where if an installation that used the terraform mixin, without a remote backend configured, failed to install, on subsequent install runs the resources originally created by terraform were not recorded and reused, leaving it up to the user to manually cleanup resources. With state, when install fails and is repeated, the terraform mixin is able to pick up where it left off.

Import credentials and parameter sets

Use the apply command to import a credential or parameter set from a file.

porter credentials apply mycreds.yaml
porter credentials apply myparams.json

You can export a credential or parameter set to a file with the show command.

porter credentials show mycreds -o yaml > mycreds.yaml
porter credentials show myparams -o json > myparams.json

Breaking Changes

  • Remove deprecated tag #1718
  • remove support for deprecated fields on manifest #1633
  • Use official mongodb driver #1745

Features

  • Hide internal outputs from porter installation outputs list #1761
  • Add state section to porter.yaml #1743
  • Update bundle action commands to work with the installation record #1724
  • Include list of mixins used in porter explain and simplify explain output #1741
  • Allow repeating install when --force is specified #1726
  • Apply installation #1720
  • Add apply command for creds and params #1715
  • All namespaces #1712
  • Support labels #1701
  • Support Installation Specification #1684
  • Support DOCKER_NETWORK environment variable #1698
  • Default parameter and output types #1692

Fixes

  • Remove debug print statement #1747
  • Improve parameters loading by first trying file if not then treat as named set. #1731 by @fibonacci1729
  • Always collect outputs even when bundle fails #1728
  • chore(examples/azure-terraform): updates per forthcoming 0.8.0 release #1732
  • Update help text description of porter #1722
  • Fix bug resolving parameter sources from claim #1710
  • Fix check for if a bundle was provided #1706
  • Print help when no args are passed #1674
  • Fix applyTo check for outputs in porter explain #1668

Miscellaneous

  • Refactoring before adding reconcilation #1753
  • Bump CI environment variables on v1 branch #1751
  • Bump CI environment variables #1750
  • Add ExtendedBundle wrapper #1739
  • Move mage targets #1737
  • Remove stopped mongo #1735
  • Add Thinktecture AG to the adopters list #1721 🎉
  • Sync docs #1711
  • Fix helm download in workshop image #1713
  • docs(code): Introduce copy code feature #1697 by @thisisommore
  • faq.md updated #1679 by @sonukushwaha403
  • doc(styles): Scroll menu and main content separately #1685 by @thisisommore
  • Update credentials.md #1689 by @Jemgoss
  • Remove jsonschema fork: Bump cnab-go to v0.20.2 #1695
  • Fix go.mod entry for jsonschema #1655
  • Add shortlink for all pull requests #1694
  • Fix tag detection on azure pipelines #1670
  • Debug why example build is failing #1671
  • Add bundle use cases to homepage #1657
  • Blog: Helm v2 rename #1654
  • Document helm3 mixin #1652
  • Improve credentials documentation #1651
  • Added Porter Mixins and Plugins details in Readme.md #1640 by @DARK-art108
  • Document object parameters #1645
  • Skip publish for v1 canary and latest #1641

Install or Upgrade

We would love for you to try out v1.0.0-alpha.3 and send us any feedback that you have! Keep in mind that the v1 prerelease is not suitable for running with production workloads, and that data migrations will not be provided or supported for v1 prerelease.
The prerelease is intended for you to try out the new features in Porter, and provide feedback but won't work with existing installations.

One way to try out Porter without messing with your current installation of Porter is to install Porter into a different
PORTER_HOME directory.

MacOS

export PORTER_HOME=~/.porterv1
export VERSION="v1.0.0-alpha.3"
curl -L https://cdn.porter.sh/$VERSION/install-mac.sh | bash

Linux

PORTER_HOME=~/.porterv1
VERSION="v1.0.0-alpha.3"
curl -L https://cdn.porter.sh/$VERSION/install-linux.sh | bash

Windows

$PORTER_HOME="$env:USERPROFILE\.porterv1"
$VERSION="v1.0.0-alpha.3"
(New-Object System.Net.WebClient).DownloadFile("https://cdn.porter.sh/$VERSION/install-windows.ps1", "install-porter.ps1")
.\install-porter.ps1 -PORTER_HOME $PORTER_HOME

Now when you want to use the v1 version of Porter, set the PORTER_HOME environment variable and add it to your PATH.

Posix Shells

export PORTER_HOME=~/.porterv1
export PATH="$PORTER_HOME:$PATH"

PowerShell

$env:PORTER_HOME="$env:USERPROFILE\.porterv1"
$env:PATH+=";$env:PORTER_HOME"

Don't miss a new porter release

NewReleases is sending notifications on new releases.