Last active
July 23, 2017 03:40
-
-
Save hwayne/2ea51fddf991afcbc8c67624f5628052 to your computer and use it in GitHub Desktop.
AWS Data Pipelines
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
aws_pipeline = client.create_pipeline(name: pipeline_name, | |
unique_id: pipeline_uid, | |
description: 'Automatic') | |
begin | |
# AWS uses different JSON formats for CLI and ruby sdk. | |
tempjson = Tempfile.new('tempjson') | |
tempjson.write(JSON.dump(pipeline_schema)) | |
tempjson.rewind | |
`aws datapipeline put-pipeline-definition --pipeline-id #{aws_pipeline.pipeline_id} --pipeline-definition file://#{tempjson.path}` | |
ensure | |
tempjson.close; tempjson.unlink | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment