Skip to content

Commit

Permalink
Fix SSH key locations for new server layout
Browse files Browse the repository at this point in the history
As of a week or so ago the MPR server has been put on the main homelab instance, and that has brought about some layout changes for where things like the SSH keys are stored.
  • Loading branch information
hwittenborn committed Apr 29, 2023
1 parent 69fd183 commit acdb561
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .drone/drone.jsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ local publishImage() = {
type: "exec",
trigger: {branch: ["main"]},
depends_on: ["run-tests"],
node: {server: "mprweb"},
node: {server: "homelab"},
steps: [{
name: "publish-image",
environment: {
Expand Down
7 changes: 4 additions & 3 deletions .drone/scripts/publish-image.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@ aurweb_config set notifications smtp-password "${mpr_smtp_password}"
aurweb_config set notifications sender "MPR <mpr@${makedeb_url}>"
aurweb_config set notifications reply-to "mpr@${makedeb_url}"

ed25519_key="$(ssh-keygen -lf /etc/ssh/ssh_host_ed25519_key.pub | awk '{print $2}')"
ecdsa_key="$(ssh-keygen -lf /etc/ssh/ssh_host_ecdsa_key.pub | awk '{print $2}')"
rsa_key="$(ssh-keygen -lf /etc/ssh/ssh_host_rsa_key.pub | awk '{print $2}')"
ed25519_key="$(ssh-keygen -lf /var/www/mpr.makedeb.org/keys/ssh_host_ed25519_key.pub | awk '{print $2}')"
ecdsa_key="$(ssh-keygen -lf /var/www/mpr.makedeb.org/keys/ssh_host_ecdsa_key.pub | awk '{print $2}')"
rsa_key="$(ssh-keygen -lf /var/www/mpr.makedeb.org/keys/ssh_host_rsa_key.pub | awk '{print $2}')"

aurweb_config set fingerprints Ed25519 "${ed25519_key}"
aurweb_config set fingerprints ECDSA "${ecdsa_key}"
Expand All @@ -60,6 +60,7 @@ docker-compose -f ./docker-compose.yml \
find ./ -maxdepth 1 \
-not -path './' \
-not -path './data' \
-not -path './keys' \
-not -path './service.sh' \
-exec rm -rf '{}' +

Expand Down
6 changes: 3 additions & 3 deletions docker-compose.mpr-override.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ services:
volumes:
- ./data/git_data:/aurweb/aur.git
- ./data:/aurweb/data
- /etc/ssh/ssh_host_ecdsa_key:/etc/ssh/ssh_host_ecdsa_key:ro
- /etc/ssh/ssh_host_ed25519_key:/etc/ssh/ssh_host_ed25519_key:ro
- /etc/ssh/ssh_host_rsa_key:/etc/ssh/ssh_host_rsa_key:ro
- ./keys/ssh_host_ecdsa_key:/etc/ssh/ssh_host_ecdsa_key:ro
- ./keys/ssh_host_ed25519_key:/etc/ssh/ssh_host_ed25519_key:ro
- ./keys/ssh_host_rsa_key:/etc/ssh/ssh_host_rsa_key:ro

smartgit:
volumes:
Expand Down

0 comments on commit acdb561

Please sign in to comment.