1 Respuesta
- Más nuevo
- Más votos
- Más comentarios
0
I did those steps :
1 - Sign in to the AWS Management Console and open the CodePipeline console at http://console.aws.amazon.com/codesuite/codepipeline/home.
2 - Choose the pipeline => choose Edit. On the stage that contains your CodeBuild action, choose Edit stage.
3- Choose the icon to edit your CodeBuild action.
4 - On the Edit action page, under Environment variables, enter the following:
-
In Name, enter a name for your environment variable.
-
In Value, enter the variable syntax for your pipeline output variable: #{SourceVariables.BranchName}.
-
In Type, choose Plaintext.
then in code buildSpec you access the resolved value like $VAR_NAME
respondido hace 2 años
Contenido relevante
- OFICIAL DE AWSActualizada hace 3 años
- OFICIAL DE AWSActualizada hace 2 años
- ¿Cómo puedo transferir variables de mi entorno de Elastic Beanstalk a instancias de Linux y Windows?OFICIAL DE AWSActualizada hace 2 años
- OFICIAL DE AWSActualizada hace un año
I added in code Build => environment variables section an env var :
BRANCH_NAME, #{SourceVariables.BranchName}, plaintext
when I read it in code build I have an output string equals to "#{SourceVariables.BranchName}" instead of "main"