Trent Larson
9 months ago
commit
b52ebbf0ff
5 changed files with 825 additions and 0 deletions
@ -0,0 +1,4 @@ |
|||
.env |
|||
node_modules |
|||
uploads |
|||
|
@ -0,0 +1,15 @@ |
|||
# Image Server |
|||
|
|||
## setup |
|||
|
|||
``` |
|||
sh <(curl https://pkgx.sh) +pnpm sh |
|||
pnpm install |
|||
# manually set the AWS_ variables inside the .env file |
|||
``` |
|||
|
|||
## dev |
|||
|
|||
``` |
|||
node server.js |
|||
``` |
@ -0,0 +1,12 @@ |
|||
{ |
|||
"name": "image-trade", |
|||
"version": "0.0.1", |
|||
"description": "", |
|||
"license": "UNLICENSED", |
|||
"dependencies": { |
|||
"aws-sdk": "^2.1564.0", |
|||
"dotenv": "^16.4.5", |
|||
"express": "^4.18.2", |
|||
"multer": "1.4.5-lts.1" |
|||
} |
|||
} |
@ -0,0 +1,745 @@ |
|||
lockfileVersion: '6.0' |
|||
|
|||
settings: |
|||
autoInstallPeers: true |
|||
excludeLinksFromLockfile: false |
|||
|
|||
dependencies: |
|||
aws-sdk: |
|||
specifier: ^2.1564.0 |
|||
version: 2.1564.0 |
|||
dotenv: |
|||
specifier: ^16.4.5 |
|||
version: 16.4.5 |
|||
express: |
|||
specifier: ^4.18.2 |
|||
version: 4.18.2 |
|||
multer: |
|||
specifier: 1.4.5-lts.1 |
|||
version: 1.4.5-lts.1 |
|||
|
|||
packages: |
|||
|
|||
/accepts@1.3.8: |
|||
resolution: {integrity: sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==} |
|||
engines: {node: '>= 0.6'} |
|||
dependencies: |
|||
mime-types: 2.1.35 |
|||
negotiator: 0.6.3 |
|||
dev: false |
|||
|
|||
/append-field@1.0.0: |
|||
resolution: {integrity: sha512-klpgFSWLW1ZEs8svjfb7g4qWY0YS5imI82dTg+QahUvJ8YqAY0P10Uk8tTyh9ZGuYEZEMaeJYCF5BFuX552hsw==} |
|||
dev: false |
|||
|
|||
/array-flatten@1.1.1: |
|||
resolution: {integrity: sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==} |
|||
dev: false |
|||
|
|||
/available-typed-arrays@1.0.7: |
|||
resolution: {integrity: sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==} |
|||
engines: {node: '>= 0.4'} |
|||
dependencies: |
|||
possible-typed-array-names: 1.0.0 |
|||
dev: false |
|||
|
|||
/aws-sdk@2.1564.0: |
|||
resolution: {integrity: sha512-597Ugza41QCTknjv2VDeUMBFHvHVdg/h9qydDwnX+2kK/EcdE+Vjopcz2+lhHBlbqLi9yUbT4yc1nfo8T+f53w==} |
|||
engines: {node: '>= 10.0.0'} |
|||
dependencies: |
|||
buffer: 4.9.2 |
|||
events: 1.1.1 |
|||
ieee754: 1.1.13 |
|||
jmespath: 0.16.0 |
|||
querystring: 0.2.0 |
|||
sax: 1.2.1 |
|||
url: 0.10.3 |
|||
util: 0.12.5 |
|||
uuid: 8.0.0 |
|||
xml2js: 0.6.2 |
|||
dev: false |
|||
|
|||
/base64-js@1.5.1: |
|||
resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==} |
|||
dev: false |
|||
|
|||
/body-parser@1.20.1: |
|||
resolution: {integrity: sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==} |
|||
engines: {node: '>= 0.8', npm: 1.2.8000 || >= 1.4.16} |
|||
dependencies: |
|||
bytes: 3.1.2 |
|||
content-type: 1.0.5 |
|||
debug: 2.6.9 |
|||
depd: 2.0.0 |
|||
destroy: 1.2.0 |
|||
http-errors: 2.0.0 |
|||
iconv-lite: 0.4.24 |
|||
on-finished: 2.4.1 |
|||
qs: 6.11.0 |
|||
raw-body: 2.5.1 |
|||
type-is: 1.6.18 |
|||
unpipe: 1.0.0 |
|||
transitivePeerDependencies: |
|||
- supports-color |
|||
dev: false |
|||
|
|||
/buffer-from@1.1.2: |
|||
resolution: {integrity: sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==} |
|||
dev: false |
|||
|
|||
/buffer@4.9.2: |
|||
resolution: {integrity: sha512-xq+q3SRMOxGivLhBNaUdC64hDTQwejJ+H0T/NB1XMtTVEwNTrfFF3gAxiyW0Bu/xWEGhjVKgUcMhCrUy2+uCWg==} |
|||
dependencies: |
|||
base64-js: 1.5.1 |
|||
ieee754: 1.1.13 |
|||
isarray: 1.0.0 |
|||
dev: false |
|||
|
|||
/busboy@1.6.0: |
|||
resolution: {integrity: sha512-8SFQbg/0hQ9xy3UNTB0YEnsNBbWfhf7RtnzpL7TkBiTBRfrQ9Fxcnz7VJsleJpyp6rVLvXiuORqjlHi5q+PYuA==} |
|||
engines: {node: '>=10.16.0'} |
|||
dependencies: |
|||
streamsearch: 1.1.0 |
|||
dev: false |
|||
|
|||
/bytes@3.1.2: |
|||
resolution: {integrity: sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==} |
|||
engines: {node: '>= 0.8'} |
|||
dev: false |
|||
|
|||
/call-bind@1.0.7: |
|||
resolution: {integrity: sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==} |
|||
engines: {node: '>= 0.4'} |
|||
dependencies: |
|||
es-define-property: 1.0.0 |
|||
es-errors: 1.3.0 |
|||
function-bind: 1.1.2 |
|||
get-intrinsic: 1.2.4 |
|||
set-function-length: 1.2.1 |
|||
dev: false |
|||
|
|||
/concat-stream@1.6.2: |
|||
resolution: {integrity: sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw==} |
|||
engines: {'0': node >= 0.8} |
|||
dependencies: |
|||
buffer-from: 1.1.2 |
|||
inherits: 2.0.4 |
|||
readable-stream: 2.3.8 |
|||
typedarray: 0.0.6 |
|||
dev: false |
|||
|
|||
/content-disposition@0.5.4: |
|||
resolution: {integrity: sha512-FveZTNuGw04cxlAiWbzi6zTAL/lhehaWbTtgluJh4/E95DqMwTmha3KZN1aAWA8cFIhHzMZUvLevkw5Rqk+tSQ==} |
|||
engines: {node: '>= 0.6'} |
|||
dependencies: |
|||
safe-buffer: 5.2.1 |
|||
dev: false |
|||
|
|||
/content-type@1.0.5: |
|||
resolution: {integrity: sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==} |
|||
engines: {node: '>= 0.6'} |
|||
dev: false |
|||
|
|||
/cookie-signature@1.0.6: |
|||
resolution: {integrity: sha512-QADzlaHc8icV8I7vbaJXJwod9HWYp8uCqf1xa4OfNu1T7JVxQIrUgOWtHdNDtPiywmFbiS12VjotIXLrKM3orQ==} |
|||
dev: false |
|||
|
|||
/cookie@0.5.0: |
|||
resolution: {integrity: sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==} |
|||
engines: {node: '>= 0.6'} |
|||
dev: false |
|||
|
|||
/core-util-is@1.0.3: |
|||
resolution: {integrity: sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==} |
|||
dev: false |
|||
|
|||
/debug@2.6.9: |
|||
resolution: {integrity: sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==} |
|||
peerDependencies: |
|||
supports-color: '*' |
|||
peerDependenciesMeta: |
|||
supports-color: |
|||
optional: true |
|||
dependencies: |
|||
ms: 2.0.0 |
|||
dev: false |
|||
|
|||
/define-data-property@1.1.4: |
|||
resolution: {integrity: sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==} |
|||
engines: {node: '>= 0.4'} |
|||
dependencies: |
|||
es-define-property: 1.0.0 |
|||
es-errors: 1.3.0 |
|||
gopd: 1.0.1 |
|||
dev: false |
|||
|
|||
/depd@2.0.0: |
|||
resolution: {integrity: sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==} |
|||
engines: {node: '>= 0.8'} |
|||
dev: false |
|||
|
|||
/destroy@1.2.0: |
|||
resolution: {integrity: sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg==} |
|||
engines: {node: '>= 0.8', npm: 1.2.8000 || >= 1.4.16} |
|||
dev: false |
|||
|
|||
/dotenv@16.4.5: |
|||
resolution: {integrity: sha512-ZmdL2rui+eB2YwhsWzjInR8LldtZHGDoQ1ugH85ppHKwpUHL7j7rN0Ti9NCnGiQbhaZ11FpR+7ao1dNsmduNUg==} |
|||
engines: {node: '>=12'} |
|||
dev: false |
|||
|
|||
/ee-first@1.1.1: |
|||
resolution: {integrity: sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==} |
|||
dev: false |
|||
|
|||
/encodeurl@1.0.2: |
|||
resolution: {integrity: sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==} |
|||
engines: {node: '>= 0.8'} |
|||
dev: false |
|||
|
|||
/es-define-property@1.0.0: |
|||
resolution: {integrity: sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==} |
|||
engines: {node: '>= 0.4'} |
|||
dependencies: |
|||
get-intrinsic: 1.2.4 |
|||
dev: false |
|||
|
|||
/es-errors@1.3.0: |
|||
resolution: {integrity: sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==} |
|||
engines: {node: '>= 0.4'} |
|||
dev: false |
|||
|
|||
/escape-html@1.0.3: |
|||
resolution: {integrity: sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==} |
|||
dev: false |
|||
|
|||
/etag@1.8.1: |
|||
resolution: {integrity: sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==} |
|||
engines: {node: '>= 0.6'} |
|||
dev: false |
|||
|
|||
/events@1.1.1: |
|||
resolution: {integrity: sha512-kEcvvCBByWXGnZy6JUlgAp2gBIUjfCAV6P6TgT1/aaQKcmuAEC4OZTV1I4EWQLz2gxZw76atuVyvHhTxvi0Flw==} |
|||
engines: {node: '>=0.4.x'} |
|||
dev: false |
|||
|
|||
/express@4.18.2: |
|||
resolution: {integrity: sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==} |
|||
engines: {node: '>= 0.10.0'} |
|||
dependencies: |
|||
accepts: 1.3.8 |
|||
array-flatten: 1.1.1 |
|||
body-parser: 1.20.1 |
|||
content-disposition: 0.5.4 |
|||
content-type: 1.0.5 |
|||
cookie: 0.5.0 |
|||
cookie-signature: 1.0.6 |
|||
debug: 2.6.9 |
|||
depd: 2.0.0 |
|||
encodeurl: 1.0.2 |
|||
escape-html: 1.0.3 |
|||
etag: 1.8.1 |
|||
finalhandler: 1.2.0 |
|||
fresh: 0.5.2 |
|||
http-errors: 2.0.0 |
|||
merge-descriptors: 1.0.1 |
|||
methods: 1.1.2 |
|||
on-finished: 2.4.1 |
|||
parseurl: 1.3.3 |
|||
path-to-regexp: 0.1.7 |
|||
proxy-addr: 2.0.7 |
|||
qs: 6.11.0 |
|||
range-parser: 1.2.1 |
|||
safe-buffer: 5.2.1 |
|||
send: 0.18.0 |
|||
serve-static: 1.15.0 |
|||
setprototypeof: 1.2.0 |
|||
statuses: 2.0.1 |
|||
type-is: 1.6.18 |
|||
utils-merge: 1.0.1 |
|||
vary: 1.1.2 |
|||
transitivePeerDependencies: |
|||
- supports-color |
|||
dev: false |
|||
|
|||
/finalhandler@1.2.0: |
|||
resolution: {integrity: sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg==} |
|||
engines: {node: '>= 0.8'} |
|||
dependencies: |
|||
debug: 2.6.9 |
|||
encodeurl: 1.0.2 |
|||
escape-html: 1.0.3 |
|||
on-finished: 2.4.1 |
|||
parseurl: 1.3.3 |
|||
statuses: 2.0.1 |
|||
unpipe: 1.0.0 |
|||
transitivePeerDependencies: |
|||
- supports-color |
|||
dev: false |
|||
|
|||
/for-each@0.3.3: |
|||
resolution: {integrity: sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==} |
|||
dependencies: |
|||
is-callable: 1.2.7 |
|||
dev: false |
|||
|
|||
/forwarded@0.2.0: |
|||
resolution: {integrity: sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==} |
|||
engines: {node: '>= 0.6'} |
|||
dev: false |
|||
|
|||
/fresh@0.5.2: |
|||
resolution: {integrity: sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q==} |
|||
engines: {node: '>= 0.6'} |
|||
dev: false |
|||
|
|||
/function-bind@1.1.2: |
|||
resolution: {integrity: sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==} |
|||
dev: false |
|||
|
|||
/get-intrinsic@1.2.4: |
|||
resolution: {integrity: sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==} |
|||
engines: {node: '>= 0.4'} |
|||
dependencies: |
|||
es-errors: 1.3.0 |
|||
function-bind: 1.1.2 |
|||
has-proto: 1.0.3 |
|||
has-symbols: 1.0.3 |
|||
hasown: 2.0.1 |
|||
dev: false |
|||
|
|||
/gopd@1.0.1: |
|||
resolution: {integrity: sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==} |
|||
dependencies: |
|||
get-intrinsic: 1.2.4 |
|||
dev: false |
|||
|
|||
/has-property-descriptors@1.0.2: |
|||
resolution: {integrity: sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==} |
|||
dependencies: |
|||
es-define-property: 1.0.0 |
|||
dev: false |
|||
|
|||
/has-proto@1.0.3: |
|||
resolution: {integrity: sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==} |
|||
engines: {node: '>= 0.4'} |
|||
dev: false |
|||
|
|||
/has-symbols@1.0.3: |
|||
resolution: {integrity: sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==} |
|||
engines: {node: '>= 0.4'} |
|||
dev: false |
|||
|
|||
/has-tostringtag@1.0.2: |
|||
resolution: {integrity: sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==} |
|||
engines: {node: '>= 0.4'} |
|||
dependencies: |
|||
has-symbols: 1.0.3 |
|||
dev: false |
|||
|
|||
/hasown@2.0.1: |
|||
resolution: {integrity: sha512-1/th4MHjnwncwXsIW6QMzlvYL9kG5e/CpVvLRZe4XPa8TOUNbCELqmvhDmnkNsAjwaG4+I8gJJL0JBvTTLO9qA==} |
|||
engines: {node: '>= 0.4'} |
|||
dependencies: |
|||
function-bind: 1.1.2 |
|||
dev: false |
|||
|
|||
/http-errors@2.0.0: |
|||
resolution: {integrity: sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ==} |
|||
engines: {node: '>= 0.8'} |
|||
dependencies: |
|||
depd: 2.0.0 |
|||
inherits: 2.0.4 |
|||
setprototypeof: 1.2.0 |
|||
statuses: 2.0.1 |
|||
toidentifier: 1.0.1 |
|||
dev: false |
|||
|
|||
/iconv-lite@0.4.24: |
|||
resolution: {integrity: sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==} |
|||
engines: {node: '>=0.10.0'} |
|||
dependencies: |
|||
safer-buffer: 2.1.2 |
|||
dev: false |
|||
|
|||
/ieee754@1.1.13: |
|||
resolution: {integrity: sha512-4vf7I2LYV/HaWerSo3XmlMkp5eZ83i+/CDluXi/IGTs/O1sejBNhTtnxzmRZfvOUqj7lZjqHkeTvpgSFDlWZTg==} |
|||
dev: false |
|||
|
|||
/inherits@2.0.4: |
|||
resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} |
|||
dev: false |
|||
|
|||
/ipaddr.js@1.9.1: |
|||
resolution: {integrity: sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==} |
|||
engines: {node: '>= 0.10'} |
|||
dev: false |
|||
|
|||
/is-arguments@1.1.1: |
|||
resolution: {integrity: sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==} |
|||
engines: {node: '>= 0.4'} |
|||
dependencies: |
|||
call-bind: 1.0.7 |
|||
has-tostringtag: 1.0.2 |
|||
dev: false |
|||
|
|||
/is-callable@1.2.7: |
|||
resolution: {integrity: sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==} |
|||
engines: {node: '>= 0.4'} |
|||
dev: false |
|||
|
|||
/is-generator-function@1.0.10: |
|||
resolution: {integrity: sha512-jsEjy9l3yiXEQ+PsXdmBwEPcOxaXWLspKdplFUVI9vq1iZgIekeC0L167qeu86czQaxed3q/Uzuw0swL0irL8A==} |
|||
engines: {node: '>= 0.4'} |
|||
dependencies: |
|||
has-tostringtag: 1.0.2 |
|||
dev: false |
|||
|
|||
/is-typed-array@1.1.13: |
|||
resolution: {integrity: sha512-uZ25/bUAlUY5fR4OKT4rZQEBrzQWYV9ZJYGGsUmEJ6thodVJ1HX64ePQ6Z0qPWP+m+Uq6e9UugrE38jeYsDSMw==} |
|||
engines: {node: '>= 0.4'} |
|||
dependencies: |
|||
which-typed-array: 1.1.14 |
|||
dev: false |
|||
|
|||
/isarray@1.0.0: |
|||
resolution: {integrity: sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==} |
|||
dev: false |
|||
|
|||
/jmespath@0.16.0: |
|||
resolution: {integrity: sha512-9FzQjJ7MATs1tSpnco1K6ayiYE3figslrXA72G2HQ/n76RzvYlofyi5QM+iX4YRs/pu3yzxlVQSST23+dMDknw==} |
|||
engines: {node: '>= 0.6.0'} |
|||
dev: false |
|||
|
|||
/media-typer@0.3.0: |
|||
resolution: {integrity: sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ==} |
|||
engines: {node: '>= 0.6'} |
|||
dev: false |
|||
|
|||
/merge-descriptors@1.0.1: |
|||
resolution: {integrity: sha512-cCi6g3/Zr1iqQi6ySbseM1Xvooa98N0w31jzUYrXPX2xqObmFGHJ0tQ5u74H3mVh7wLouTseZyYIq39g8cNp1w==} |
|||
dev: false |
|||
|
|||
/methods@1.1.2: |
|||
resolution: {integrity: sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w==} |
|||
engines: {node: '>= 0.6'} |
|||
dev: false |
|||
|
|||
/mime-db@1.52.0: |
|||
resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} |
|||
engines: {node: '>= 0.6'} |
|||
dev: false |
|||
|
|||
/mime-types@2.1.35: |
|||
resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==} |
|||
engines: {node: '>= 0.6'} |
|||
dependencies: |
|||
mime-db: 1.52.0 |
|||
dev: false |
|||
|
|||
/mime@1.6.0: |
|||
resolution: {integrity: sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==} |
|||
engines: {node: '>=4'} |
|||
hasBin: true |
|||
dev: false |
|||
|
|||
/minimist@1.2.8: |
|||
resolution: {integrity: sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==} |
|||
dev: false |
|||
|
|||
/mkdirp@0.5.6: |
|||
resolution: {integrity: sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==} |
|||
hasBin: true |
|||
dependencies: |
|||
minimist: 1.2.8 |
|||
dev: false |
|||
|
|||
/ms@2.0.0: |
|||
resolution: {integrity: sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==} |
|||
dev: false |
|||
|
|||
/ms@2.1.3: |
|||
resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==} |
|||
dev: false |
|||
|
|||
/multer@1.4.5-lts.1: |
|||
resolution: {integrity: sha512-ywPWvcDMeH+z9gQq5qYHCCy+ethsk4goepZ45GLD63fOu0YcNecQxi64nDs3qluZB+murG3/D4dJ7+dGctcCQQ==} |
|||
engines: {node: '>= 6.0.0'} |
|||
dependencies: |
|||
append-field: 1.0.0 |
|||
busboy: 1.6.0 |
|||
concat-stream: 1.6.2 |
|||
mkdirp: 0.5.6 |
|||
object-assign: 4.1.1 |
|||
type-is: 1.6.18 |
|||
xtend: 4.0.2 |
|||
dev: false |
|||
|
|||
/negotiator@0.6.3: |
|||
resolution: {integrity: sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==} |
|||
engines: {node: '>= 0.6'} |
|||
dev: false |
|||
|
|||
/object-assign@4.1.1: |
|||
resolution: {integrity: sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==} |
|||
engines: {node: '>=0.10.0'} |
|||
dev: false |
|||
|
|||
/object-inspect@1.13.1: |
|||
resolution: {integrity: sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==} |
|||
dev: false |
|||
|
|||
/on-finished@2.4.1: |
|||
resolution: {integrity: sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg==} |
|||
engines: {node: '>= 0.8'} |
|||
dependencies: |
|||
ee-first: 1.1.1 |
|||
dev: false |
|||
|
|||
/parseurl@1.3.3: |
|||
resolution: {integrity: sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==} |
|||
engines: {node: '>= 0.8'} |
|||
dev: false |
|||
|
|||
/path-to-regexp@0.1.7: |
|||
resolution: {integrity: sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ==} |
|||
dev: false |
|||
|
|||
/possible-typed-array-names@1.0.0: |
|||
resolution: {integrity: sha512-d7Uw+eZoloe0EHDIYoe+bQ5WXnGMOpmiZFTuMWCwpjzzkL2nTjcKiAk4hh8TjnGye2TwWOk3UXucZ+3rbmBa8Q==} |
|||
engines: {node: '>= 0.4'} |
|||
dev: false |
|||
|
|||
/process-nextick-args@2.0.1: |
|||
resolution: {integrity: sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==} |
|||
dev: false |
|||
|
|||
/proxy-addr@2.0.7: |
|||
resolution: {integrity: sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg==} |
|||
engines: {node: '>= 0.10'} |
|||
dependencies: |
|||
forwarded: 0.2.0 |
|||
ipaddr.js: 1.9.1 |
|||
dev: false |
|||
|
|||
/punycode@1.3.2: |
|||
resolution: {integrity: sha512-RofWgt/7fL5wP1Y7fxE7/EmTLzQVnB0ycyibJ0OOHIlJqTNzglYFxVwETOcIoJqJmpDXJ9xImDv+Fq34F/d4Dw==} |
|||
dev: false |
|||
|
|||
/qs@6.11.0: |
|||
resolution: {integrity: sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==} |
|||
engines: {node: '>=0.6'} |
|||
dependencies: |
|||
side-channel: 1.0.5 |
|||
dev: false |
|||
|
|||
/querystring@0.2.0: |
|||
resolution: {integrity: sha512-X/xY82scca2tau62i9mDyU9K+I+djTMUsvwf7xnUX5GLvVzgJybOJf4Y6o9Zx3oJK/LSXg5tTZBjwzqVPaPO2g==} |
|||
engines: {node: '>=0.4.x'} |
|||
deprecated: The querystring API is considered Legacy. new code should use the URLSearchParams API instead. |
|||
dev: false |
|||
|
|||
/range-parser@1.2.1: |
|||
resolution: {integrity: sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==} |
|||
engines: {node: '>= 0.6'} |
|||
dev: false |
|||
|
|||
/raw-body@2.5.1: |
|||
resolution: {integrity: sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==} |
|||
engines: {node: '>= 0.8'} |
|||
dependencies: |
|||
bytes: 3.1.2 |
|||
http-errors: 2.0.0 |
|||
iconv-lite: 0.4.24 |
|||
unpipe: 1.0.0 |
|||
dev: false |
|||
|
|||
/readable-stream@2.3.8: |
|||
resolution: {integrity: sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==} |
|||
dependencies: |
|||
core-util-is: 1.0.3 |
|||
inherits: 2.0.4 |
|||
isarray: 1.0.0 |
|||
process-nextick-args: 2.0.1 |
|||
safe-buffer: 5.1.2 |
|||
string_decoder: 1.1.1 |
|||
util-deprecate: 1.0.2 |
|||
dev: false |
|||
|
|||
/safe-buffer@5.1.2: |
|||
resolution: {integrity: sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==} |
|||
dev: false |
|||
|
|||
/safe-buffer@5.2.1: |
|||
resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} |
|||
dev: false |
|||
|
|||
/safer-buffer@2.1.2: |
|||
resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} |
|||
dev: false |
|||
|
|||
/sax@1.2.1: |
|||
resolution: {integrity: sha512-8I2a3LovHTOpm7NV5yOyO8IHqgVsfK4+UuySrXU8YXkSRX7k6hCV9b3HrkKCr3nMpgj+0bmocaJJWpvp1oc7ZA==} |
|||
dev: false |
|||
|
|||
/send@0.18.0: |
|||
resolution: {integrity: sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==} |
|||
engines: {node: '>= 0.8.0'} |
|||
dependencies: |
|||
debug: 2.6.9 |
|||
depd: 2.0.0 |
|||
destroy: 1.2.0 |
|||
encodeurl: 1.0.2 |
|||
escape-html: 1.0.3 |
|||
etag: 1.8.1 |
|||
fresh: 0.5.2 |
|||
http-errors: 2.0.0 |
|||
mime: 1.6.0 |
|||
ms: 2.1.3 |
|||
on-finished: 2.4.1 |
|||
range-parser: 1.2.1 |
|||
statuses: 2.0.1 |
|||
transitivePeerDependencies: |
|||
- supports-color |
|||
dev: false |
|||
|
|||
/serve-static@1.15.0: |
|||
resolution: {integrity: sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==} |
|||
engines: {node: '>= 0.8.0'} |
|||
dependencies: |
|||
encodeurl: 1.0.2 |
|||
escape-html: 1.0.3 |
|||
parseurl: 1.3.3 |
|||
send: 0.18.0 |
|||
transitivePeerDependencies: |
|||
- supports-color |
|||
dev: false |
|||
|
|||
/set-function-length@1.2.1: |
|||
resolution: {integrity: sha512-j4t6ccc+VsKwYHso+kElc5neZpjtq9EnRICFZtWyBsLojhmeF/ZBd/elqm22WJh/BziDe/SBiOeAt0m2mfLD0g==} |
|||
engines: {node: '>= 0.4'} |
|||
dependencies: |
|||
define-data-property: 1.1.4 |
|||
es-errors: 1.3.0 |
|||
function-bind: 1.1.2 |
|||
get-intrinsic: 1.2.4 |
|||
gopd: 1.0.1 |
|||
has-property-descriptors: 1.0.2 |
|||
dev: false |
|||
|
|||
/setprototypeof@1.2.0: |
|||
resolution: {integrity: sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==} |
|||
dev: false |
|||
|
|||
/side-channel@1.0.5: |
|||
resolution: {integrity: sha512-QcgiIWV4WV7qWExbN5llt6frQB/lBven9pqliLXfGPB+K9ZYXxDozp0wLkHS24kWCm+6YXH/f0HhnObZnZOBnQ==} |
|||
engines: {node: '>= 0.4'} |
|||
dependencies: |
|||
call-bind: 1.0.7 |
|||
es-errors: 1.3.0 |
|||
get-intrinsic: 1.2.4 |
|||
object-inspect: 1.13.1 |
|||
dev: false |
|||
|
|||
/statuses@2.0.1: |
|||
resolution: {integrity: sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==} |
|||
engines: {node: '>= 0.8'} |
|||
dev: false |
|||
|
|||
/streamsearch@1.1.0: |
|||
resolution: {integrity: sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg==} |
|||
engines: {node: '>=10.0.0'} |
|||
dev: false |
|||
|
|||
/string_decoder@1.1.1: |
|||
resolution: {integrity: sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==} |
|||
dependencies: |
|||
safe-buffer: 5.1.2 |
|||
dev: false |
|||
|
|||
/toidentifier@1.0.1: |
|||
resolution: {integrity: sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==} |
|||
engines: {node: '>=0.6'} |
|||
dev: false |
|||
|
|||
/type-is@1.6.18: |
|||
resolution: {integrity: sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==} |
|||
engines: {node: '>= 0.6'} |
|||
dependencies: |
|||
media-typer: 0.3.0 |
|||
mime-types: 2.1.35 |
|||
dev: false |
|||
|
|||
/typedarray@0.0.6: |
|||
resolution: {integrity: sha512-/aCDEGatGvZ2BIk+HmLf4ifCJFwvKFNb9/JeZPMulfgFracn9QFcAf5GO8B/mweUjSoblS5In0cWhqpfs/5PQA==} |
|||
dev: false |
|||
|
|||
/unpipe@1.0.0: |
|||
resolution: {integrity: sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==} |
|||
engines: {node: '>= 0.8'} |
|||
dev: false |
|||
|
|||
/url@0.10.3: |
|||
resolution: {integrity: sha512-hzSUW2q06EqL1gKM/a+obYHLIO6ct2hwPuviqTTOcfFVc61UbfJ2Q32+uGL/HCPxKqrdGB5QUwIe7UqlDgwsOQ==} |
|||
dependencies: |
|||
punycode: 1.3.2 |
|||
querystring: 0.2.0 |
|||
dev: false |
|||
|
|||
/util-deprecate@1.0.2: |
|||
resolution: {integrity: sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==} |
|||
dev: false |
|||
|
|||
/util@0.12.5: |
|||
resolution: {integrity: sha512-kZf/K6hEIrWHI6XqOFUiiMa+79wE/D8Q+NCNAWclkyg3b4d2k7s0QGepNjiABc+aR3N1PAyHL7p6UcLY6LmrnA==} |
|||
dependencies: |
|||
inherits: 2.0.4 |
|||
is-arguments: 1.1.1 |
|||
is-generator-function: 1.0.10 |
|||
is-typed-array: 1.1.13 |
|||
which-typed-array: 1.1.14 |
|||
dev: false |
|||
|
|||
/utils-merge@1.0.1: |
|||
resolution: {integrity: sha512-pMZTvIkT1d+TFGvDOqodOclx0QWkkgi6Tdoa8gC8ffGAAqz9pzPTZWAybbsHHoED/ztMtkv/VoYTYyShUn81hA==} |
|||
engines: {node: '>= 0.4.0'} |
|||
dev: false |
|||
|
|||
/uuid@8.0.0: |
|||
resolution: {integrity: sha512-jOXGuXZAWdsTH7eZLtyXMqUb9EcWMGZNbL9YcGBJl4MH4nrxHmZJhEHvyLFrkxo+28uLb/NYRcStH48fnD0Vzw==} |
|||
hasBin: true |
|||
dev: false |
|||
|
|||
/vary@1.1.2: |
|||
resolution: {integrity: sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==} |
|||
engines: {node: '>= 0.8'} |
|||
dev: false |
|||
|
|||
/which-typed-array@1.1.14: |
|||
resolution: {integrity: sha512-VnXFiIW8yNn9kIHN88xvZ4yOWchftKDsRJ8fEPacX/wl1lOvBrhsJ/OeJCXq7B0AaijRuqgzSKalJoPk+D8MPg==} |
|||
engines: {node: '>= 0.4'} |
|||
dependencies: |
|||
available-typed-arrays: 1.0.7 |
|||
call-bind: 1.0.7 |
|||
for-each: 0.3.3 |
|||
gopd: 1.0.1 |
|||
has-tostringtag: 1.0.2 |
|||
dev: false |
|||
|
|||
/xml2js@0.6.2: |
|||
resolution: {integrity: sha512-T4rieHaC1EXcES0Kxxj4JWgaUQHDk+qwHcYOCFHfiwKz7tOVPLq7Hjq9dM1WCMhylqMEfP7hMcOIChvotiZegA==} |
|||
engines: {node: '>=4.0.0'} |
|||
dependencies: |
|||
sax: 1.2.1 |
|||
xmlbuilder: 11.0.1 |
|||
dev: false |
|||
|
|||
/xmlbuilder@11.0.1: |
|||
resolution: {integrity: sha512-fDlsI/kFEx7gLvbecc0/ohLG50fugQp8ryHzMTuW9vSa1GJ0XYWKnhsUx7oie3G98+r56aTQIUB4kht42R3JvA==} |
|||
engines: {node: '>=4.0'} |
|||
dev: false |
|||
|
|||
/xtend@4.0.2: |
|||
resolution: {integrity: sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==} |
|||
engines: {node: '>=0.4'} |
|||
dev: false |
@ -0,0 +1,49 @@ |
|||
const AWS = require('aws-sdk'); |
|||
const express = require('express'); |
|||
const fs = require('fs'); |
|||
const multer = require('multer'); |
|||
const path = require('path'); |
|||
require('dotenv').config() |
|||
|
|||
const app = express(); |
|||
const port = 3000; |
|||
|
|||
// Configure AWS
|
|||
AWS.config.update({ |
|||
accessKeyId: process.env.AWS_ACCESS_KEY, |
|||
secretAccessKey: process.env.AWS_SECRET_KEY, |
|||
region: process.env.AWS_REGION, |
|||
}); |
|||
|
|||
const s3 = new AWS.S3(); |
|||
const upload = multer({ dest: 'uploads/' }); |
|||
|
|||
// POST endpoint to upload an image
|
|||
app.post('/image', upload.single('image'), (req, res) => { |
|||
const file = req.file; |
|||
|
|||
// Read the file from the temporary location
|
|||
fs.readFile(file.path, (err, data) => { |
|||
if (err) throw err; // Handle error
|
|||
|
|||
const params = { |
|||
Bucket: 'gifts-image', // S3 Bucket name
|
|||
Key: `${Date.now()}_${path.basename(file.originalname)}`, // File name to use in S3
|
|||
Body: data, |
|||
//ACL: 'public-read' // Optional: if you want the uploaded file to be publicly accessible
|
|||
}; |
|||
|
|||
// Upload the file to S3
|
|||
s3.upload(params, function(s3Err, data) { |
|||
if (s3Err) throw s3Err; // Handle upload error
|
|||
|
|||
// Once successfully uploaded to S3, send back the URL of the uploaded file
|
|||
res.send(`File uploaded successfully at ${data.Location}`); |
|||
}); |
|||
}); |
|||
}); |
|||
|
|||
app.listen(port, () => { |
|||
console.log(`Server running at http://localhost:${port}`); |
|||
}); |
|||
|
Loading…
Reference in new issue