GithubHelp home page GithubHelp logo

wms / artifactmanager-resource Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ai-labs-team/artifactmanager-resource

0.0 2.0 0.0 24 KB

Manages uploading and retrieving artifacts from a central repo

License: Apache License 2.0

Dockerfile 2.87% Makefile 2.51% Python 90.48% Shell 4.14%

artifactmanager-resource's Introduction

Artifact Manager Resource

This concourse plugin allows artifacts to be uploaded and retrieved based on path built from external inputs.

Currently only S3 is supported.

Source Configuration

  • driver : Required. The driver used to access the the file containing the version.

s3 Driver

  • bucket : Required. The name of the bucket.
  • region_name : Required. The s3 region being targeted.
  • access_key_id : Required. The AWS Key used to access the bucket.
  • secret_access_key : Required. The AWS access key used to access the bucket.

Params Configuration

  • local_path: Required for get. local path to upload from.
  • remote_path: Required for get and put. remote path to upload to or download from

Path Building

Example

Configuration with a build on patch:

resource_types:
- name: artifactManager-resource
  type: docker-image
  source:
    repository: lukaszz/artifact-manager-resource
    tag: 0.0.6

resources:
- name: store-files
  type: artifactManager-resource
  source:
    driver: s3
    region_name: us-west-2
    bucket: app.builds
    access_key_id: ((s3-key-id))
    secret_access_key: ((s3-access-key))

job:
- name: get-put-artifacts
  - get: store-files
    params:
      remote_path:
      - artifact-manager
      - type: s3
        bucket: app.config
        key: testing/version/api.txt
      - files
  - task: something-to-do
    file: location/of/something-to-do.yml
  - put: store-files
    params:
      local_path:
      - generated-files
      remote_path:
      - artifact-manager
      - type: file
        path: test-version/version
      - files

Behavior

The path is built from passed in params. in takes a remote_path while out takes both a remote_path and local_path.

check : Provide a timestamp

  • Provides a timestamp for the download. Currently does not actually check if the artifact exists. Since the artifacts it is getting are identified at runtime

in : Download the files indicated in params

note: in does not have access to local inputs, it can only build paths from remote resources and strings.

  - get: store-files
    params:
      remote_path:
      - artifact-manager
      - type: s3
        bucket: app.config
        key: testing/version/api.txt
      - files

Assuming the file in s3://app.config/testing/version/api.txt contains: 0.0.2

The following would create a path containing: artifact-manager/0.0.2/files

the contents of artifact-manager/0.0.2/files would be downloaded locally into the input store-files

out: Upload the files indicated in params

  - put: store-files
    params:
      local_path:
      - generated-files
      remote_path:
      - artifact-manager
      - type: file
        path: test-version/version
      - files

Assuming ths file in test-version/version contains: 0.0.2

The following would create a path containing: artifact-manager/0.0.2/files

The contents of the local_path generated-files would be uploaded to the s3 path artifact-manager/0.0.2/files

Contributing

Please see Contrib.md

artifactmanager-resource's People

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.