Quick Start
This page covers takeout run. More detailed setup and configuration is covered in setup.
The takeout run command can be used to quickly setup and run takeout. This process can use command line options, environment variables, and yaml files to create the required configuration as described in setup. takeout run will also start the takeout server after the configuration has been created.
After using takeout run you can switch to using takeout serve with the created configuration, as described in setup. takeout run be used as well, however, it will only create the configuration once.
Use the –setup_only option to only create configuration without starting the server.
Install Go
Download and install Go from https://go.dev/ as needed. Run the following command to ensure Go is correctly installed. You should have Go 1.22 or higher.
$ go version
Install Takeout
Download and build the takeout server from source.
$ go install takeoutfm.dev/takeout/cmd/takeout@latest
This will build & install takeout in $GOPATH/bin. Don’t worry if you don’t have a GOPATH environment variable defined, Go will default to your home directory (~/go/bin). Ensure that $GOPATH/bin is in your command path. You should see a takeout version displayed.
$ takeout version
Takeout Run
Now you can use takeout run to setup and start takeout. Below are some example commands. Please see takeout run –help for further details.
Media in S3
$ takeout run --dir /home/takeout --music s3://mybucket/Music --endpoint s3.someprovider.net --region us-west --access_key_id MY_KEY_ID --secret_access_key MY_SECRET_KEY --log /tmp/takeout.log
Local media
$ takeout run --dir /home/takeout --music /media/music --movies /media/movies --log /tmp/takeout.log
Note that S3 credentials can be obtained from the following environment variables:
- AWS_ENDPOINT_URL
- AWS_DEFAULT_REGION
- AWS_ACCESS_KEY_ID
- AWS_SECRET_ACCESS_KEY
Options can also be stored in a yaml configuration file located here:
- $HOME/.config/takeout/config.yaml
- $HOME/.takeout/config.yaml
Supported file options are the same as the command line options, without the leading dashes.
Media Sync
takeout run will sync your media which means it will look for supported music and video file extensions and obtain metadata from corresponding services. This process will take a while so be patient.
Next Steps
The server files will located in the directory specified with the –dir option. Cache files will be stored in the –cache directory. The defaults are /var/lib/takeout and /var/cache/takeout respectively. A userid and password will be generated and output to the screen.
Access the server at http://localhost:3000/ and login with the generated userid and password.
Install apps and enjoy your media.
Caution
This setup is not secure. Setup a TLS server like nginx or caddy.