mirror of
https://forgejo.merr.is/annika/actions-docker-extract.git
synced 2025-12-11 12:28:49 -05:00
ci: Package action automatically on release branch (#15)
This commit is contained in:
parent
abde1147dd
commit
917745b929
9 changed files with 161 additions and 1623 deletions
39
README.md
39
README.md
|
|
@ -5,27 +5,27 @@ A GitHub Action for extracting files from a Docker Image.
|
|||
```yaml
|
||||
- uses: shrink/actions-docker-extract@v1
|
||||
with:
|
||||
image: 'ghost:alpine'
|
||||
path: '/var/lib/ghost/current/core/built/assets/.'
|
||||
image: "ghost:alpine"
|
||||
path: "/var/lib/ghost/current/core/built/assets/."
|
||||
```
|
||||
|
||||
## Inputs
|
||||
|
||||
All inputs are required.
|
||||
|
||||
| ID | Description | Examples |
|
||||
| --- | ----------- | -------- |
|
||||
| `image` | Docker Image to extract files from | `alpine` `ghcr.io/github/super-linter:latest` |
|
||||
| `path` | Path (from root) to a file or directory within Image | `files/example.txt` `files` `files/.` |
|
||||
| ID | Description | Examples |
|
||||
| ------- | ---------------------------------------------------- | --------------------------------------------- |
|
||||
| `image` | Docker Image to extract files from | `alpine` `ghcr.io/github/super-linter:latest` |
|
||||
| `path` | Path (from root) to a file or directory within Image | `files/example.txt` `files` `files/.` |
|
||||
|
||||
> :paperclip: To copy the **contents** of a directory the `path` must end with
|
||||
`/.` otherwise the directory itself will be copied. More information about the
|
||||
specific rules can be found via the [docker cp][docker-cp] documentation.
|
||||
> `/.` otherwise the directory itself will be copied. More information about the
|
||||
> specific rules can be found via the [docker cp][docker-cp] documentation.
|
||||
|
||||
## Outputs
|
||||
|
||||
| ID | Description | Example |
|
||||
| --- | ----------- | ------- |
|
||||
| ID | Description | Example |
|
||||
| ------------- | ------------------------------------------------- | ------------------------ |
|
||||
| `destination` | Destination path containing the extracted file(s) | `.extracted-1598717412/` |
|
||||
|
||||
## Examples
|
||||
|
|
@ -88,6 +88,25 @@ jobs:
|
|||
name: dist
|
||||
```
|
||||
|
||||
## Automatic Release Packaging
|
||||
|
||||
A Workflow packages the Action automatically when a collaborator created a new
|
||||
tag. Any reference to this Action in a Workflow must use a [tag][tags] (mutable)
|
||||
or the commit hash of a tag (immutable).
|
||||
|
||||
```yaml
|
||||
✅ uses: shrink/actions-docker-extract@v2
|
||||
✅ uses: shrink/actions-docker-extract@v2.0.0
|
||||
✅ uses: shrink/actions-docker-extract@abde1147dd0d248b38feda9e75768c3d2b57eefc
|
||||
❌ uses: shrink/actions-docker-extract@main
|
||||
```
|
||||
|
||||
The blog post
|
||||
[Package GitHub Actions automatically with GitHub Actions][blog/package-automatically]
|
||||
describes how this is achieved.
|
||||
|
||||
[build-push-action]: https://github.com/docker/build-push-action
|
||||
[login-action]: https://github.com/docker/login-action
|
||||
[docker-cp]: https://docs.docker.com/engine/reference/commandline/cp/#extended-description
|
||||
[tags]: https://github.com/shrink/actions-docker-extract/tags
|
||||
[blog/package-automatically]: https://medium.com/prompt/package-github-actions-automatically-with-github-actions-a70b9f7bae4
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue