kopia lustrzana https://github.com/simonw/datasette
rodzic
848dec4deb
commit
f524510230
|
@ -72,7 +72,10 @@ def publish_subcommand(publish):
|
|||
"about_url": about_url,
|
||||
}
|
||||
|
||||
environment_variables = {}
|
||||
environment_variables = {
|
||||
# Avoid uvicorn error: https://github.com/simonw/datasette/issues/633
|
||||
"WEB_CONCURRENCY": "1"
|
||||
}
|
||||
if plugin_secret:
|
||||
extra_metadata["plugins"] = {}
|
||||
for plugin_name, plugin_setting, setting_value in plugin_secret:
|
||||
|
@ -164,7 +167,7 @@ def temporary_heroku_directory(
|
|||
if metadata_content:
|
||||
open("metadata.json", "w").write(json.dumps(metadata_content, indent=2))
|
||||
|
||||
open("runtime.txt", "w").write("python-3.6.8")
|
||||
open("runtime.txt", "w").write("python-3.8.0")
|
||||
|
||||
if branch:
|
||||
install = [
|
||||
|
|
|
@ -57,8 +57,13 @@ def test_publish_heroku(mock_call, mock_check_output, mock_which):
|
|||
open("test.db", "w").write("data")
|
||||
result = runner.invoke(cli.cli, ["publish", "heroku", "test.db"])
|
||||
assert 0 == result.exit_code, result.output
|
||||
mock_call.assert_called_once_with(
|
||||
["heroku", "builds:create", "-a", "f", "--include-vcs-ignore"]
|
||||
mock_call.assert_has_calls(
|
||||
[
|
||||
mock.call(["heroku", "config:set", "-a", "f", "WEB_CONCURRENCY=1",]),
|
||||
mock.call(
|
||||
["heroku", "builds:create", "-a", "f", "--include-vcs-ignore"]
|
||||
),
|
||||
]
|
||||
)
|
||||
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue