use app manifest for build id

This commit is contained in:
keyan 2021-10-05 13:01:40 -07:00
parent bc0ec2c609
commit 61be400365
1 changed files with 4 additions and 4 deletions

View File

@ -1,11 +1,11 @@
const { withPlausibleProxy } = require('next-plausible') const { withPlausibleProxy } = require('next-plausible')
const data = require('/opt/elasticbeanstalk/deployment/app_version_manifest.json') // eslint-disable-line const { RuntimeSources } = require('/opt/elasticbeanstalk/deployment/app_version_manifest.json') // eslint-disable-line
console.error(data, process.env)
module.exports = withPlausibleProxy()({ module.exports = withPlausibleProxy()({
generateBuildId: async () => { generateBuildId: async () => {
return data.VersionLabel // use the app version which eb doesn't otherwise give us
// as the build id
return Object.keys(RuntimeSources['stacker.news'])[0]
}, },
async rewrites () { async rewrites () {
return [ return [