npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

bosco-s3

v0.0.3

Published

Bosco s3 will take care of pushing assets to s3

Downloads

15

Readme

Bosco-s3

Bosco is a utility knife to help manage the complexity that using microservices, which naturally results in a large number of code repositories, brings with it. Inspired by the Github 'setup', e.g. can a developer run one simple command and get up and running?

Docs: https://bosco.readme.io/v0.4.0/docs/what-is-bosco

Please refer to the bosco documentation here https://github.com/tes/bosco, you can use this package to push assets to s3 using continuous integration without having to depend on the entire bosco.

Command List

Commands in Bosco are defined via specific command files within the 'commands' folder: https://github.com/tes/bosco/tree/master/commands.

To get help on any command just type;

bosco-s3 help s3push

Parameters

You can use a number of parameters to control the behaviour of Bosco. Parameters are configuration options that can be used across commands.

|parameter|description|default| |---------|-----------|--------| |-e, --environment|Environment name|local| |-b, --build|Build number or tag|default| |-c, --configFile|Config file|~/.bosco/bosco.json| |-p, --configPath|Config path|~/.bosco/bosco.json| |-n, --noprompt|Do not prompt for confirmation|false| |-f, --force|Force over ride of any files|false| |-s, --service|Inside single service|false| |--nocache|Ignore local cache for github projects|false| |--offline|Ignore expired cache of remote service data and use local if available|false|

To see all possible commands and parameters, just type 'bosco'.

S3 Push

This will create bundles for front end assets (JS, CSS, Templates), this command can be run across repositories in a workspace, but it is typically run within a single service (hence the -s parameter below) by a build server that dynamically assigns a build number.

bosco-s3 s3push -s -e <environment> -b <buildnumber>

This command requires that you have configured your AWS details for S3. Best to put these into a .bosco folder in the project workspace a per environment config, e.g. .bosco/tes.json.

{
    "aws": {
        "key": "XXXXXX",
        "secret": "XXXXXX",
        "bucket": "bucket-name",
        "region": "eu-west-1",
        "cdn": "https://dudu89lpwit3y.cloudfront.net"
    }
}

To then access the html fragments for compoxure, it follows a simple convention:

<cdn>/<environment>/<build>/<type>/<bundle>.<fragmentType>.<js|css|html|map|txt>

For example:

This would contain a fragment that has script a tag for all of the minified JS tagged in the bottom group.