Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
cloud-computing-msc-ai-examples
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Christoph Jürgen König
cloud-computing-msc-ai-examples
Commits
8350862a
Commit
8350862a
authored
1 year ago
by
Sebastian Rieger
Browse files
Options
Downloads
Patches
Plain Diff
fixed type in cloud-init for microservice worker, removed rabitmq fix as it is not needed anymore
parent
f63e5ebd
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
demo3_microservice.py
+4
-14
4 additions, 14 deletions
demo3_microservice.py
with
4 additions
and
14 deletions
demo3_microservice.py
+
4
−
14
View file @
8350862a
...
...
@@ -192,21 +192,11 @@ def main(): # noqa: C901 pylint: disable=too-many-branches,too-many-statements,
#
###########################################################################
# https://git.openstack.org/cgit/openstack/faafo/plain/contrib/install.sh
# is currently broken, hence the "rabbitctl" lines were added in the example
# below, see also https://bugs.launchpad.net/faafo/+bug/1679710
#
# Thanks to Stefan Friedmann for finding this fix ;)
# TODO: still needed for new version of faafo and Ubuntu 22.04?
userdata
=
'
#!/usr/bin/env bash
\n
'
\
'
curl -L -s https://gogs.informatik.hs-fulda.de/srieger/cloud-computing-msc-ai-
'
\
'
examples/raw/master/faafo/contrib/install.sh | bash -s --
'
\
'
-i messaging -i faafo -r api
\n
'
\
'
rabbitmqctl add_user faafo guest
\n
'
\
'
rabbitmqctl set_user_tags faafo administrator
\n
'
\
'
rabbitmqctl set_permissions -p / faafo
"
.*
"
"
.*
"
"
.*
"
\n
'
print
(
'
\n
Using cloud-init userdata:
\n
"'
+
userdata
+
'"
\n
'
)
'
-i messaging -i faafo -r api
\n
'
print
(
'
\n
Using cloud-init userdata for controller:
\n
"'
+
userdata
+
'"
\n
'
)
print
(
'
Starting new app-controller instance and wait until it is running...
'
)
instance_controller_1
=
conn
.
create_node
(
name
=
'
app-controller
'
,
...
...
@@ -265,8 +255,8 @@ def main(): # noqa: C901 pylint: disable=too-many-branches,too-many-statements,
'
curl -L -s https://gogs.informatik.hs-fulda.de/srieger/cloud-computing-msc-ai-
'
\
'
examples/raw/master/faafo/contrib/install.sh | bash -s --
'
\
f
'
-i faafo -r worker -e
"
http://
{
ip_controller
}
"
-m
"
amqp://faafo:guest@
'
\
f
'
{
ip_controller
}
:5672/
\n
'
print
(
'
\n
Using cloud-init userdata:
\n
"'
+
userdata
+
'"
\n
'
)
f
'
{
ip_controller
}
:5672/
"
\n
'
print
(
'
\n
Using cloud-init userdata
for worker
:
\n
"'
+
userdata
+
'"
\n
'
)
print
(
'
Starting new app-worker-1 instance and wait until it is running...
'
)
instance_worker_1
=
conn
.
create_node
(
name
=
'
app-worker-1
'
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment