{"id":23613664,"url":"https://github.com/freckle/setup-platform-action","last_synced_at":"2025-05-12T21:42:00.872Z","repository":{"id":43691701,"uuid":"331357965","full_name":"freckle/setup-platform-action","owner":"freckle","description":"GitHub Action to install the Freckle Platform CLI","archived":false,"fork":false,"pushed_at":"2025-04-08T03:56:28.000Z","size":138,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":15,"default_branch":"main","last_synced_at":"2025-04-08T04:28:51.294Z","etag":null,"topics":["ghvm-managed"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/freckle.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-01-20T16:01:58.000Z","updated_at":"2025-04-08T03:56:31.000Z","dependencies_parsed_at":"2023-11-16T16:44:11.441Z","dependency_job_id":"d3875a02-b816-4d89-b8c2-7a34814f1363","html_url":"https://github.com/freckle/setup-platform-action","commit_stats":{"total_commits":48,"total_committers":1,"mean_commits":48.0,"dds":0.0,"last_synced_commit":"7786888ebea1009126d2527325e35b526b3141e3"},"previous_names":[],"tags_count":31,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/freckle%2Fsetup-platform-action","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/freckle%2Fsetup-platform-action/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/freckle%2Fsetup-platform-action/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/freckle%2Fsetup-platform-action/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/freckle","download_url":"https://codeload.github.com/freckle/setup-platform-action/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253717618,"owners_count":21952517,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ghvm-managed"],"created_at":"2024-12-27T17:18:39.193Z","updated_at":"2025-05-12T21:42:00.847Z","avatar_url":"https://github.com/freckle.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Setup Platform Action\n\nGitHub Action to install and configure our [PlatformCLI][platform] and\n[Stackctl][] tools.\n\n[platform]: https://github.com/freckle/platform\n[stackctl]: https://github.com/freckle/stackctl\n\n**NOTE**: This action is public so that we can use it outside of its own\nrepository, but the tooling it installs and uses is private. It is of no use\noutside Freckle.\n\n## Basic Usage\n\n```yaml\n- id: setup\n  uses: freckle/setup-platform-action@v7\n  with:\n    # Required\n    token: ${{ secrets.X }}\n\n    # Optional\n    # version: 3.2.2.2\n    # app-directory: my-app     # If in multi-app repository\n    # environment: prod\n    # resource: my-resource     # If in multi-resource app\n    # stackctl-version: 1.6.0.0\n```\n\nThe action installs a `platform` executable, configures `PLATFORM_*` environment\nvariables (so you can just invoke it without global options throughout the\nremainder of your workflow), and sets the `tag` output.\n\nThis can be used to build and push images,\n\n```yaml\n- run: platform container:login\n- run: platform container:push --tag '${{ steps.setup.outputs.tag }}'\n```\n\nBuild and push assets,\n\n```yaml\n- run: platform assets:push --tag '${{ steps.setup.outputs.tag }}'\n```\n\nOr deploy\n\n```yaml\n- run: platform deploy --tag '${{ steps.setup.outputs.tag }}'\n```\n\nWe also export various `SLACK_*` environment variables, so you don't have to set\nas much when notifying via the `rtCamp` action:\n\n```yaml\n- if: ${{ always() }}\n  uses: rtCamp/action-slack-notify@v2\n  env:\n    # Only this is now required\n    SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL }}\n\n    # But you probably want this too\n    SLACK_COLOR: ${{ job.status }}\n    SLACK_MESSAGE: ${{ job.status }}\n```\n\n## Stackctl\n\nThe action also installs a `stackctl` executable and configures `STACKCTL_*`\nvariables to work with the specifications generated by PlatformCLI. This means\nyou can do things like post changeset details to your PR:\n\n```yaml\n- run: |\n    # Generates content in .platform/specs\n    platform deploy --tag '${{ steps.prep.outputs.tag }}' --inspect\n\n    # Which you can work with naturally using Stackctl\n    stackctl changes --format pr /tmp/changes.md\n\n- uses: { your preferred add-pr-comment action }\n  with:\n    body-path: /tmp/changes.md\n```\n\n\u003c!-- action-docs-inputs action=\"action.yml\" --\u003e\n\n## Inputs\n\n| name                     | description                                                                                                                                                                                                                                                                                                  | required | default           |\n| ------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -------- | ----------------- |\n| `version`                | \u003cp\u003eThe version of PlatformCLI to install. Do not include the \u003ccode\u003ev\u003c/code\u003e prefix here. The default is to lookup the latest release. We recommend using this default, along with specifying a \u003ccode\u003erequired_version\u003c/code\u003e constraint (such as \u003ccode\u003e=~ 3\u003c/code\u003e) in your \u003ccode\u003e.platform.yaml\u003c/code\u003e.\u003c/p\u003e | `false`  | `\"\"`              |\n| `token`                  | \u003cp\u003eA GitHub access token with rights to fetch the private PlatformCLI release artifacts. Either this or \u003ccode\u003egithub-app-{id,private-key}\u003c/code\u003e must be given.\u003c/p\u003e                                                                                                                                          | `false`  | `\"\"`              |\n| `github-app-id`          | \u003cp\u003eProvide this (and \u003ccode\u003egithub-private-key\u003c/code\u003e) instead of \u003ccode\u003etoken\u003c/code\u003e to generate and use one from the identified App.\u003c/p\u003e                                                                                                                                                                     | `false`  | `\"\"`              |\n| `github-private-key`     | \u003cp\u003eProvide this (and \u003ccode\u003egithub-app-id\u003c/code\u003e) instead of \u003ccode\u003etoken\u003c/code\u003e to generate and use one from the identified App.\u003c/p\u003e                                                                                                                                                                          | `false`  | `\"\"`              |\n| `github-app-private-key` | \u003cp\u003eDeprecated, use github-private-key\u003c/p\u003e                                                                                                                                                                                                                                                                    | `false`  | `\"\"`              |\n| `app-directory`          | \u003cp\u003eIf present, this will be set as \u003ccode\u003ePLATFORM_APP_DIRECTORY\u003c/code\u003e for the remainder of the workflow. For details on what this affects, see \u003ccode\u003eplatform(1)\u003c/code\u003e.\u003c/p\u003e                                                                                                                                | `false`  | `\"\"`              |\n| `environment`            | \u003cp\u003eIf present, this will be set as \u003ccode\u003ePLATFORM_ENVIRONMENT\u003c/code\u003e for the remainder of the workflow. For details on what this affects, see \u003ccode\u003eplatform(1)\u003c/code\u003e.\u003c/p\u003e                                                                                                                                  | `false`  | `\"\"`              |\n| `resource`               | \u003cp\u003eIf present, this will be set as \u003ccode\u003ePLATFORM_RESOURCE\u003c/code\u003e for the remainder of the workflow. For details on what this affects, see \u003ccode\u003eplatform(1)\u003c/code\u003e.\u003c/p\u003e                                                                                                                                     | `false`  | `\"\"`              |\n| `no-validate`            | \u003cp\u003eIf present, this will be set as \u003ccode\u003ePLATFORM_NO_VALIDATE\u003c/code\u003e for the remainder of the workflow. For details on what this affects, see \u003ccode\u003eplatform(1)\u003c/code\u003e.\u003c/p\u003e                                                                                                                                  | `false`  | `\"\"`              |\n| `stackctl-version`       | \u003cp\u003eThe version of Stackctl to install. Do not include the \u003ccode\u003ev\u003c/code\u003e prefix here. The default is to lookup the latest release.\u003c/p\u003e                                                                                                                                                                       | `false`  | `\"\"`              |\n| `stackctl-directory`     | \u003cp\u003eValue to set as STACKCTL_DIRECTORY\u003c/p\u003e                                                                                                                                                                                                                                                                    | `false`  | `.platform/specs` |\n| `stackctl-filter`        | \u003cp\u003eValue to set as STACKCTL_FILTER\u003c/p\u003e                                                                                                                                                                                                                                                                       | `false`  | `\"\"`              |\n| `fetch-platform-yaml`    | \u003cp\u003eAutomatically fetch \u003ccode\u003e.platform.yaml\u003c/code\u003e via GitHub API if not present. This can be useful to avoid a checkout if all your Job needs is this file. This will always use \u003ccode\u003egithub.token\u003c/code\u003e, regardless of our own \u003ccode\u003etoken\u003c/code\u003e input.\u003c/p\u003e                                             | `false`  | `true`            |\n\n\u003c!-- action-docs-inputs action=\"action.yml\" --\u003e\n\n\u003c!-- action-docs-outputs action=\"action.yml\" --\u003e\n\n## Outputs\n\n| name    | description                                                                                                                                                                                                                                                           |\n| ------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `tag`   | \u003cp\u003eA consistent, source-specific value that should be used throughout build/push/deploy actions. It's currently the head sha for \u003ccode\u003epull_request\u003c/code\u003e events, the \"after\" sha for \u003ccode\u003epush\u003c/code\u003e events, and \u003ccode\u003egithub.sha\u003c/code\u003e for all other events\u003c/p\u003e |\n| `cache` | \u003cp\u003ePath to the \u003ccode\u003e.platform/cache\u003c/code\u003e directory, for which we've setup an \u003ccode\u003eactions/cache\u003c/code\u003e step. This output is only useful if in a multi-app repository.\u003c/p\u003e                                                                                         |\n\n\u003c!-- action-docs-outputs action=\"action.yml\" --\u003e\n\n\u003c!-- action-docs-usage action=\"action.yml\" project=\"freckle/platform-setup-action\" version=\"v7\" --\u003e\n\n## Usage\n\n```yaml\n- uses: freckle/platform-setup-action@v7\n  with:\n    version:\n    # The version of PlatformCLI to install. Do not include the `v` prefix here.\n    # The default is to lookup the latest release. We recommend using this\n    # default, along with specifying a `required_version` constraint (such as\n    # `=~ 3`) in your `.platform.yaml`.\n    #\n    # Required: false\n    # Default: \"\"\n\n    token:\n    # A GitHub access token with rights to fetch the private PlatformCLI release\n    # artifacts. Either this or `github-app-{id,private-key}` must be given.\n    #\n    # Required: false\n    # Default: \"\"\n\n    github-app-id:\n    # Provide this (and `github-private-key`) instead of `token` to generate\n    # and use one from the identified App.\n    #\n    # Required: false\n    # Default: \"\"\n\n    github-private-key:\n    # Provide this (and `github-app-id`) instead of `token` to generate and use\n    # one from the identified App.\n    #\n    # Required: false\n    # Default: \"\"\n\n    github-app-private-key:\n    # Deprecated, use github-private-key\n    #\n    # Required: false\n    # Default: \"\"\n\n    app-directory:\n    # If present, this will be set as `PLATFORM_APP_DIRECTORY` for the remainder\n    # of the workflow. For details on what this affects, see `platform(1)`.\n    #\n    # Required: false\n    # Default: \"\"\n\n    environment:\n    # If present, this will be set as `PLATFORM_ENVIRONMENT` for the remainder\n    # of the workflow. For details on what this affects, see `platform(1)`.\n    #\n    # Required: false\n    # Default: \"\"\n\n    resource:\n    # If present, this will be set as `PLATFORM_RESOURCE` for the remainder of\n    # the workflow. For details on what this affects, see `platform(1)`.\n    #\n    # Required: false\n    # Default: \"\"\n\n    no-validate:\n    # If present, this will be set as `PLATFORM_NO_VALIDATE` for the remainder\n    # of the workflow. For details on what this affects, see `platform(1)`.\n    #\n    # Required: false\n    # Default: \"\"\n\n    stackctl-version:\n    # The version of Stackctl to install. Do not include the `v` prefix here.\n    # The default is to lookup the latest release.\n    #\n    # Required: false\n    # Default: \"\"\n\n    stackctl-directory:\n    # Value to set as STACKCTL_DIRECTORY\n    #\n    # Required: false\n    # Default: .platform/specs\n\n    stackctl-filter:\n    # Value to set as STACKCTL_FILTER\n    #\n    # Required: false\n    # Default: \"\"\n\n    fetch-platform-yaml:\n    # Automatically fetch `.platform.yaml` via GitHub API if not present. This\n    # can be useful to avoid a checkout if all your Job needs is this file. This\n    # will always use `github.token`, regardless of our own `token` input.\n    #\n    # Required: false\n    # Default: true\n```\n\n\u003c!-- action-docs-usage action=\"action.yml\" project=\"freckle/platform-setup-action\" version=\"v7\" --\u003e\n\n## Caveat\n\nDepending on the version of PlatformCLI you install, not all\nenvironment-variable-based configurations may be supported. Please refer to the\ndocumentation for the version you're using.\n\n---\n\n[LICENSE](./LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffreckle%2Fsetup-platform-action","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffreckle%2Fsetup-platform-action","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffreckle%2Fsetup-platform-action/lists"}