- Assuming you already have Docker and Docker Compose installed
0. Change your database user and password in env-mysql.env and env-yourls.env
- You should see following 3 kinds of success log
- YOURLS init
YOURLS | YOURLS init... YOURLS | YOURLS init done! YOURLS exited with code 0
- MySQL init
yourls-database | update db user privileges yourls-database | MySQL init done! yourls-database exited with code 0
- Finish and shutdown
Init complete Removing YOURLS ... done Removing yourls-database ... done Removing network docker_intranet-init-yourls
- YOURLS init
- If things failed, try to increase delay time (POSTPONE_FOR_A_WHILE=60s)
- E.g., set to
90sor longer - Note that you have to remove old failed database before retry
- E.g., set to
- Set flags in
docker-compose-init.ymlas needed- Set
INIT_INSTALL_RECOMMENDED_PLUGINS=trueto install plugins recommended (and revise) by me - Set
INIT_ENABLE_GITLAB_OAUTH_SUPPORT=trueto add (GitLab) OAuth support
- Set
- Now, you can visit
http://localhost/admin/index.phpto start using YOURLS - Remember to change domain setting in both Nginx config and YOURLS
- Note that
config-docker.phpwill be copied as/docker/deploy/yourls/user/config.php, so change that file after running0-init.shrather than modifyconfig-docker.phpitself - Also remember to replace default user as your own ones; otherwise, it may be dangerous
- Note that
- Answer
YtoWarning!! (Permanently) REMOVE folders for yourls and database? [y/N]if you want to Remove Database and YOURLS - Otherwise, answer
NorPress Enterto keep data
- The main point is that MySQL chane their policy on authentication method
- The critical script is
cmd-mysql.shfor this project#L15is the original entrypoint, which will initialize the database#L16is for commandpsandpkillin alpine#L17is the delay time for former works to get ready#L18is to kill the original mysqld#L20is to create a newmysqld_safewith flag--skip-grant-tables#L26-L29are to enablemysql_native_passwordfor user
- The critical script is
This project is licensed under the following 3 licenses, YOURLS, MIT, and EPL
- YOURLS: aka
Do whatever the hell you want with it - MIT: aka
MadeInTaiwan Licenceฅ• ω •ฅ - EPL: aka
EPL Public License, where EPL stands for EmbeddedPlatformLab (like GNU or YAML, quite cool, huh?)
Feel free to modify it to your own version as needed
Contact me if having any comments :D
