Bump abra, add swarm installer script
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Luke Murphy 2020-09-24 09:14:00 +02:00
parent 45402139ba
commit ed1d84c575
No known key found for this signature in database
GPG Key ID: 5E2EF5A63E3718CC
6 changed files with 67 additions and 9 deletions

View File

@ -1,9 +1,13 @@
ABRA_VERSION := 0.1.2 ABRA_VERSION := 0.2.0
ABRA_SRC := "https://git.autonomic.zone/autonomic-cooperative/abra/raw/tag/$(ABRA_VERSION)/installer" ABRA_INSTALL_SRC := "https://git.autonomic.zone/autonomic-cooperative/abra/raw/tag/$(ABRA_VERSION)/script.d/abra-installer"
SWARM_INSTALL_SRC := "https://git.autonomic.zone/autonomic-cooperative/abra/raw/tag/$(ABRA_VERSION)/script.d/swarm-installer"
default: update-abra-installer default: update-abra-installer update-swarm-installer
update-abra-installer: update-abra-installer:
@curl $(ABRA_SRC) > abra/installer @curl $(ABRA_INSTALL_SRC) > abra/abra-installer
.PHONY: update-abra-installer update-swarm-installer:
@curl $(SWARM_INSTALL_SRC) > swarm/swarm-installer
.PHONY: update-abra-installer update-swarm-installer

View File

@ -5,6 +5,6 @@ server {
location / { location / {
root /var/www/abra-installer; root /var/www/abra-installer;
add_header Content-Type text/plain; add_header Content-Type text/plain;
index installer; index abra-installer;
} }
} }

View File

@ -2,13 +2,13 @@
version: "3.8" version: "3.8"
services: services:
nginx: abra-installer:
image: "nginx:stable" image: "nginx:stable"
configs: configs:
- source: abra_conf - source: abra_conf
target: /etc/nginx/conf.d/abra.conf target: /etc/nginx/conf.d/abra.conf
- source: abra_installer - source: abra_installer
target: /var/www/abra-installer/installer target: /var/www/abra-installer/abra-installer
volumes: volumes:
- "public:/var/www/abra-installer" - "public:/var/www/abra-installer"
networks: networks:
@ -24,13 +24,41 @@ services:
- "traefik.http.routers.installer-scripts.entrypoints=web-secure" - "traefik.http.routers.installer-scripts.entrypoints=web-secure"
- "traefik.http.routers.installer-scripts.tls.certresolver=production" - "traefik.http.routers.installer-scripts.tls.certresolver=production"
swarm-installer:
image: "nginx:stable"
configs:
- source: swarm_conf
target: /etc/nginx/conf.d/swarm.conf
- source: swarm_installer
target: /var/www/swarm-installer/swarm-installer
volumes:
- "public:/var/www/swarm-installer"
networks:
- proxy
deploy:
update_config:
failure_action: rollback
order: start-first
labels:
- "traefik.enable=true"
- "traefik.http.services.installer-scripts.loadbalancer.server.port=80"
- "traefik.http.routers.installer-scripts.rule=Host(`install.swarm.autonomic.zone`)"
- "traefik.http.routers.installer-scripts.entrypoints=web-secure"
- "traefik.http.routers.installer-scripts.tls.certresolver=production"
configs: configs:
abra_installer: abra_installer:
name: abra_installer_v1 name: abra_installer_v1
file: abra/installer file: abra/abra-installer
abra_conf: abra_conf:
name: abra_conf_v1 name: abra_conf_v1
file: abra/abra.conf file: abra/abra.conf
swarm_installer:
name: swarm_installer_v1
file: swarm/swarm-installer
swarm_conf:
name: swarm_conf_v1
file: swarm/swarm.conf
networks: networks:
proxy: proxy:

16
swarm/swarm-installer Normal file
View File

@ -0,0 +1,16 @@
#!/bin/sh
install_docker() {
echo "install_docker: TODO"
}
init_swarm() {
echo "init_swarm: TODO"
}
run_installation() {
install_docker
init_swarm
}
run_installation
exit 0

10
swarm/swarm.conf Normal file
View File

@ -0,0 +1,10 @@
server {
listen 80 default_server;
server_name install.swarm.autonomic.zone;
location / {
root /var/www/swarm-installer;
add_header Content-Type text/plain;
index swarm-installer;
}
}