Skip to content

Commit

Permalink
Fix issues with config loading.
Browse files Browse the repository at this point in the history
  • Loading branch information
reynoldsalec committed Mar 6, 2024
1 parent ab0badb commit 6c64122
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 6 deletions.
7 changes: 6 additions & 1 deletion builders/mean.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

// Modules
const _ = require('lodash');
const fs = require('fs');
const path = require('path');
const utils = require('./../lib/utils');

Expand Down Expand Up @@ -88,10 +89,13 @@ module.exports = {
confSrc: path.resolve(__dirname, '..', 'config'),
command: 'npm start',
database: 'mongo:7.0',
defaultFiles: {
},
globals: {},
node: '18',
port: '80',
ssl: false,
proxy: {},
},
builder: (parent, config) => class LandoMean extends parent {
constructor(id, options = {}) {
Expand All @@ -100,7 +104,8 @@ module.exports = {
options.services = _.merge({}, getServices(options), options.services);
options.tooling = _.merge({}, getTooling(options), options.tooling);
options.proxy = _.set({}, 'appserver', [`${options.app}.${options._app._config.domain}:${options.port}`]);
super(id, options);
// Send downstream
super(id, _.merge({}, config, options));
};
},
};
7 changes: 6 additions & 1 deletion examples/mean-custom/.lando.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,9 @@ config:
node: '14'
port: '8055'
database: mysql
config: config/mysql.cnf
config:
database: config/mysql.cnf

# do not remove this
plugins:
"@lando/mean": ../..
5 changes: 1 addition & 4 deletions examples/mean-custom/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,8 @@ Start up tests
Run the following commands to get up and running with this example.

```bash
# Should poweroff
# Should poweroff and start successfully
lando poweroff

# Should start up successfully
cp ../../.lando.upstream.yml .lando.upstream.yml
lando start
```

Expand Down

0 comments on commit 6c64122

Please sign in to comment.