|
50 | 50 | # See https://github.com/docker/login-action#usage. |
51 | 51 | oci-registry-password: ${{ secrets.GITHUB_TOKEN }} |
52 | 52 |
|
| 53 | + # List of secrets to expose to the build. |
| 54 | + # See <https://docs.docker.com/build/ci/github-actions/secrets/>. |
| 55 | + build-secrets: "" |
| 56 | + |
| 57 | + # GitHub App private key to generate GitHub token to be passed as build secret env. |
| 58 | + # See <https://github.com/actions/create-github-app-token>. |
| 59 | + build-secret-github-app-key: "" |
| 60 | + |
53 | 61 | # Optional customizations. |
54 | 62 | with: |
55 | 63 | # Json array of runner(s) to use. |
@@ -88,32 +96,54 @@ jobs: |
88 | 96 | # } |
89 | 97 | # ] |
90 | 98 | images: "" |
| 99 | + |
| 100 | + # Enable Git LFS. |
| 101 | + # See <https://github.com/actions/checkout?tab=readme-ov-file#usage>. |
| 102 | + # Default: true |
| 103 | + lfs: true |
| 104 | + |
| 105 | + # Environment variable name(s) to pass GitHub token generated by GitHub App. |
| 106 | + # Can be a multiline string list. |
| 107 | + # This is useful to pass a generated token to the build, as it is not possible to share generated secrets between jobs. |
| 108 | + # Needs input `build-secret-github-app-id` and secret `build-secret-github-app-key`. |
| 109 | + # Default: "GITHUB_APP_TOKEN" |
| 110 | + build-secret-github-app-token-env: | |
| 111 | + GITHUB_APP_TOKEN |
| 112 | +
|
| 113 | + # GitHub App ID to generate GitHub token to be passed as build secret env. |
| 114 | + # See <https://github.com/actions/create-github-app-token>. |
| 115 | + build-secret-github-app-id: "" |
91 | 116 | ``` |
92 | 117 |
|
93 | 118 | <!-- end usage --> |
94 | 119 | <!-- start secrets --> |
95 | 120 |
|
96 | 121 | ## Secrets |
97 | 122 |
|
98 | | -| **Secret** | **Description** | |
99 | | -| -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------- | |
100 | | -| **<code>oci-registry-password</code>** | Password or GitHub token (`packages:read` and `packages:write` scopes) used to log against the OCI registry. See <https://github.com/docker/login-action#usage>. | |
| 123 | +| **Secret** | **Description** | **Required** | |
| 124 | +| -------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------ | |
| 125 | +| **<code>oci-registry-password</code>** | Password or GitHub token (`packages:read` and `packages:write` scopes) used to log against the OCI registry. See <https://github.com/docker/login-action#usage>. | **true** | |
| 126 | +| **<code>build-secrets</code>** | List of secrets to expose to the build. See <https://docs.docker.com/build/ci/github-actions/secrets/>. | **false** | |
| 127 | +| **<code>build-secret-github-app-key</code>** | GitHub App private key to generate GitHub token to be passed as build secret env. See <https://github.com/actions/create-github-app-token>. | **false** | |
101 | 128 |
|
102 | 129 | <!-- end secrets --> |
| 130 | +<!-- markdownlint-disable MD013 --> |
103 | 131 | <!-- start inputs --> |
104 | 132 |
|
105 | 133 | ## Inputs |
106 | 134 |
|
107 | | -| **Input** | **Description** | **Default** | **Required** | |
108 | | -| -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------- | ------------ | |
109 | | -| **<code>runs-on</code>** | Json array of runner(s) to use. See <https://docs.github.com/en/actions/using-jobs/choosing-the-runner-for-a-job> | <code>["ubuntu-latest"]</code> | **false** | |
110 | | -| **<code>oci-registry</code>** | OCI registry where to pull and push images | <code>ghcr.io</code> | **false** | |
111 | | -| **<code>oci-registry-username</code>** | Username used to log against the OCI registry. See <https://github.com/docker/login-action#usage> | <code>${{ github.repository_owner }}</code> | **false** | |
112 | | -| **<code>images</code>** | Images to build parameters. | | **true** | |
113 | | -| | Example: <code>[{ "name": "application", "context": ".", "dockerfile": "./docker/application/Dockerfile", "target": "prod", "build-args": { "APP_PATH": "./application/", "PROD_MODE": "true" }, "platforms": ["linux/amd64", { "name": "darwin/amd64", "runs-on": "macos-latest" }] }]</code> | | | |
114 | | -| **<code>lfs</code>** | Enable Git LFS. See <https://github.com/actions/checkout?tab=readme-ov-file#usage>. | <code>true</code> | **false** | |
| 135 | +| **Input** | **Description** | **Default** | **Required** | **Type** | |
| 136 | +| -------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------- | ------------ | ----------- | |
| 137 | +| **<code>runs-on</code>** | Json array of runner(s) to use. See <https://docs.github.com/en/actions/using-jobs/choosing-the-runner-for-a-job> | <code>["ubuntu-latest"]</code> | **false** | **string** | |
| 138 | +| **<code>oci-registry</code>** | OCI registry where to pull and push images | <code>ghcr.io</code> | **false** | **string** | |
| 139 | +| **<code>oci-registry-username</code>** | Username used to log against the OCI registry. See <https://github.com/docker/login-action#usage> | <code>${{ github.repository_owner }}</code> | **false** | **string** | |
| 140 | +| **<code>images</code>** | Images to build parameters. Json array of objects. Example: [{ "name": "application", "context": ".", "dockerfile": "./docker/application/Dockerfile", "target": "prod", "build-args": { "APP_PATH": "./application/", "PROD_MODE": "true" }, "secret-envs": { "GH_TOKEN": "GITHUB_TOKEN" }, "platforms": ["linux/amd64", { "name": "darwin/amd64", "runs-on": "macos-latest" }] }] | | **true** | **string** | |
| 141 | +| **<code>lfs</code>** | Enable Git LFS. See <https://github.com/actions/checkout?tab=readme-ov-file#usage>. | <code>true</code> | **false** | **boolean** | |
| 142 | +| **<code>build-secret-github-app-token-env</code>** | Environment variable name(s) to pass GitHub token generated by GitHub App. Can be a multiline string list. This is useful to pass a generated token to the build, as it is not possible to share generated secrets between jobs. Needs input `build-secret-github-app-id` and secret `build-secret-github-app-key`. | <code>GITHUB_APP_TOKEN</code> | **false** | **string** | |
| 143 | +| **<code>build-secret-github-app-id</code>** | GitHub App ID to generate GitHub token to be passed as build secret env. See <https://github.com/actions/create-github-app-token>. | | **false** | **string** | |
115 | 144 |
|
116 | 145 | <!-- end inputs --> |
| 146 | +<!-- markdownlint-enable MD013 --> |
117 | 147 |
|
118 | 148 | ### Images entry parameters |
119 | 149 |
|
|
0 commit comments