Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Circleci project setup #139

Open
wants to merge 18 commits into
base: master
Choose a base branch
from
83 changes: 83 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
# Use the latest 2.1 version of CircleCI pipeline process engine.
# See: https://circleci.com/docs/2.0/configuration-reference
version: 2.1
commands: # a reusable command with parameters
print_pipeline_id:
# parameters:
# to:
# default: "world"
# type: string
steps:
# - run: echo "Hello <<parameters.to>>"
- run: echo ${CIRCLE_WORKFLOW_ID}

# Define a job to be invoked later in a workflow.
# See: https://circleci.com/docs/2.0/configuration-reference/#jobs
jobs:
say-hello:
# Specify the execution environment. You can specify an image from Dockerhub or use one of our Convenience Images from CircleCI's Developer Hub.
# See: https://circleci.com/docs/2.0/configuration-reference/#docker-machine-macos-windows-executor
docker:
- image: cimg/base:stable
# Add steps to the job
# See: https://circleci.com/docs/2.0/configuration-reference/#steps
steps:
- checkout
- run:
name: "Say hello"
command: "echo Hello, World!"
print_hello:
docker:
- image: circleci/node:13.8.0
steps:
- print_pipeline_id
- run:
name: "hello"
command: "echo hello"

print_world:
docker:
- image: circleci/node:13.8.0
steps:
- run:
name: "world"
command: "echo world"

save_hello_world_output:
docker:
- image: circleci/node:13.8.0
steps:
- run:
name: "cache"
command: |
echo "text to output here" > ~/output.txt
- persist_to_workspace:
root: ~/
paths:
- output.txt
print_output_file:
docker:
- image: circleci/node:13.8.0
steps:
- attach_workspace:
at: ~/
- run:
cat ~/output.txt



# Invoke jobs via workflows
# See: https://circleci.com/docs/2.0/configuration-reference/#workflows
workflows:
say-hello-workflow:
jobs:
- say-hello
- print_hello
- print_world:
requires:
- print_hello
- save_hello_world_output
- print_output_file:
requires:
- save_hello_world_output

3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# my-app

hello readme
1 change: 1 addition & 0 deletions ansible/dev
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
[tomcat]
ip of dev
#adding comment