From 9ad4e973fe6a11fe55b2d370578057c43a6f39ac Mon Sep 17 00:00:00 2001
From: parauliya <aman@infracloud.io>
Date: Fri, 3 Apr 2020 00:11:47 +0530
Subject: [PATCH 1/2] Added nginx setup in docker-compose setup process

---
 setup_with_docker_compose.sh | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)

diff --git a/setup_with_docker_compose.sh b/setup_with_docker_compose.sh
index 9155886fa..d24dfd155 100755
--- a/setup_with_docker_compose.sh
+++ b/setup_with_docker_compose.sh
@@ -35,7 +35,26 @@ function setup_network () {
     sudo ip addr add $NGINX_IP/$IP_CIDR dev $network_interface
 }
 
+function setup_osie_with_nginx() {
+    mkdir -p /packet/nginx/misc/osie/current
+    mkdir -p /packet/nginx/misc/tinkerbell/workflow/
+    cd /packet/nginx/misc/tinkerbell/workflow/
+    wget https://raw.githubusercontent.com/tinkerbell/osie/master/installer/workflow-helper.sh
+    wget https://raw.githubusercontent.com/tinkerbell/osie/master/installer/workflow-helper-rc
+    chmod +x workflow-helper.sh
+    
+    cd /tmp
+    curl 'https://packet-osie-uploads.s3.amazonaws.com/osie-v19.10.23.00-n=55,c=be58d67,b=master.tar.gz' -o osie.tar.gz
+    tar -zxvf osie.tar.gz
+    cd /tmp/'osie-v19.10.23.00-n=55,c=be58d67,b=master'
+    cp -r grub /packet/nginx/misc/osie/current/
+    cp modloop-x86_64 /packet/nginx/misc/osie/current/
+    cp initramfs-x86_64 /packet/nginx/misc/osie/current/
+    cp vmlinuz-x86_64 /packet/nginx/misc/osie/current/
+    rm /tmp/'osie-v19.10.23.00-n=55,c=be58d67,b=master' -rf
+}
 function build_and_setup_certs () {
+    cd ~/go/src/github.com/tinkerbell/tink
     grep "$HOST_IP" /etc/network/interfaces
     if [[ $? -eq 1 ]]
     then            
@@ -89,6 +108,7 @@ function start_docker_stack() {
 
 setup_environemt;
 setup_network;
+setup_osie_with_nginx;
 build_and_setup_certs;
 build_registry_and_update_worker_image;
 start_docker_stack;

From addf66001a2c88182fbda16e53a95c526f96ee83 Mon Sep 17 00:00:00 2001
From: parauliya <aman@infracloud.io>
Date: Fri, 3 Apr 2020 01:04:24 +0530
Subject: [PATCH 2/2] Fixed a minor issue in for the cli container

---
 docker-compose.yml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/docker-compose.yml b/docker-compose.yml
index 8ff08bd14..b092f578c 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -71,7 +71,7 @@ services:
       options:
         tag: tink-cli
     depends_on:
-      tinkerbell:
+      tink-server:
         condition: service_healthy
       db:
         condition: service_healthy