Skip to content
This repository has been archived by the owner on Feb 5, 2020. It is now read-only.

Is it possible to migrate from the standard FS storage to S3 somehow? #6

Open
apexskier opened this issue Jun 21, 2018 · 2 comments
Open

Comments

@apexskier
Copy link

Original question at: verdaccio/verdaccio#472 (comment)

@lenovouser:

@apexskier thanks for creating the plugin! Is it possible to migrate from the standard FS storage to > S3 somehow?

@apexskier
Copy link
Author

It should be, with a bit of manual work! The file structure is pretty close to exactly the same, since this project is based on the local storage plugin.

You'll need to upload the contents of your local storage to your s3 bucket (prefix it with your keyPrefix if you've configured one), then rename the file .sinopia-db.json to verdaccio-s3-db.json.

Something like this using the aws cli might work (untested):

AWS_PATH="s3://$BUCKET"
# if you have a key prefix
AWS_PATH="s3://$BUCKET/$KEY_PREFIX"

aws s3 sync "$PATH_TO_STORAGE" "$AWS_PATH"
aws s3 mv "$AWS_PATH/.sinopia-db.json" "$AWS_PATH/verdaccio-s3-db.json"

@apexskier apexskier added question Further information is requested help wanted Extra attention is needed and removed question Further information is requested help wanted Extra attention is needed labels Feb 9, 2019
@apexskier
Copy link
Author

Leaving this open for now, I want to add it to some documentation.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant