Actions for v1.2 werf version

- remove actions not used in v1.2
- update the example arbitrary version
- embed v1.2 MAJOR.MINOR
This commit is contained in:
Alexey Igrychev
2021-03-10 14:06:15 +00:00
parent f933394504
commit 2df7b68580
27 changed files with 64 additions and 134152 deletions

View File

@@ -6,11 +6,8 @@ ___
This action set allows you to organize CI/CD with GitHub Actions and [werf](https://github.com/werf/werf). The set consists of several independent and complex actions:
- [werf/actions/converge](https://github.com/werf/actions/tree/master/converge)
- [werf/actions/build-and-publish](https://github.com/werf/actions/tree/master/build-and-publish)
- [werf/actions/build](https://github.com/werf/actions/tree/master/build)
- [werf/actions/publish](https://github.com/werf/actions/tree/master/build)
- [werf/actions/deploy](https://github.com/werf/actions/tree/master/deploy)
- [werf/actions/dismiss](https://github.com/werf/actions/tree/master/dismiss)
- [werf/actions/build](https://github.com/werf/actions/tree/master/build)
- [werf/actions/run](https://github.com/werf/actions/tree/master/run)
- [werf/actions/cleanup](https://github.com/werf/actions/tree/master/cleanup)
@@ -30,7 +27,7 @@ Using the `channel` input the user can switch the release channel.
> This is recommended approach to be up-to-date and to use actual werf version without changing configurations
```yaml
- uses: werf/actions/converge@v1.1
- uses: werf/actions/converge@v1.2
with:
channel: alpha
```
@@ -38,9 +35,9 @@ Using the `channel` input the user can switch the release channel.
Withal, it is not necessary to work within release channels, and the user might specify certain werf version with `version` input.
```yaml
- uses: werf/actions/converge@v1.1
- uses: werf/actions/converge@v1.2
with:
version: v1.1.23
version: v1.2.9
```
### kubeconfig setup (*optional*)
@@ -52,7 +49,7 @@ The _kubeconfig_ may be used for deployment, cleanup, distributed locks and cach
* Pass secret with `kube-config-base64-data` input:
```yaml
- uses: werf/actions/build-and-publish@v1.1
- uses: werf/actions/converge@v1.2
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```
@@ -70,11 +67,9 @@ By default, action will use the token provided to your workflow.
Any werf option can be defined with environment variables:
```yaml
- uses: werf/actions/build-and-publish@v1.1
- uses: werf/actions/converge@v1.2
env:
WERF_LOG_VERBOSE: "on"
WERF_TAG_CUSTOM_TAG1: tag1
WERF_TAG_CUSTOM_TAG2: tag2
```
## Examples
@@ -93,43 +88,7 @@ converge:
fetch-depth: 0
- name: Converge
uses: werf/actions/converge@v1.1
with:
env: production
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```
### build, publish and deploy
```yaml
build-and-publish:
name: Build and Publish
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Build and Publish
uses: werf/actions/build-and-publish@v1.1
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
deploy:
name: Deploy
needs: build-and-publish
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Deploy
uses: werf/actions/deploy@v1.1
uses: werf/actions/converge@v1.2
with:
env: production
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
@@ -147,7 +106,7 @@ dismiss:
uses: actions/checkout@v2
- name: Dismiss
uses: werf/actions/dismiss@v1.1
uses: werf/actions/dismiss@v1.2
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
env: production
@@ -167,7 +126,7 @@ run:
fetch-depth: 0
- name: Run
uses: werf/actions/run@v1.1
uses: werf/actions/run@v1.2
with:
image: backend
args: rails server
@@ -191,7 +150,7 @@ cleanup:
run: git fetch --prune --unshallow
- name: Cleanup
uses: werf/actions/cleanup@v1.1
uses: werf/actions/cleanup@v1.2
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```
@@ -208,7 +167,7 @@ werf:
uses: actions/checkout@v2
- name: Install werf CLI
uses: werf/actions/install@v1.1
uses: werf/actions/install@v1.2
# for deploy and distributed locks
- name: Create kube config
@@ -222,8 +181,8 @@ werf:
- name: Run werf commands
run: |
source $(werf ci-env github --as-file)
werf build-and-publish
werf deploy
werf render
werf converge
env:
GITHUB_TOKEN: ${{ github.token }}
WERF_ENV: production

View File

@@ -1,101 +0,0 @@
<p align="center">
<img src="https://github.com/werf/werf/raw/master/docs/images/werf-logo.svg?sanitize=true" style="max-height:100%;" height="175">
</p>
___
The action combines all the necessary steps in itself and logic may be divided into environment setup and launching `werf build-and-publish`.
## Action in Details
### werf binary setup
By default, all actions setup actual werf version for [1.1 alpha channel](https://werf.io/releases.html) (more details about channels, werf release cycle and compatibility promise [here](https://github.com/werf/werf#backward-compatibility-promise)).
Using the `channel` input the user can switch the release channel.
> This is recommended approach to be up-to-date and to use actual werf version without changing configurations
```yaml
- uses: werf/actions/build-and-publish@v1.1
with:
channel: alpha
```
Withal, it is not necessary to work within release channels, and the user might specify certain werf version with `version` input.
```yaml
- uses: werf/actions/build-and-publish@v1.1
with:
version: v1.1.23
```
### kubeconfig setup (*optional*)
The _kubeconfig_ may be used for deployment, cleanup, distributed locks and caches. Thus, the configuration should be added before step with the action or passed as base64 encoded data with `kube-config-base64-data` input:
* Prepare _kubeconfig_ (e.g. `cat ~/.kube/config | base64`) and save in GitHub Project Secrets (e.g. with name `KUBE_CONFIG_BASE64_DATA`).
* Pass secret with `kube-config-base64-data` input:
```yaml
- uses: werf/actions/build-and-publish@v1.1
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```
### werf ci-env
This command performs _docker login_ using `github-token`, sets up predefined variables based on GitHub Workflow context.
**Note** that `github-token` is optional in this action, and the input is there in case you need to use a non-default token.
By default, action will use the token provided to your workflow.
## Working with werf options
Any werf option can be defined with environment variables:
```yaml
- uses: werf/actions/build-and-publish@v1.1
env:
WERF_LOG_VERBOSE: "on"
WERF_TAG_CUSTOM_TAG1: tag1
WERF_TAG_CUSTOM_TAG2: tag2
```
## Inputs
```yaml
channel:
description: 'The one of the following channel: alpha, beta, ea, stable, rock-solid'
default: 'alpha'
required: false
version:
description: 'The certain version'
required: false
github-token:
description: 'The GitHub token used to login and to interact with Docker Github Packages'
default: ${{ github.token }}
required: false
kube-config-base64-data:
description: 'Base64 encoded kubeconfig data used for deployment, cleanup and distributed locks'
required: false
```
## Example
```yaml
build-and-publish:
name: Build and Publish
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Build and Publish
uses: werf/actions/build-and-publish@v1.1
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```

View File

@@ -1,24 +0,0 @@
name: werf build-and-publish
author: 'Flant'
description: 'Prepare the environment and perform image building and publishing with werf'
branding:
color: blue
icon: anchor
inputs:
channel:
description: 'The one of the following channel: alpha, beta, ea, stable, rock-solid'
default: 'alpha'
required: false
version:
description: 'The certain version'
required: false
github-token:
description: 'The GitHub token used to login and to interact with Docker Github Packages'
default: ${{ github.token }}
required: false
kube-config-base64-data:
description: 'Base64 encoded kubeconfig data used for deployment, cleanup and distributed locks'
required: false
runs:
using: 'node12'
main: 'index.js'

File diff suppressed because one or more lines are too long

View File

@@ -15,7 +15,7 @@ Using the `channel` input the user can switch the release channel.
> This is recommended approach to be up-to-date and to use actual werf version without changing configurations
```yaml
- uses: werf/actions/build@v1.1
- uses: werf/actions/build@v1.2
with:
channel: alpha
```
@@ -23,9 +23,9 @@ Using the `channel` input the user can switch the release channel.
Withal, it is not necessary to work within release channels, and the user might specify certain werf version with `version` input.
```yaml
- uses: werf/actions/build@v1.1
- uses: werf/actions/build@v1.2
with:
version: v1.1.23
version: v1.2.9
```
### kubeconfig setup (*optional*)
@@ -37,7 +37,7 @@ The _kubeconfig_ may be used for deployment, cleanup, distributed locks and cach
* Pass secret with `kube-config-base64-data` input:
```yaml
- uses: werf/actions/build@v1.1
- uses: werf/actions/build@v1.2
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```
@@ -55,11 +55,9 @@ By default, action will use the token provided to your workflow.
Any werf option can be defined with environment variables:
```yaml
- uses: werf/actions/build@v1.1
- uses: werf/actions/build@v1.2
env:
WERF_LOG_VERBOSE: "on"
WERF_TAG_CUSTOM_TAG1: tag1
WERF_TAG_CUSTOM_TAG2: tag2
```
## Inputs
@@ -95,7 +93,7 @@ build:
fetch-depth: 0
- name: Build
uses: werf/actions/build@v1.1
uses: werf/actions/build@v1.2
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```

View File

@@ -4125,9 +4125,9 @@ module.exports = gt
Object.defineProperty(exports, "__esModule", { value: true });
exports.MINOR = exports.MAJOR = exports.MAJOR_MINOR_GROUP = void 0;
exports.MAJOR_MINOR_GROUP = '1.1';
exports.MAJOR_MINOR_GROUP = '1.2';
exports.MAJOR = 1;
exports.MINOR = 1;
exports.MINOR = 2;
/***/ }),

View File

@@ -15,7 +15,7 @@ Using the `channel` input the user can switch the release channel.
> This is recommended approach to be up-to-date and to use actual werf version without changing configurations
```yaml
- uses: werf/actions/cleanup@v1.1
- uses: werf/actions/cleanup@v1.2
with:
channel: alpha
```
@@ -23,9 +23,9 @@ Using the `channel` input the user can switch the release channel.
Withal, it is not necessary to work within release channels, and the user might specify certain werf version with `version` input.
```yaml
- uses: werf/actions/cleanup@v1.1
- uses: werf/actions/cleanup@v1.2
with:
version: v1.1.23
version: v1.2.9
```
### kubeconfig setup (*optional*)
@@ -37,7 +37,7 @@ The _kubeconfig_ may be used for deployment, cleanup, distributed locks and cach
* Pass secret with `kube-config-base64-data` input:
```yaml
- uses: werf/actions/cleanup@v1.1
- uses: werf/actions/cleanup@v1.2
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```
@@ -55,7 +55,7 @@ By default, action will use the token provided to your workflow.
Any werf option can be defined with environment variables:
```yaml
- uses: werf/actions/cleanup@v1.1
- uses: werf/actions/cleanup@v1.2
env:
WERF_LOG_VERBOSE: "on"
```
@@ -94,7 +94,7 @@ cleanup:
run: git fetch --prune --unshallow
- name: Cleanup
uses: werf/actions/cleanup@v1.1
uses: werf/actions/cleanup@v1.2
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```

View File

@@ -4125,9 +4125,9 @@ module.exports = gt
Object.defineProperty(exports, "__esModule", { value: true });
exports.MINOR = exports.MAJOR = exports.MAJOR_MINOR_GROUP = void 0;
exports.MAJOR_MINOR_GROUP = '1.1';
exports.MAJOR_MINOR_GROUP = '1.2';
exports.MAJOR = 1;
exports.MINOR = 1;
exports.MINOR = 2;
/***/ }),

View File

@@ -15,7 +15,7 @@ Using the `channel` input the user can switch the release channel.
> This is recommended approach to be up-to-date and to use actual werf version without changing configurations
```yaml
- uses: werf/actions/converge@v1.1
- uses: werf/actions/converge@v1.2
with:
channel: alpha
```
@@ -23,9 +23,9 @@ Using the `channel` input the user can switch the release channel.
Withal, it is not necessary to work within release channels, and the user might specify certain werf version with `version` input.
```yaml
- uses: werf/actions/converge@v1.1
- uses: werf/actions/converge@v1.2
with:
version: v1.1.23
version: v1.2.9
```
### kubeconfig setup (*optional*)
@@ -37,7 +37,7 @@ The _kubeconfig_ may be used for deployment, cleanup, distributed locks and cach
* Pass secret with `kube-config-base64-data` input:
```yaml
- uses: werf/actions/converge@v1.1
- uses: werf/actions/converge@v1.2
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```
@@ -55,7 +55,7 @@ By default, action will use the token provided to your workflow.
Any werf option can be defined with environment variables:
```yaml
- uses: werf/actions/converge@v1.1
- uses: werf/actions/converge@v1.2
with:
env: production
env:
@@ -98,7 +98,7 @@ converge:
fetch-depth: 0
- name: Converge
uses: werf/actions/converge@v1.1
uses: werf/actions/converge@v1.2
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
env: production

View File

@@ -4125,9 +4125,9 @@ module.exports = gt
Object.defineProperty(exports, "__esModule", { value: true });
exports.MINOR = exports.MAJOR = exports.MAJOR_MINOR_GROUP = void 0;
exports.MAJOR_MINOR_GROUP = '1.1';
exports.MAJOR_MINOR_GROUP = '1.2';
exports.MAJOR = 1;
exports.MINOR = 1;
exports.MINOR = 2;
/***/ }),

View File

@@ -1,105 +0,0 @@
<p align="center">
<img src="https://github.com/werf/werf/raw/master/docs/images/werf-logo.svg?sanitize=true" style="max-height:100%;" height="175">
</p>
___
The action combines all the necessary steps in itself and logic may be divided into environment setup and launching `werf deploy`.
## Action in Details
### werf binary setup
By default, all actions setup actual werf version for [1.1 alpha channel](https://werf.io/releases.html) (more details about channels, werf release cycle and compatibility promise [here](https://github.com/werf/werf#backward-compatibility-promise)).
Using the `channel` input the user can switch the release channel.
> This is recommended approach to be up-to-date and to use actual werf version without changing configurations
```yaml
- uses: werf/actions/deploy@v1.1
with:
channel: alpha
```
Withal, it is not necessary to work within release channels, and the user might specify certain werf version with `version` input.
```yaml
- uses: werf/actions/deploy@v1.1
with:
version: v1.1.23
```
### kubeconfig setup (*optional*)
The _kubeconfig_ may be used for deployment, cleanup, distributed locks and caches. Thus, the configuration should be added before step with the action or passed as base64 encoded data with `kube-config-base64-data` input:
* Prepare _kubeconfig_ (e.g. `cat ~/.kube/config | base64`) and save in GitHub Project Secrets (e.g. with name `KUBE_CONFIG_BASE64_DATA`).
* Pass secret with `kube-config-base64-data` input:
```yaml
- uses: werf/actions/deploy@v1.1
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```
### werf ci-env
This command performs _docker login_ using `github-token`, sets up predefined variables based on GitHub Workflow context.
**Note** that `github-token` is optional in this action, and the input is there in case you need to use a non-default token.
By default, action will use the token provided to your workflow.
## Working with werf options
Any werf option can be defined with environment variables:
```yaml
- uses: werf/actions/deploy@v1.1
with:
env: production
env:
WERF_LOG_VERBOSE: "on"
```
## Inputs
```yaml
channel:
description: 'The one of the following channel: alpha, beta, ea, stable, rock-solid'
default: 'alpha'
required: false
version:
description: 'The certain version'
required: false
env:
description: 'Specific deployment environment'
required: true
github-token:
description: 'The GitHub token used to login and to interact with Docker Github Packages'
default: ${{ github.token }}
required: false
kube-config-base64-data:
description: 'Base64 encoded kubeconfig data used for deployment, cleanup and distributed locks'
required: false
```
## Example
```yaml
deploy:
name: Deploy
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Deploy
uses: werf/actions/deploy@v1.1
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
env: production
```

View File

@@ -1,27 +0,0 @@
name: werf build-and-publish
author: 'Flant'
description: 'Prepare the environment and perform deployment with werf'
branding:
color: blue
icon: anchor
inputs:
channel:
description: 'The one of the following channel: alpha, beta, ea, stable, rock-solid'
default: 'alpha'
required: false
version:
description: 'The certain version'
required: false
env:
description: 'Specific deployment environment'
required: true
github-token:
description: 'The GitHub token used to login and to interact with Docker Github Packages'
default: ${{ github.token }}
required: false
kube-config-base64-data:
description: 'Base64 encoded kubeconfig data used for deployment, cleanup and distributed locks'
required: false
runs:
using: 'node12'
main: 'index.js'

File diff suppressed because one or more lines are too long

View File

@@ -15,7 +15,7 @@ Using the `channel` input the user can switch the release channel.
> This is recommended approach to be up-to-date and to use actual werf version without changing configurations
```yaml
- uses: werf/actions/converge@v1.1
- uses: werf/actions/converge@v1.2
with:
channel: alpha
```
@@ -23,9 +23,9 @@ Using the `channel` input the user can switch the release channel.
Withal, it is not necessary to work within release channels, and the user might specify certain werf version with `version` input.
```yaml
- uses: werf/actions/converge@v1.1
- uses: werf/actions/converge@v1.2
with:
version: v1.1.23
version: v1.2.9
```
### kubeconfig setup (*optional*)
@@ -37,7 +37,7 @@ The _kubeconfig_ may be used for deployment, cleanup, distributed locks and cach
* Pass secret with `kube-config-base64-data` input:
```yaml
- uses: werf/actions/converge@v1.1
- uses: werf/actions/converge@v1.2
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```
@@ -55,7 +55,7 @@ By default, action will use the token provided to your workflow.
Any werf option can be defined with environment variables:
```yaml
- uses: werf/actions/converge@v1.1
- uses: werf/actions/converge@v1.2
with:
env: production
env:
@@ -96,7 +96,7 @@ dismiss:
uses: actions/checkout@v2
- name: Dismiss
uses: werf/actions/dismiss@v1.1
uses: werf/actions/dismiss@v1.2
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
env: production

View File

@@ -4125,9 +4125,9 @@ module.exports = gt
Object.defineProperty(exports, "__esModule", { value: true });
exports.MINOR = exports.MAJOR = exports.MAJOR_MINOR_GROUP = void 0;
exports.MAJOR_MINOR_GROUP = '1.1';
exports.MAJOR_MINOR_GROUP = '1.2';
exports.MAJOR = 1;
exports.MINOR = 1;
exports.MINOR = 2;
/***/ }),

View File

@@ -9,7 +9,7 @@ Using the `channel` input the user can switch the release channel.
> This is recommended approach to be up-to-date and to use actual werf version without changing configurations
```yaml
- uses: werf/actions/install@v1.1
- uses: werf/actions/install@v1.2
with:
channel: alpha
```
@@ -17,9 +17,9 @@ Using the `channel` input the user can switch the release channel.
Withal, it is not necessary to work within release channels, and the user might specify certain werf version with `version` input.
```yaml
- uses: werf/actions/install@v1.1
- uses: werf/actions/install@v1.2
with:
version: v1.1.23
version: v1.2.9
```
## Inputs
@@ -46,7 +46,7 @@ werf:
uses: actions/checkout@v2
- name: Install werf CLI
uses: werf/actions/install@v1.1
uses: werf/actions/install@v1.2
# for deploy and distributed locks
- name: Create kube config
@@ -60,8 +60,8 @@ werf:
- name: Run werf commands
run: |
source $(werf ci-env github --as-file)
werf build-and-publish
werf deploy
werf render
werf converge
env:
GITHUB_TOKEN: ${{ github.token }}
WERF_ENV: production

View File

@@ -4265,9 +4265,9 @@ module.exports = gt
Object.defineProperty(exports, "__esModule", { value: true });
exports.MINOR = exports.MAJOR = exports.MAJOR_MINOR_GROUP = void 0;
exports.MAJOR_MINOR_GROUP = '1.1';
exports.MAJOR_MINOR_GROUP = '1.2';
exports.MAJOR = 1;
exports.MINOR = 1;
exports.MINOR = 2;
/***/ }),

View File

@@ -1,3 +1,3 @@
#!/bin/bash -e
for pkg in build build-and-publish cleanup converge deploy dismiss install publish run; do ncc build src/$pkg.ts -o $pkg; done
for pkg in build cleanup converge dismiss install run; do ncc build src/$pkg.ts -o $pkg; done

View File

@@ -1,101 +0,0 @@
<p align="center">
<img src="https://github.com/werf/werf/raw/master/docs/images/werf-logo.svg?sanitize=true" style="max-height:100%;" height="175">
</p>
___
The action combines all the necessary steps in itself and logic may be divided into environment setup and launching `werf publish`.
## Action in Details
### werf binary setup
By default, all actions setup actual werf version for [1.1 alpha channel](https://werf.io/releases.html) (more details about channels, werf release cycle and compatibility promise [here](https://github.com/werf/werf#backward-compatibility-promise)).
Using the `channel` input the user can switch the release channel.
> This is recommended approach to be up-to-date and to use actual werf version without changing configurations
```yaml
- uses: werf/actions/publish@v1.1
with:
channel: alpha
```
Withal, it is not necessary to work within release channels, and the user might specify certain werf version with `version` input.
```yaml
- uses: werf/actions/publish@v1.1
with:
version: v1.1.23
```
### kubeconfig setup (*optional*)
The _kubeconfig_ may be used for deployment, cleanup, distributed locks and caches. Thus, the configuration should be added before step with the action or passed as base64 encoded data with `kube-config-base64-data` input:
* Prepare _kubeconfig_ (e.g. `cat ~/.kube/config | base64`) and save in GitHub Project Secrets (e.g. with name `KUBE_CONFIG_BASE64_DATA`).
* Pass secret with `kube-config-base64-data` input:
```yaml
- uses: werf/actions/publish@v1.1
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```
### werf ci-env
This command performs _docker login_ using `github-token`, sets up predefined variables based on GitHub Workflow context.
**Note** that `github-token` is optional in this action, and the input is there in case you need to use a non-default token.
By default, action will use the token provided to your workflow.
## Working with werf options
Any werf option can be defined with environment variables:
```yaml
- uses: werf/actions/publish@v1.1
env:
WERF_LOG_VERBOSE: "on"
WERF_TAG_CUSTOM_TAG1: tag1
WERF_TAG_CUSTOM_TAG2: tag2
```
## Inputs
```yaml
channel:
description: 'The one of the following channel: alpha, beta, ea, stable, rock-solid'
default: 'alpha'
required: false
version:
description: 'The certain version'
required: false
github-token:
description: 'The GitHub token used to login and to interact with Docker Github Packages'
default: ${{ github.token }}
required: false
kube-config-base64-data:
description: 'Base64 encoded kubeconfig data used for deployment, cleanup and distributed locks'
required: false
```
## Example
```yaml
publish:
name: Publish
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Publish
uses: werf/actions/publish@v1.1
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```

View File

@@ -1,24 +0,0 @@
name: werf publish
author: 'Flant'
description: 'Prepare the environment and perform image publishing with werf'
branding:
color: blue
icon: anchor
inputs:
channel:
description: 'The one of the following channel: alpha, beta, ea, stable, rock-solid'
default: 'alpha'
required: false
version:
description: 'The certain version'
required: false
github-token:
description: 'The GitHub token used to login and to interact with Docker Github Packages'
default: ${{ github.token }}
required: false
kube-config-base64-data:
description: 'Base64 encoded kubeconfig data used for deployment, cleanup and distributed locks'
required: false
runs:
using: 'node12'
main: 'index.js'

File diff suppressed because one or more lines are too long

View File

@@ -15,7 +15,7 @@ Using the `channel` input the user can switch the release channel.
> This is recommended approach to be up-to-date and to use actual werf version without changing configurations
```yaml
- uses: werf/actions/run@v1.1
- uses: werf/actions/run@v1.2
with:
channel: alpha
```
@@ -23,9 +23,9 @@ Using the `channel` input the user can switch the release channel.
Withal, it is not necessary to work within release channels, and the user might specify certain werf version with `version` input.
```yaml
- uses: werf/actions/run@v1.1
- uses: werf/actions/run@v1.2
with:
version: v1.1.23
version: v1.2.9
```
### kubeconfig setup (*optional*)
@@ -37,7 +37,7 @@ The _kubeconfig_ may be used for deployment, cleanup, distributed locks and cach
* Pass secret with `kube-config-base64-data` input:
```yaml
- uses: werf/actions/run@v1.1
- uses: werf/actions/run@v1.2
with:
kube-config-base64-data: ${{ secrets.KUBE_CONFIG_BASE64_DATA }}
```
@@ -55,11 +55,9 @@ By default, action will use the token provided to your workflow.
Any werf option can be defined with environment variables:
```yaml
- uses: werf/actions/run@v1.1
- uses: werf/actions/run@v1.2
env:
WERF_LOG_VERBOSE: "on"
WERF_TAG_CUSTOM_TAG1: tag1
WERF_TAG_CUSTOM_TAG2: tag2
```
## Inputs
@@ -102,7 +100,7 @@ run:
fetch-depth: 0
- name: Run
uses: werf/actions/run@v1.1
uses: werf/actions/run@v1.2
with:
image: backend
args: rails server

View File

@@ -4247,9 +4247,9 @@ module.exports = gt
Object.defineProperty(exports, "__esModule", { value: true });
exports.MINOR = exports.MAJOR = exports.MAJOR_MINOR_GROUP = void 0;
exports.MAJOR_MINOR_GROUP = '1.1';
exports.MAJOR_MINOR_GROUP = '1.2';
exports.MAJOR = 1;
exports.MINOR = 1;
exports.MINOR = 2;
/***/ }),

View File

@@ -1,12 +0,0 @@
import * as core from '@actions/core'
import {PrepareEnvironAndRunWerfCommand} from './common'
async function run(): Promise<void> {
try {
await PrepareEnvironAndRunWerfCommand(['build-and-publish'])
} catch (error) {
core.setFailed(error.message)
}
}
run()

View File

@@ -1,13 +0,0 @@
import * as core from '@actions/core'
import {PrepareEnvironAndRunWerfCommand} from './common'
async function run(): Promise<void> {
try {
process.env.WERF_ENV = core.getInput('env')
await PrepareEnvironAndRunWerfCommand(['deploy'])
} catch (error) {
core.setFailed(error.message)
}
}
run()

View File

@@ -1,12 +0,0 @@
import * as core from '@actions/core'
import {PrepareEnvironAndRunWerfCommand} from './common'
async function run(): Promise<void> {
try {
await PrepareEnvironAndRunWerfCommand(['publish'])
} catch (error) {
core.setFailed(error.message)
}
}
run()

View File

@@ -1,3 +1,3 @@
export const MAJOR_MINOR_GROUP = '1.1'
export const MAJOR_MINOR_GROUP = '1.2'
export const MAJOR = 1
export const MINOR = 1
export const MINOR = 2