mirror of
https://github.com/symkat/MeshMage.git
synced 2024-09-20 14:56:05 +08:00
Fix bugs.
This commit is contained in:
parent
d6672fe1a8
commit
7b1ed50e60
|
@ -30,7 +30,7 @@ CREATE TABLE auth_password (
|
|||
|
||||
CREATE TABLE auth_token (
|
||||
id serial PRIMARY KEY,
|
||||
person_id int not null unique references person(id),
|
||||
person_id int not null references person(id),
|
||||
token text not null,
|
||||
created_at timestamptz not null default current_timestamp
|
||||
);
|
||||
|
|
|
@ -112,7 +112,7 @@ sub startup ($self) {
|
|||
filepath => $filepath,
|
||||
filename => $c->param('filename'),
|
||||
);
|
||||
});
|
||||
})->name( 'secure_file' );
|
||||
|
||||
# Send requests for / to the dashboard.
|
||||
$auth->get('/')->to(cb => sub ($c) {
|
||||
|
|
|
@ -139,7 +139,7 @@ sub register ( $self, $app, $config ) {
|
|||
Mojo::File->new( "$etc_path/Nebula.plist" )->copy_to( $dir );
|
||||
|
||||
# my $outfile = $job->app->filepath_for( nebula => $net_id, "${domain}_macos_intel.tgz" )VC
|
||||
my $outfile = $job->app->download_dir . "${domain}_macos.tgz";
|
||||
my $outfile = $job->app->files_dir . "/secure_download/${domain}_macos.tgz";
|
||||
|
||||
my $command = [qw( tar -C ), $tempdir, '-czf', $outfile, 'nebula' ];
|
||||
run3( $command );
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
adoption.</p>
|
||||
|
||||
<pre>
|
||||
curl -O -H 'X-Auth: [% $c.stash.person.create_auth_token %]' [% $c.url_for( '/download/' ~ $pending ).to_abs %]
|
||||
curl -O -H 'X-Auth: [% $c.stash.person.create_auth_token %]' [% $c.url_for( 'secure_file', 'filename', $pending ).to_abs %]
|
||||
tar -xzf [% $pending %]
|
||||
cd nebula
|
||||
|
||||
|
|
Loading…
Reference in a new issue