-
Notifications
You must be signed in to change notification settings - Fork 297
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
update aws sdk and image uploader #7555
Conversation
This is just to trigger a build with AWS credentials |
12d3565
to
01be580
Compare
Ready for review |
- fix js code - add test images
Addresses the feedback, tested and verified to work locally. @nick-mon1 |
- fix bug in task - log changes to files
…update-aws-sdk-and-image-uploader
This pull request also contains the fix for this Security Issue https://github.com/GSA/digitalgov.gov/security/dependabot/43
|
1535878
to
c6988a7
Compare
I'll dive into this tomorrow. Thanks @mejiaj |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ I was able to successfully upload an image and see it on digitalgov
bucket. But no go for uploading files, see my suggestion for getting around the InvalidBucketName: Bucket name shouldn't contain '/', received 'digitalgov/static'
error.
Hey @mejiaj.
Should we be putting them in
|
@mejiaj I did manage to find you uploads. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@RileySeaburg the directory content/uploads/_inbox/
is correct. The original description had it in content/uploads
, but I updated it for others testing.
I was able to upload successfully without any issues, thanks for looking into the issues!
I've approved PR and requested another review for @nick-mon1.
@RileySeaburg I added some fixes for uploading files. I was able to successfully upload an file: [10:15:58] Using gulpfile ~/Documents/gsa/digitalgov.gov/gulpfile.js
[10:15:58] Starting 'upload'...
[10:15:58] Starting 'fileTidy'...
[10:15:58] Finished 'fileTidy' after 571 μs
[10:15:58] Starting 'cleanInbox'...
[10:15:58] Finished 'cleanInbox' after 11 ms
[10:15:58] Starting 'writeDataFile'...
[10:15:58] Finished 'writeDataFile' after 25 ms
[10:15:58] Starting 'processImages'...
[10:15:58] Finished 'processImages' after 290 μs
[10:15:58] Starting 'removeProcessedImage'...
Removing processed images
No images to process
Error processing file: [undefined]. ENOENT: no such file or directory, scandir './content/uploads/_working-images/to-process'
[10:15:58] Finished 'removeProcessedImage' after 1.96 ms
[10:15:58] Starting 'uploadImage'...
[10:15:58] Finished 'uploadImage' after 7.78 ms
[10:15:58] Starting 'uploadFile'...
file is written
(node:41977) [DEP0180] DeprecationWarning: fs.Stats constructor is deprecated.
(Use `node --trace-deprecation ...` to show where the warning was created)
[10:16:10] [create] static/s3-test-uswds-monthly-call-may-2024.pptx
[10:16:11] Finished 'uploadFile' after 12 s
[10:16:11] Starting 'cleanup'...
cleanup
[10:16:11] Finished 'cleanup' after 5.42 ms
[10:16:11] Finished 'upload' after 12 s ![]() Give this a quick test and then I can approve. |
@nick-mon1 I got a successful file upload and a consistent file name. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you both,
I was able to successfully test uploads (both files & images) via npx gulp upload
.
Summary
Replaces outdate
gulp-s3-upload
package withawspublish
package and closes #7554.Solution
How To Test
/content/uploads/_inbox/
npx gulp upload
Dev Checklist