Skip to content

Instantly share code, notes, and snippets.

/docker-log.txt Secret

Created February 17, 2017 15:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save anonymous/571edbd836b7f12e40a5ced47f34ade3 to your computer and use it in GitHub Desktop.
Save anonymous/571edbd836b7f12e40a5ced47f34ade3 to your computer and use it in GitHub Desktop.
Slack Log from docker
2017-02-14T17:24:31Z @markmandel <https://docs.docker.com/engine/getstarted/>
2017-02-14T17:24:48Z @markmandel I would suggest going through these steps
2017-02-14T17:24:55Z @bdw429s Thanks for the link.
2017-02-14T17:25:10Z @bdw429s It seems like I always found things that were more 30,000 ft overviews, or assumed a lot of knowledge.
2017-02-14T17:25:38Z @markmandel hunts.. which book did I read...
2017-02-14T17:25:44Z @bdw429s But I was also hoping someone else here was specifically working with Lucee extensions too-- information I%27m not likely to find online at all.
2017-02-14T17:25:55Z @markmandel Yeah that I can%27t help you with
2017-02-14T17:25:59Z @markmandel Dockre and K8s, I totally can
2017-02-14T17:29:25Z @markmandel <https://www.amazon.com/Docker-Book-Containerization-new-virtualization-ebook/dp/B00LRROTI4> &lt; I liked this book. I read it way back in the day, 99% sure it%27s been kept up to date
2017-02-14T17:31:55Z @watney
2017-02-14T17:31:55Z @bdw429s @markmandel ++ Thanks for the suggested reading%21
2017-02-14T17:33:42Z @markmandel Np
2017-02-14T17:33:58Z @markmandel There%27s a free Udacity course for Kubernetes if that%27s your thing as well
2017-02-14T17:34:13Z @markmandel <https://www.udacity.com/course/scalable-microservices-with-kubernetes--ud615>
2017-02-14T18:48:23Z @elpete @ uploaded a file: <https://cfml.slack.com/files/elpete/F45KCK0EQ/-.dockerfile|Untitled> and commented: @bdw429s We use this Dockerfile that has an extension bundled with it. The repo with this Dockerfile has the extension we need and it is added to the image on line 34.
2017-02-14T20:18:44Z @andymyers @ has left the channel
2017-02-15T04:43:55Z @mehdi @bdw429s yes you can commit an image state so you have a new image.
<https://docs.docker.com/engine/reference/commandline/commit/>
That way you will have a new image that you can deploy
2017-02-15T04:44:43Z @mehdi Kubernetes is too early at this stage @markmandel
2017-02-15T04:45:23Z @mehdi And you can also publish the new image in a local registery so you can pull it when ever you want
2017-02-15T04:49:00Z @mehdi and most of the job can be done in dockerfile
2017-02-15T05:38:40Z @markdrew @bdw429s What I did with <https://hub.docker.com/r/markdrew/lucee4_mongodb/> was to start a lucee4 container, log in, install the extension, delete the password, then do a `docker commit` on the running container and `docker push`
2017-02-15T05:39:16Z @markdrew I then have an instance of lucee with the mongodb extension installed and available from a repo. If I want to update it I can run the container, update whatever %28patches and what not%29 and then commit it and be done
2017-02-15T05:39:46Z @markdrew I realise that scripting it or using a Docker file would be the “better” way of doing it but this is just as fast and I don’t need to know the internals of deployments of extensions and what not.
2017-02-15T09:28:23Z @markmandel @mehdi what do you mean by "too early"?
2017-02-15T09:33:06Z @mehdi for some one just starting with docker
2017-02-15T09:33:46Z @mehdi moving to kubernetes may be interesting but later :wink:.
2017-02-15T09:34:28Z @mehdi once you got the first runners working fine then you start thinking pods and milking docker in more agressive way
2017-02-15T11:22:24Z @markmandel @mehdi yeah, but @bdw429s said he already had client who are using Kubernetes...
2017-02-15T11:23:16Z @markmandel it%27s a tough one "too early" - once you start using containers, you come up on "how do I orchestrate these" pretty quick IMHO
2017-02-15T11:49:28Z @bdw429s @mehdi Thanks for the advice. Like @markmandel said I%27ve already got a need to learn Kubernetes for a few reasons. I%27ve been down with the theory and 30,000 ft overview of Docker for a while I%27ve just never dug into the actual commands and tried using it.
2017-02-15T11:49:37Z @tbrown mostly for my own clarification, but maybe speaking to @bdw429s question... The Dockerfile is the definition of how to build the "image" right? Also if I remember correctly depending on how many things you script into your docker file it can create "extra layers" which will increase the image size and there are tricks like Eric is doing in his RUN commands to concatenate the commands as each run makes an new layer in the image. <https://blog.replicated.com/engineering/refactoring-a-dockerfile-for-image-size/>
2017-02-15T11:49:49Z @bdw429s Thanks to @modius and @justincarter for answering a great many questions last night in another Slack team.
2017-02-15T11:50:43Z @bdw429s @markdrew Thanks for the info. I had seen your image and wondered how you did it. I think @ example above would allow you to script the installation in the docker file providing you know the URL to the latest LEX file
2017-02-15T11:52:16Z @markdrew %28Not having looked at @elpete ‘s docker file%29 but the idea with lucee was to be to deploy extensions on startup, but I don’t like that, I like it all installed and warmed up, which is what I did. The only change I had to do was to reset the password to blank. Which was faster but not as l337
2017-02-15T11:53:28Z @markdrew at the end of the day I am going to modify the installation the first chance I get so I can make an image like that. I am not spending the time doing new images for example, if I did, I would create the dockerfile
2017-02-15T12:12:49Z @bdw429s @markdrew
2017-02-15T12:13:18Z @bdw429s I don%27t know if he%27s doing what @modius does-- but Geoff actually starts and stops the container as part of the build file.
2017-02-15T12:13:20Z @markdrew yeah, but then you have to wait Lucee to deploy
2017-02-15T12:13:31Z @bdw429s This "warms up" the instance by deploying all the contexts ahead of time.
2017-02-15T12:13:41Z @markdrew Yep, go for it :slightly_smiling_face:
2017-02-15T12:14:03Z @bdw429s It would be interesting if Lucee actually had an option to start itself up, install any extensions and deploy all contexts, then shut down just for this purpose.
2017-02-15T12:14:05Z @markdrew I mean, I just found it easier to go in, and do it, my dockerfile would be one line long and I had to just do it.
2017-02-15T12:14:16Z @markdrew It would be.
2017-02-15T12:14:25Z @bdw429s I%27d be interested in that just for the purpose of making CommandBox starts faster. Those context deploys can take too long.
2017-02-15T12:14:35Z @bdw429s I think It%27s TICKET TIME%21%21%21
2017-02-15T12:14:51Z @markdrew Also been thinking. That you should add an extension provider for forgebox and ask @micha to add it to the lucee by default
2017-02-15T12:15:00Z @micha @ has joined the channel
2017-02-15T12:15:13Z @bdw429s I%27ve actually considered pre-starting the CommandBox Lucee wars so they download with the context files already exploded and ready to go.
2017-02-15T12:15:18Z @markdrew @bdw429s do you have a music theme for creating tickets?
2017-02-15T12:15:41Z @markdrew It might be a way to go now with the osgi-ness of it all
2017-02-15T12:15:42Z @bdw429s No, I need one though . Any suggestions?
2017-02-15T12:16:18Z @markdrew <http://www.classictvhits.com/downloadsound.php?id=25>
2017-02-15T12:42:26Z @markmandel @bdw429s Oh that%27s clever -start and stop lucee during build - that makes sense, given what you told me
2017-02-15T16:01:05Z @markdrew The problem I found was that the deployment didn%27t start until you actually did a call. And then only sometimes.
2017-02-15T16:02:23Z @bdw429s The server context deployment is always automatic, but I could totally see the web context waiting until the first request.
2017-02-15T16:09:19Z @bdw429s Here%27s the ticket. Please comment with any additional thoughts
<https://luceeserver.atlassian.net/browse/LDEV-1196>
2017-02-15T17:32:12Z @holakita @ has joined the channel
2017-02-15T18:40:44Z @modius ```
# lucee first time startup; explodes lucee and installs bundles/extensions
RUN /usr/local/tomcat/bin/catalina.sh start &amp;&amp; \
while [ %21 -f "/opt/lucee/web/logs/application.log" ] ; do sleep 2; done &amp;&amp; \
/usr/local/tomcat/bin/catalina.sh stop
2017-02-15T18:42:12Z @modius as this is part of the %2Abuild%2A you never wait for it. If you are making code changes and somehow rebuilding the container each time.. you are doing it wrong. you need to copy your code into the container as part of the build and overwrite that code at run time using a VOLUME
2017-02-15T18:44:45Z @modius @markdrew we don%27t see this at all. I%27d be interested to hear more specifics. Could it be you have an extension that is being fetched from a remote provider rather than being found locally?
2017-02-16T05:20:22Z @markdrew @modius Maybe it was previously when deploying lex files so my bullet proof solution was to just spin it up and install it. Update it however I wanted and be done with it.
2017-02-16T18:41:36Z @modius @markdrew you should avoid manual interventions on the image at all costs. Ideally the image should be "buildable" automatically every commit without the need for manual wizard sauce :tophat:
2017-02-17T04:09:49Z @markdrew @modius I know the rules. Knowing them also allows me to break them knowing the consequences:%29
2017-02-17T04:10:28Z @markdrew I use this as a base image to actual Dockerfile and Compose based builds.
2017-02-17T04:10:48Z @markdrew The images don%27t change much.
2017-02-17T04:11:03Z @markdrew I.e. The base images.
2017-02-17T04:12:27Z @markdrew That would be great%21 I have been using HA with compose.
2017-02-17T08:50:53Z @elpete The Lucee 4.5 to Lucee 5.1 upgrade was a breeze for us thanks to the awesome Docker images provided here. Thanks everyone who had a hand in making them%21
<https://twitter.com/_elpete/status/832367235385602053>
2017-02-17T09:27:59Z @watney
2017-02-17T09:27:59Z @bdw429s @modius ++ for his awesome work on the Lucee docker images.
2017-02-17T09:37:44Z @guustnieuwenhuis @ are the lucee environment variables implemented in the docker images?
2017-02-17T09:38:07Z @bdw429s @guustnieuwenhuis Can you explain what you mean?
2017-02-17T09:38:59Z @guustnieuwenhuis lucee has environment vraiebles like `lucee.preserve.case` %28full list: <https://docs.google.com/spreadsheets/d/10s-nn_FsoSD_RiLwjYZICacCoC386SjkEGT3pOfBJVU/edit#gid=0>%29
2017-02-17T09:39:36Z @guustnieuwenhuis I’m wondering if I can set `lucee.preserve.case` in my docker compose file
2017-02-17T09:40:05Z @guustnieuwenhuis like with `SMTP_SERVER` for example
2017-02-17T09:40:22Z @bdw429s Funny, I was about to post about a few of those. I don%27t know enough about Docker, but I assume you can set whatever props you want when starting the container.
2017-02-17T09:47:09Z @bdw429s So a quick note to everyone who was talking to me about how to install Extensions the other day. Micha reminded me of some java system properties that managed to not make it into the docs anywhere. One of them is a list of extension IDs you want Lucee to install for you on startup. I updated the docs here:
<http://docs.lucee.org/guides/running-lucee/configuring-lucee/system-properties.html>
So it would look like this in your JVM args:
```-Dlucee-extensions=E6634E1A-4CC5-4839-A83C67549ECA8D5B,465E1E35-2425-4F4E-8B3FAB638BD7280A```
which would install MongoDB and H2 automatically. And in case you%27re curious where the _heck_ to get those GUIDs from, they%27re listed on this page here:
<http://stable.lucee.org/download/?type=extensions>
2017-02-17T09:52:05Z @bdw429s @modius @markdrew @elpete :point_up:
2017-02-17T09:53:12Z @elpete So where in your Dockerfile are you setting those JVM args?
2017-02-17T09:53:38Z @elpete And how does that work with different versions?
2017-02-17T09:54:06Z @elpete Do the GUID’s change depending on the version? Where is that on the extensions page?
2017-02-17T09:54:32Z @bdw429s The IDs are the same regardless of the version of an extension. Not sure why Lucee didn%27t also use a human-readable slug.
2017-02-17T09:54:46Z @bdw429s I assume you would always get the latest version of the extension.
2017-02-17T09:54:47Z @elpete So, I wonder how I can install a previous version of an extension.
2017-02-17T09:55:00Z @elpete I want Oracle 11g. The latest is Oracle 12c.
2017-02-17T09:55:13Z @bdw429s That sounds like a great question for @micha :slightly_smiling_face:
2017-02-17T09:55:38Z @bdw429s As far as where in Docker you set JVM args, I%27ve no clue but I assume that%27s something that%27s been thought of by now and how some sort of standard solution??
2017-02-17T09:56:21Z @elpete `LUCEE_JAVA_OPTS`
2017-02-17T09:56:29Z @elpete Maybe?
2017-02-17T09:56:37Z @elpete It’s how to set memory.
2017-02-17T09:57:16Z @bdw429s That would work.
2017-02-17T09:57:48Z @bdw429s @elpete All of the java system props on that doc can also be set as environment args on the OS
2017-02-17T09:57:58Z @bdw429s Which probably gives you a few more options as well
2017-02-17T09:58:23Z @bdw429s There%27s even some more that aren%27t added there from the looks of this doc. Check out the "envVar/SysPro" column:
<https://docs.google.com/spreadsheets/d/10s-nn_FsoSD_RiLwjYZICacCoC386SjkEGT3pOfBJVU/edit#gid=0>
2017-02-17T09:58:26Z @bdw429s @ shared a file: <https://cfml.slack.com/files/bdw429s/F3CHL1ZFZ/lucee_configuration|Lucee Configuration>
2017-02-17T09:59:18Z @bdw429s Here is where the IDs show up:
2017-02-17T09:59:22Z @bdw429s @ uploaded a file: <https://cfml.slack.com/files/bdw429s/F470LJE2E/pasted_image_at_2017_02_17_08_59_am.png|Pasted image at 2017-02-17, 8:59 AM>
2017-02-17T09:59:51Z @bdw429s An extension author creates their own ID and place it in their extension%27s manifest file.
2017-02-17T10:00:00Z @bdw429s I created one for the Ortus extension for instance.
2017-02-17T10:07:41Z @elpete Here was Micha’s answer: <https://cfml.slack.com/archives/lucee/p1487344003002671>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment