Domains for multiple version of a single project #4072
Answered
by
antonmedv
matfire
asked this question in
Help needed
-
Hey all, Just discovered this tool and it looks awesome. I deployed a Laravel app with it and it worked just fine. Now I'd like to have a staging environment on the same machine. Here's what the deploy file looks like: <?php
namespace Deployer;
require 'recipe/laravel.php';
// Config
set('repository', '[email protected]:repo');
add('shared_files', []);
add('shared_dirs', []);
add('writable_dirs', []);
// Hosts
host('main)
->set('remote_user', 'deployer')
->set('deploy_path', '/srv/apps/app')
->setLabels([
'env' => 'prod'
]);
host('staging')
->set('remote_user', 'deployer')
->set('deploy_path', '/srv/apps/staging')
->setLabels([
'env' => 'staging'
]);
// Hooks
after('deploy:failed', 'deploy:unlock');
task('build', function () {
cd('{{release_path}}');
run('npm install');
run('npm run build');
});
after('deploy:vendors', 'build'); Deploying main worked fine, but while trying to deploy staging works (in the sense that the files are copied over fine), I don't see a caddyfile being generated. Am I missing something in the config ? Thanks! |
Beta Was this translation helpful? Give feedback.
Answered by
antonmedv
May 14, 2025
Replies: 1 comment 1 reply
-
I think you need to run provision again. |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
matfire
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I think you need to run provision again.