Skip to content

New setup project cannot deploy, "Failed with status 1 (1)" #328

@cofyc

Description

@cofyc

I run mina -S deploy get deploy script, It contains:

#!/usr/bin/env bash

# Bail out ASAP
set -e

....

# Determine $previous_path and other variables
[ -h "current" ] && [ -d "current" ] && previous_path=$(cd "current" >/dev/null && pwd -LP)
build_path="./tmp/build-`date +%s`$RANDOM"
version=$((`cat "/var/www/project/last_version" 2>/dev/null`+1))
release_path="releases/$version"
...

When getting last version with cat, it failed and exit because of last_version file is missing.

mina setup should create last_version file with 0, or deploy script check file exist or not.

At last, I create this file myself to work around this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions