Error on parsing fly.toml , deploy_couchdb_to_flyio_v2_with_swap.ipynb
Abstract
The script is not working
Error: failed loading app config from /home/ec2-user/obsidian-livesync/fly.toml: toml: line 28: Key 'build' has already been defined.
I had use the following command to run deploy_couchdb_to_flyio_v2_with_swap.ipynb
sudo ipython --TerminalIPythonApp.file_to_run= deploy_couchdb_to_flyio_v2_with_swap.ipynb
Generated fly.toml,
# fly.toml app configuration file generated for purple-sound-5047 on 2023-10-25T02:42:54Z
#
# See https://fly.io/docs/reference/configuration/ for information about how to use this file.
#
app = "purple-sound-5047"
primary_region = "nrt"
[build]
[http_service]
internal_port = 5984
force_https = true
auto_stop_machines = true
auto_start_machines = true
min_machines_running = 0
processes = ["app"]
[env]
COUCHDB_USER = "alkcsa93"
ERL_FLAGS="-couch_ini /opt/couchdb/etc/default.ini /opt/couchdb/etc/default.d/ /opt/couchdb/etc/local.d /opt/couchdb/etc/local.ini /opt/couchdb/data/persistence.ini"
[mounts]
source="couchdata"
destination="/opt/couchdb/data"
[build]
dockerfile = "./Dockerfile"
System:
AWS linux
Same thing happen when I following this guide. Default fly.toml generated
# fly.toml app configuration file generated for broken-grass-8742 on 2023-10-25T03:54:18Z
#
# See https://fly.io/docs/reference/configuration/ for information about how to use this file.
#
app = "broken-grass-8742"
primary_region = "nrt"
[build]
[http_service]
internal_port = 8080
force_https = true
auto_stop_machines = true
auto_start_machines = true
min_machines_running = 0
processes = ["app"]
I believe there is some update from fly and it generate a different fly.toml compare to the time the colab notebook is written (Build is automatically generated for now)
Date of running the script : 25/10/2023
May I know can you reproduce the issue by simply running the colab notebook and running the command flyctl launch --generate-name --detach --no-deploy --region nrt, if yes, may I try to edit the notebook and the guide to fix the issue and submit a pull request. Thanks.
Not working for me either.
Sorry for being so late! This had been caused by forcibly modifying the TOML as like text. For robustness, we had been better to take care of the structure, instead of using a simple but wild method.
Therefore, I have fixed the notebook to do so. Would you please check the behaviour?