New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Environment variable example #11
Comments
Thanks @danleecpi I've fixed that typo now. I have a guide here for Backblaze setup here which should help: https://github.com/weareferal/craft-remote-backup/wiki/Backblaze-B2 |
Here's the environment variables: https://github.com/weareferal/craft-remote-backup/wiki/Backblaze-B2#create-environment-variables
Bear in mind you can call the variables whatever you like as long as you reference them correctly from the Control Panel settings page. |
Thanks, I'm trying to run the following locally and on the server: I get the following error:
|
Interesting. I haven't run into that before. It looks like the Can you show your One option here is to fork the |
Here is the composer.json file contents:
|
@danleecpi it looks like there is a working fork with updated dependencies here Could you remove |
Yes that seems to install fine! |
Great, let me know if you've any other issues with it |
Thanks @timmyomahony Just run my first test. I get the following error:
This is my setup.I have defined my environment variables in the env file and aliases in general.php config file. env file
general.php
I then used the aliases in the plugin settings. |
Is that first image from the Craft queue? Are you on the same machine you installed the That error would suggest that it's an issue with the instance not finding the As an aside, you shouldn't needed env vars AND aliases. You can just reference the env vars directly into the control panel ( |
Yes, the first image is from the Craft queue. I can see it in the composer.lock file and composer.json files: Just tried installing again... this is what I get:
|
That's very strange. And you can see it in your |
Amazing - Ill give it a go on Monday |
Hi @timmyomahony, I'm guessing this is still in progress? |
Yep, just working on adding a new release now |
OK, https://github.com/weareferal/craft-remote-backup/wiki/Backblaze-B2 You will need to install: composer require aws/aws-sdk-php:^3 and also note the variables will be a little different than before: BACKBLAZE_B2_MASTER_KEY_ID="..."
BACKBLAZE_B2_MASTER_APP_KEY="..."
BACKBLAZE_B2_REGION_NAME="us-west-002" # don't include the "s3"
BACKBLAZE_B2_BUCKET_NAME="craft-backups"
BACKBLAZE_B2_BUCKET_PATH="mysite" I've been testing this new release today so let me know of any issues |
I have installed and tested. I have double-checked the credentials.
I checked the Access Key Id in backblaze again and it is correct. I'm a bit stumped. :) |
I got that error myself before. Did you go back and re-create the app key (outlined here)? Backblaze has two types of keys:
In this case, we need to use regular app keys that have been granted access to your new bucket (previously you could just use a master app key). If you have the wrong key set up then it could be showing this error as it can't access the bucket via the S3 API. |
I can replicate that error message when I use my master app key instead of a regular app key. I get the error:
EDIT: I've updated the guide to mention this: https://github.com/weareferal/craft-remote-backup/wiki/Backblaze-B2#malformed-access-key-id |
Thanks @timmyomahony If we have to use the regular app keys I'd suggest changing the label name on the fields settings. I copied in the regular app id and key and now I get a new error message. Do you know what it means?
|
Good idea @danleecpi, I've updated the labels on the backblaze settings page as well as in the docs: https://github.com/weareferal/craft-remote-backup/wiki/Backblaze-B2 Hopefull that will make it clearer. Regarding that error message, I haven't seen that before. Can you post the full stack trace? I would guess that it's related to the upload of the backup once it's been created. Are you backing up the database or the volumes (or both)? |
@timmyomahony what is the best way to send you the log files? |
Via email to timmy@weareferal.com, or you can find me on the Craft Discord username |
@danleecpi I'm going to close this now - hopefully we got the issue sorted for good! If it's still an issue let me know. (Recreating the B2 bucket as well as the app key seemed to sort the issue) |
Thanks! Seems to be working. |
Noticed in the AWS environment variable example you have AWS_BUCKET_NAME="feral-backups" twice.
AWS_ACCESS_KEY=
AWS_SECRET_KEY=
AWS_REGION="us-west-1"
AWS_BUCKET_NAME="feral-backups"
AWS_BUCKET_NAME="feral-backups"
AWS_BUCKET_SYNC_PREFIX="craft-sync/craft-test"
AWS_BUCKET_BACKUP_PREFIX="craft-backups/craft-test"
I'm setting up syncing for Backblaze what would the example be for that?
The text was updated successfully, but these errors were encountered: