How to publish a GitHub action in the marketplace

I’m trying to create a GitHub Action for the marketplace, but I’ve found two different guides which are contradticting each other. 

Metadata Syntax for GitHub Actions says to create an ‘action.yaml’ in the root repo, while Publishing an action in the GitHub Marketplace says to create a regular GitHub action in .github/workflows 

What steps do I take to convert an existing workflow into a GitHub action that I can publish to the GitHub marketplace? 

Here’s a template you can use: https://github.com/actions/typescript-action

Once you have an action.yml in the root of your repo. You’ll be able to publish to Marketplace by creating a new release.

I already have an action.yml in my repo, but it doesn’t give me the option to publish to Marketplace. I did notice, however, that in the guide in mentions the following:

Note:  GitHub requires that all labels in your Docker file are present if you want to publish your action to the GitHub Marketplace.

I’m not familiar with Dockerfiles… Do I need one for this to work? The template doesn’t have any.

The problem might be with the ‘runs’ in my action.yml file. I’m trying to run a Python script, but I’m not sure how I would go about doing that. The setup-python action uses a different syntax (steps.uses). I’m having a hard time figuring out the difference between the syntax for an action.yml and a regular workflow