Updated the CMS to have the ability to choose the Banner image
This commit is contained in:
@@ -1,12 +1,25 @@
|
||||
module.exports = [
|
||||
'strapi::logger',
|
||||
'strapi::errors',
|
||||
'strapi::security',
|
||||
'strapi::cors',
|
||||
'strapi::poweredBy',
|
||||
'strapi::query',
|
||||
'strapi::body',
|
||||
'strapi::session',
|
||||
'strapi::favicon',
|
||||
'strapi::public',
|
||||
"strapi::logger",
|
||||
"strapi::errors",
|
||||
{
|
||||
name: "strapi::security",
|
||||
config: {
|
||||
contentSecurityPolicy: {
|
||||
useDefaults: true,
|
||||
directives: {
|
||||
"connect-src": ["'self'", "https:"],
|
||||
"img-src": ["'self'", "data:", "blob:", "storage.googleapis.com"],
|
||||
"media-src": ["'self'", "data:", "blob:", "storage.googleapis.com"],
|
||||
upgradeInsecureRequests: null,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
"strapi::cors",
|
||||
"strapi::poweredBy",
|
||||
"strapi::query",
|
||||
"strapi::body",
|
||||
"strapi::session",
|
||||
"strapi::favicon",
|
||||
"strapi::public",
|
||||
];
|
||||
|
||||
@@ -1 +1,25 @@
|
||||
module.exports = () => ({});
|
||||
module.exports = ({ env }) => {
|
||||
const serviceAccount = JSON.parse(atob(env("GCS_SERVICE_ACCOUNT")));
|
||||
|
||||
return {
|
||||
upload: {
|
||||
config: {
|
||||
provider:
|
||||
"@strapi-community/strapi-provider-upload-google-cloud-storage",
|
||||
providerOptions: {
|
||||
bucketName: env("GCS_BUCKET_NAME"),
|
||||
publicFiles: true,
|
||||
uniform: false,
|
||||
gzip: true,
|
||||
serviceAccount: {
|
||||
...serviceAccount,
|
||||
private_key: serviceAccount.private_key
|
||||
.split(String.raw`\n`)
|
||||
.join("\n"),
|
||||
},
|
||||
basePath: "",
|
||||
},
|
||||
},
|
||||
},
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user