Feed2Toot Docker is a fork of [chaica/feed2toot](https://gitlab.com/chaica/feed2toot) that allows for simple deployment over Docker. In the future I'll try to add other useful features.
Insert your full username (including the part with your homeserver's address), password and instance URL where required.
You also need to create a working `feed2toot.ini` in the `./data` folder. See the [upstream docs](`https://feed2toot.readthedocs.io/en/latest/configure.html#create-feed2toot-configuration`) for the guide.
### Create the authorization for the Feed2toot app
After the first successful run, you can remove the entire `environment` block if you want, however, if you delete and re-create the container, you will need to put it back.
* Just launch the following command::
### Support
$ register_feed2toot_app
Don't ask the upstream developers for help, if something is broken it's more likely that it is my fault.
You can get support by opening an [issue](https://gitea.massivebox.net/massivebox/feed2toot-docker/issues), or by [contacting me](https://massivebox.net/contact.html), or in the [Matrix support room](https://matrix.to/#/#support:massivebox.net).
### Use Feed2toot
* Create or modify feed2toot.ini file in order to configure feed2toot:
[mastodon]
instance_url=https://mastodon.social
user_credentials=feed2toot_usercred.txt
client_credentials=feed2toot_clientcred.txt
; Default visibility is public, but you can override it:
; toot_visibility=unlisted
[cache]
cachefile=cache.db
[rss]
uri=https://www.journalduhacker.net/rss
toot={title} {link}
[hashtaglist]
several_words_hashtags_list=hashtags.txt
### Feed2toot
* Launch Feed2toot
The following links and addresses are the upstream developers'. I don't want donations for this project, but I encourage you to donate to them.
parser.add_argument('--client-credentials-file', dest='clientcredfile', help='the name of the client credentials for the Mastodon app', default='feed2toot_clientcred.txt')
parser.add_argument('--user-credentials-file', dest='usercredfile', help='the name of the user credentials for the Mastodon app', default='feed2toot_usercred.txt')
parser.add_argument('--name', help='the name of the Mastodon app', default='feed2toot')
parser.add_argument('--instance', help='the URL of the Mastodon instance')
parser.add_argument('--username', help='the username of your Mastodon account')
parser.add_argument('--password', help='the password of your Mastodon account')
opts = parser.parse_args()
clientcredfile=opts.clientcredfile
@ -44,7 +47,9 @@ print(headline)
# get the instance
instance = input('Mastodon instance URL (defaults to https://mastodon.social): ')
instance = opts.instance
if not instance:
instance = input('Mastodon instance URL (defaults to https://mastodon.social): ')
if not instance:
instance = 'https://mastodon.social'
elif not instance.startswith('http'):
@ -52,19 +57,25 @@ elif not instance.startswith('http'):
# get the username
userok = False
quit_on_error = True
while not userok:
user = input('Mastodon login: ')
user = opts.username
if not user:
user = input('Mastodon login: ')
quit_on_error = False
if not user:
print('Your Mastodon username can not be empty.')
userok = False
elif '@' not in user or '.' not in user:
print('Your Mastodon username should be an email.')