I’ve recently deployed Drone onto my server, and when my pipelines started hanging in “pending” mode, I decided to check what’s up. Turns out, Drone is setting the stage OS and arch to linux/amd64, even though the platform key inside the yml defines them as linux/arm64.
Okay, about 10 .drone.yml edits later, I’ve realized that the pipeline in Drone is not really getting created.
Turns out missing secrets were the issue. Apparently Drone refuses to create the pipeline if secrets are missing (would be great if someone could confirm or correct that), and that leads to, for some reason, to Drone also ignoring the configuration in platform.{os,arch}
This is incorrect. Drone executes the pipeline regardless of whether or not the secret exists. Here is an example yaml and corresponding build that demonstrates this behavior:
I am unable to reproduce and have not received any other reports matching the behavior you described (the platform feature is very heavily used in the Drone community). See the example yaml and the API response below, which reflects the architecture defined in the yaml.
For some reason, it looks like Drone stopped parsing the yml past the fourth line, because none of the steps were created, nor was the platform properly set. I personally have no clue why that has happened, but later I rewrote the entire file, with a step that didn’t use a secret, and that made the CI execute properly.
It should also be noted that initially the pipeline was first created without the platform configuration.