Closed sergeyzwezdin closed 4 years ago
@Goodsmileduck is there any chance to have it implemented? It clears env variables on every deployment it makes this action useless :(
@sergeyzwezdin I can do that, how you would like to set them? 1 variable with comma-separated parameters?
can you try to test branch dev
?
just set variables separated with commas in var ENVIRONMENT
don't forget to change branch in workflow file - uses: goodsmileduck/yandex-serverless-action@dev
https://github.com/Goodsmileduck/yandex-serverless-action/pull/4
@Goodsmileduck It works for simple values like TEST=123
, but how to put something more complicated? For example, TEST=User Name <info@domain.com>
.
@Goodsmileduck Also, maybe it would be better to use GH Action with
section?
- uses: goodsmileduck/yandex-serverless-action@master
with:
environment:
- TEST1: User Name <info@domain.com>.
- TEST2: 123
env:
SOURCE_DIR: '.'
ZONE: 'ru-central1-a'
FUNCTION_NAME: 'handler'
RUNTIME: 'python37'
ENTRYPOINT: 'main.handler'
ENVIRONMENT: DEBUG=True,COUNT=1
CLOUD_ID: ${{ secrets.CLOUD_ID }}
FOLDER_ID: ${{ secrets.FOLDER_ID }}
TOKEN: ${{ secrets.TOKEN }}
BUCKET: ${{ secrets.BUCKET }}
ACCESS_KEY: ${{ secrets.ACCESS_KEY }}
SECRET_KEY: ${{ secrets.SECRET_KEY }}
@sergeyzwezdin can you restart the last build? I added quotas for ENVIRONMENT value
@Goodsmileduck now works like a charm, thank you! 👏
It would be more convenient to setup it with with
, but at least now it works, so it's up to you.
Thank you again :-)
@sergeyzwezdin I not sure I understand how to use it, can you show example? I didn't find anything. Also if you have questions, you can drop me messages to telegram https://t.me/goodsmileduck And if you could help me with js to use nodejs-sdk for yandex cloud https://github.com/yandex-cloud/nodejs-sdk/blob/master/api/serverless/functions/v1/index.js we could rewrite action on javascript probably..
@Goodsmileduck It's input
definition in action.yml
- https://help.github.com/en/actions/automating-your-workflow-with-github-actions/metadata-syntax-for-github-actions#inputs
inputs:
numOctocats:
description: 'Number of Octocats'
required: false
default: '1'
octocatEyeColor:
description: 'Eye color of the Octocats'
required: true
So if you define it in for action, next you can define these parameters in with
section - https://help.github.com/en/actions/automating-your-workflow-with-github-actions/workflow-syntax-for-github-actions#jobsjob_idstepswith
I see that it's also available for docker actions - https://help.github.com/en/actions/automating-your-workflow-with-github-actions/creating-a-docker-container-action#create-an-action-metadata-file
And if you could help me with js to use nodejs-sdk for yandex cloud https://github.com/yandex-cloud/nodejs-sdk/blob/master/api/serverless/functions/v1/index.js we could rewrite action on javascript probably..
I'd happy to help, but do they have any documentation for the API? Couldn't find that
It would be very useful if we could update env variables settings during deploy together with updating actual code.