Giter Site home page Giter Site logo

prismaclouddevsecopsscanner / alphagov-asset-manager Goto Github PK

View Code? Open in Web Editor NEW

This project forked from alphagov/asset-manager

0.0 0.0 0.0 2.54 MB

Manages uploaded assets (images, PDFs etc.) for applications on GOV.UK

Home Page: https://docs.publishing.service.gov.uk/apps/asset-manager.html

License: MIT License

JavaScript 0.01% Ruby 97.56% HTML 1.98% Dockerfile 0.40% Procfile 0.05%

alphagov-asset-manager's Introduction

Asset Manager

Manages uploaded assets (images, PDFs etc.) for applications in the GOV.UK Publishing stack.

The app receives uploaded files from publishing applications and returns the URLs that they will be made available at. Before an asset is available to the public, it is virus scanned. Once a file is found to be clean, Asset Manager serves it at the previously generated URL. Unscanned or Infected files return a 404 Not Found error.

Scanning uses ClamAV and occurs asynchronously via govuk_sidekiq.

Technical Documentation

This is a Ruby on Rails app, and should follow our Rails app conventions.

You can use the GOV.UK Docker environment to run the application and its tests with all the necessary dependencies. Follow the usage instructions to get started.

Use GOV.UK Docker to run any commands that follow.

Running the test suite

bundle exec rspec

Assets on S3

All assets are uploaded to the S3 bucket via a separate govuk_sidekiq job triggered if virus scanning succeeds. Assets are currently still also saved to the NFS mount as per the original behaviour.

In non-production environments if the AWS_S3_BUCKET_NAME environment variable is not set, then a fake version of S3 (S3Storage::Fake) is used and the other AWS_* environment variables do not need to be set. In this case, files are saved to the local filesystem instead of S3 and are served via an instance of Rack::File mounted on the appropriate route path prefix.

Manuals and decisions

Check the docs directory for detailed instructions, including API documentation.

Licence

MIT License

alphagov-asset-manager's People

Contributors

alext avatar barrucadu avatar beckal avatar benthorner avatar brucebolt avatar callumknights avatar cbaines avatar cdccollins avatar chrisbashton avatar chrislo avatar chrisroos avatar danielburnley avatar dependabot-preview[bot] avatar dependabot-support avatar dependabot[bot] avatar elliotcm avatar floehopper avatar h-lame avatar jkempster34 avatar jonathanhallam avatar jordanhatch avatar kevindew avatar kushalp avatar murilodalri avatar nsabri1 avatar sengi avatar steventux avatar theseanything avatar thomasleese avatar tijmenb 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.