[PR #802] [CLOSED] Mysql support #1660

Closed
opened 2025-12-29 02:31:07 +01:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/juanfont/headscale/pull/802
Author: @Willsr71
Created: 9/12/2022
Status: Closed

Base: mainHead: mysql-2


📝 Commits (2)

📊 Changes

5 files changed (+74 additions, -27 deletions)

View changed files

📝 app.go (+28 -0)
📝 db.go (+13 -13)
📝 go.mod (+3 -1)
📝 go.sum (+3 -0)
📝 machine.go (+27 -13)

📄 Description

  • read the CONTRIBUTING guidelines
  • raised a GitHub issue or discussed it on the projects chat beforehand
  • added unit tests
  • added integration tests
  • updated documentation if needed
  • updated CHANGELOG.md

This adds mysql support. I have tested interactions against every table except kvs, but it doesn't have any new data types so it should work. Please note this is my first foray into go so I highly doubt this PR is without issues.

There's still some improvements that I'd like to make to this, namely using FormatDSN instead of the rather gross mess that is there right now. Unfortunately I'm rather time limited at the moment, so this will have to do.

I've joined the discord, feel free to hit me up, I'll have limited internet access for a while though so it might be a bit before a response.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/juanfont/headscale/pull/802 **Author:** [@Willsr71](https://github.com/Willsr71) **Created:** 9/12/2022 **Status:** ❌ Closed **Base:** `main` ← **Head:** `mysql-2` --- ### 📝 Commits (2) - [`21c5e38`](https://github.com/juanfont/headscale/commit/21c5e38616e8f7dd2c3d6b8d300706e4c05422cb) Mysql support - [`3aebcdd`](https://github.com/juanfont/headscale/commit/3aebcddcc6642fb036d5e6a5b4cef521a56f7a9f) dep update ### 📊 Changes **5 files changed** (+74 additions, -27 deletions) <details> <summary>View changed files</summary> 📝 `app.go` (+28 -0) 📝 `db.go` (+13 -13) 📝 `go.mod` (+3 -1) 📝 `go.sum` (+3 -0) 📝 `machine.go` (+27 -13) </details> ### 📄 Description <!-- Please tick if the following things apply. You… --> - [X] read the [CONTRIBUTING guidelines](README.md#contributing) - [ ] raised a GitHub issue or discussed it on the projects chat beforehand - [ ] added unit tests - [ ] added integration tests - [ ] updated documentation if needed - [ ] updated CHANGELOG.md This adds mysql support. I have tested interactions against every table except kvs, but it doesn't have any new data types so it should work. Please note this is my first foray into go so I highly doubt this PR is without issues. There's still some improvements that I'd like to make to this, namely using [FormatDSN](https://pkg.go.dev/github.com/go-sql-driver/mysql?utm_source=godoc#Config.FormatDSN) instead of the rather gross mess that is there right now. Unfortunately I'm rather time limited at the moment, so this will have to do. I've joined the discord, feel free to hit me up, I'll have limited internet access for a while though so it might be a bit before a response. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
adam added the pull-request label 2025-12-29 02:31:07 +01:00
adam closed this issue 2025-12-29 02:31:07 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/headscale#1660