File tree 5 files changed +45
-7
lines changed
5 files changed +45
-7
lines changed Original file line number Diff line number Diff line change 1
- # load-env Github Action
1
+ # load-env GitHub Action
2
2
3
3
The ** load-env** action provides .env key-value pairs as outputs for use in workflows.
4
4
File renamed without changes.
Original file line number Diff line number Diff line change
1
+ # next-image-tag-number GitHub Action
2
+
3
+ The ** next-image-tag-number** action calculates the next sequential tag for an image in an OCI repository. This is useful for tracking build numbers or versioning images in continuous integration workflows.
4
+
5
+ ## Usage
6
+
7
+ Specify the OCI image repository URL in your workflow, along with optional parameters:
8
+
9
+ ``` yaml
10
+ jobs :
11
+ next-tag :
12
+ runs-on : ubuntu-latest
13
+ steps :
14
+ - uses : actions/checkout@v2
15
+
16
+ - name : Get Next Image Tag Number
17
+ id : next-tag
18
+ uses : codebandits/github-actions/next-image-tag-number@main
19
+ with :
20
+ image_repository_url : https://registry.example.com/v2/my-repo/my-image
21
+ bearer_token : ${{ secrets.REPO_BEARER_TOKEN }}
22
+ initial_number : 100
23
+ tag_prefix : build-
24
+
25
+ - run : echo "Next tag is ${{ steps.next-tag.outputs.tag }} with number ${{ steps.next-tag.outputs.number }}"
26
+ ` ` `
27
+
28
+ ## Inputs
29
+
30
+ - ` image_repository_url:` **Required.** The URL of the OCI-compatible image repository.
31
+ - ` bearer_token:` Optional. The bearer token for repository authentication. Defaults to empty (no authentication).
32
+ - ` initial_number:` Optional. Starting tag number if no tags exist in the repository. Defaults to 1.
33
+ - ` tag_prefix:` Optional. Prefix for the tags. Defaults to build-.
34
+
35
+ # # Outputs
36
+
37
+ - ` tag:` The next tag, including the prefix and tag number.
38
+ - ` number:` The next tag number.
Original file line number Diff line number Diff line change 1
- name : Next Repository Tag Number
2
- description : Get the next tag number for a repository.
1
+ name : Next Image Tag Number
2
+ description : Get the next tag number for an image in an OCI repository.
3
3
4
4
inputs :
5
- repository_url :
6
- description : The URL of the OCI-compatible repository.
5
+ image_repository_url :
6
+ description : The URL of the OCI-compatible image repository.
7
7
required : true
8
8
bearer_token :
9
9
description : Optional bearer token for repository authentication.
@@ -19,7 +19,7 @@ inputs:
19
19
20
20
outputs :
21
21
tag :
22
- description : The next tag.
22
+ description : The next tag, including the prefix and tag number .
23
23
value : ${{ steps.next-tag.outputs.tag }}
24
24
number :
25
25
description : The next tag number.
29
29
using : docker
30
30
image : Dockerfile
31
31
args :
32
- - ${{ inputs.repository_url }}
32
+ - ${{ inputs.image_repository_url }}
33
33
- ${{ inputs.bearer_token }}
34
34
- ${{ inputs.initial_number }}
35
35
- ${{ inputs.tag_prefix }}
File renamed without changes.
You can’t perform that action at this time.
0 commit comments