-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add support for bitbucket pipes (#317)
- Loading branch information
Showing
7 changed files
with
146 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
********* | ||
BitBucket | ||
********* | ||
|
||
``easy_infra`` can be used as a BitBucket pipe. | ||
|
||
Using the pipe | ||
-------------- | ||
|
||
An example ``bitbucket-pipeline.yml`` is as follows:: | ||
|
||
--- | ||
image: | ||
name: atlassian/default-image:4 | ||
|
||
test: &test | ||
step: | ||
name: Test | ||
services: | ||
- docker | ||
script: | ||
- pipe: docker://seisollc/easy_infra:2024.01.01-terraform | ||
|
||
pipelines: | ||
default: | ||
- <<: *test | ||
|
||
Configuring the pipe | ||
-------------------- | ||
|
||
The pipe accepts the following variables:: | ||
|
||
+-----------------------+------------------------+------------------------------------------------------------+ | ||
| Variable | Default | Result | | ||
+=======================+========================+============================================================+ | ||
| ``COMMAND`` | ``terraform validate`` | Sets the command to run in the ``easy_infra`` container | | ||
+-----------------------+------------------------+------------------------------------------------------------+ | ||
| ``LEARNING_MODE`` | ``false`` | Sets ``LEARNING_MODE`` in the ``easy_infra`` container | | ||
+-----------------------+------------------------+------------------------------------------------------------+ | ||
| ``TERRAFORM_VERSION`` | N/A | Sets ``TERRAFORM_VERSION`` in the ``easy_infra`` container | | ||
+-----------------------+------------------------+------------------------------------------------------------+ | ||
|
||
For example:: | ||
|
||
--- | ||
deploy: &deploy | ||
step: | ||
name: Deploy | ||
services: | ||
- docker | ||
script: | ||
- pipe: docker://seisollc/easy_infra:2024.01.01-terraform | ||
variables: | ||
COMMAND: /bin/bash -c "terraform plan -out=plan.out && terraform apply -auto-approve plan.out" | ||
LEARNING_MODE: true | ||
TERRAFORM_VERSION: 1.6.6 | ||
|
||
pipelines: | ||
default: | ||
- <<: *deploy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,4 +14,5 @@ | |
Logging/index | ||
Hooks/index | ||
Cloning/index | ||
BitBucket/index | ||
Technical Details/index |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
--- | ||
NOTICE: | | ||
This is just for illustrative purposes; BitBucket requires that pipe.yml files be hosted on bitbucket so we use `pipe: docker://` in our examples to go direct | ||
to Docker Hub, bypassing the use of this file. | ||
--- | ||
name: Easy Infra (terraform) | ||
description: A docker container to simplify and secure the use of Infrastructure as Code (IaC) | ||
image: seiso/easy_infra:2024.01.01-terraform | ||
category: Security | ||
repository: https://github.com/seisollc/easy_infra | ||
maintainer: | ||
name: Seiso | ||
website: https://SeisoLLC.com/ | ||
vendor: | ||
name: Seiso | ||
website: https://SeisoLLC.com/ | ||
variables: | ||
- name: COMMAND | ||
default: "terraform validate" | ||
- name: LEARNING_MODE | ||
default: "false" | ||
- name: TERRAFORM_VERSION | ||
default: "$TERRAFORM_VERSION" | ||
tags: | ||
- seiso | ||
- security | ||
- terraform |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters